Skip to content

gossip cli commands are unusable #2698

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
dignifiedquire opened this issue Sep 5, 2024 · 1 comment · Fixed by #2751
Closed

gossip cli commands are unusable #2698

dignifiedquire opened this issue Sep 5, 2024 · 1 comment · Fixed by #2751
Assignees
Labels
bug Something isn't working _c-iroh-cli
Milestone

Comments

@dignifiedquire
Copy link
Contributor

subscribe is not really usable

> gossip subscribe test
error: invalid value 'test' for '[BOOTSTRAP]...': decoding: base32: non-zero trailing bits at 3

sending a message seems not to be available at all

@dignifiedquire dignifiedquire added bug Something isn't working _c-iroh-cli labels Sep 5, 2024
@dignifiedquire dignifiedquire added this to the v0.25.0 milestone Sep 5, 2024
@b5
Copy link
Member

b5 commented Sep 6, 2024

agreed. it took me a long time to learn the incantations to make gossip work

@dignifiedquire dignifiedquire modified the milestones: v0.25.0, v0.26.0 Sep 16, 2024
@matheus23 matheus23 self-assigned this Sep 27, 2024
github-merge-queue bot pushed a commit that referenced this issue Sep 30, 2024
…#2751)

## Description

<!-- A summary of what this pull request achieves and a rough list of
changes. -->

Previously the gossip command could be confusing:
```sh
$ iroh gossip subscribe test --start
error: invalid value 'test' for '[BOOTSTRAP]...': decoding: base32: non-zero trailing bits at 3
```

Now, the output is more helpful:
```sh
$ iroh gossip subscribe test --start
error: the following required arguments were not provided:
  <--topic <TOPIC>|--raw-topic <RAW_TOPIC>>

Usage: iroh gossip subscribe --start <--topic <TOPIC>|--raw-topic <RAW_TOPIC>> <BOOTSTRAP>...

For more information, try '--help'.
```

And the help text also contains examples & explanation on how the
command works.

## Breaking Changes

<!-- Optional, if there are any breaking changes document them,
including how to migrate older code. -->
None. The command still works the same way.

## Notes & open questions

Closes #2698

Should we rename the command? When I read `gossip subscribe` initially,
I thought a `gossip publish` command may be missing. But actually
`gossip subscribe` does both.
Perhaps `gossip join` may be better?
But also: We want to keep the CLI names in sync with the names in the
code API. Perhaps we should rename the API call to be `join` instead of
`subscribe`? Or perhaps something like `open_topic`?
Anyhow - perhaps that's food for thought & another PR.


## Change checklist

- [x] Self-review.
- [x] Documentation updates following the [style
guide](https://rust-lang.github.io/rfcs/1574-more-api-documentation-conventions.html#appendix-a-full-conventions-text),
if relevant.
- ~~[ ] Tests if relevant.~~
- [x] All breaking changes documented.

Co-authored-by: Friedel Ziegelmayer <[email protected]>
@github-project-automation github-project-automation bot moved this to ✅ Done in iroh Sep 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working _c-iroh-cli
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

3 participants