Skip to content
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

bug: inconsistent usage of topic flags #1726

Closed
jakubgs opened this issue May 12, 2023 · 1 comment · Fixed by #1727
Closed

bug: inconsistent usage of topic flags #1726

jakubgs opened this issue May 12, 2023 · 1 comment · Fixed by #1727
Assignees
Labels
bug Something isn't working

Comments

@jakubgs
Copy link
Contributor

jakubgs commented May 12, 2023

Problem

There's two ways to use topics flags:

  • --topics - Takes a list of comma separated topics, CANNOT be repeated.
  • --protected-topic - Does NOT take a list, CAN be repeate.

Makes no sense.

Impact

Almost made me vomit.

Expected behavior

Not inducing nauseousness. Probably just make --topics into --topic and allow it to be repeated.

Additional context

topics* {.
desc: "Default topics to subscribe to (space separated list)."
defaultValue: "/waku/2/default-waku/proto"
name: "topics" .}: string

protectedTopics* {.
desc: "Topics and its public key to be used for message validation, topic:pubkey. Argument may be repeated."
defaultValue: newSeq[ProtectedTopic](0)
name: "protected-topic" .}: seq[ProtectedTopic]

@jm-clius
Copy link
Contributor

Hahaha. Yeah, this is bad. The --topics config item is old and was never used until recently, so no-one scrutinised how ugly it is against the rest of the config items. I think --topic should be repeated argument (similar to almost all other repeated config items).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants