bluerobotics / bluerobotics/ping-viewer-next
Allow load custom json zenoh settings
- Dominant language
- Vue
- Stars
- 3
- Forks
- 10
- Avg merge
- 19h 54m
- Merged PRs (30d)
- 7
Description
Saving the configuration on loading the configuration from a file is problematic, this will save the zenoh id that should be unique per application while being unnecessary at all.
If the goal is to load custom zenoh configuration you should do as the following pseudo-python script
```python
zenoh_config = zenoh.Config()
zenoh_config.insert_json5("mode", json.dumps("client"))
zenoh_config.insert_json5("connect/endpoints", json.dumps(["tcp/127.0.0.1:7447"]))
zenoh_config.insert_json5("adminspace", json.dumps({"enabled": True}))
zenoh_config.insert_json5("metadata", json.dumps({"name": node_name}))
if input_file:
zenoh_config.from_json5(json5.dumps(input_file))
session = zenoh.open(zenoh_config)
```
_Originally posted by @patrickelectric in https://github.com/bluerobotics/ping-viewer-next/pull/109#discussion_r2211072159_
Contributor guide
No contributing guide indexed for this repository
Research direction
Start by locating the configuration-loading path and the zenoh session-opening entry point described in the issue. Compare that flow with the provided pseudo-Python example; done means custom JSON settings load without unnecessarily saving or replacing the unique zenoh id.
Written by the indexing model from the issue text.
Assessment
- Domain
- networking
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100