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

orb create precludes use of orb init #804

Open
Peter-Darton-i2 opened this issue Nov 1, 2022 · 1 comment
Open

orb create precludes use of orb init #804

Peter-Darton-i2 opened this issue Nov 1, 2022 · 1 comment
Assignees

Comments

@Peter-Darton-i2
Copy link

The recommended/documented orb registration command (orb create) locks the user out from ever using the recommended/documented orb development process (orb init).
This isn't a good user experience.

Meta:

CircleCI CLI Version:
0.1.22322+5ff92b4 (release)

Operating System:
Ubuntu running under WSL2 on Win10

CircleCI CLI Diagnostic:

---
CircleCI CLI Diagnostics
---
Debugger mode: false
Config found: /home/pjd/.circleci/cli.yml
API host: https://circleci.com
API endpoint: graphql-unstable
OK, got a token.
Trying an introspection query on API...
Ok.
Hello, Peter Darton.

Current behavior:

  1. circleci orb create myorg/myorbname --private
  2. circleci orb init myorbname --private
    ...
    Error: Unable to create orb: Cannot create an Orb named 'myorbname': an Orb with that name already exists.

Expected behavior:

orb init command should detect that the orb has already been registered and continue on (it does this when registering contexts; it needs to do this everywhere else too).

When did this begin / Was this previously working?:

I've only tried to use this command today; it's failed every time (see also #495 and #803)

Additional Information:

As with #495 and #803, the same bad coding pattern is used and the fix is much the same for all - whenever orb init needs something to exist, it should first check to see if it already exists before trying to create it (just as it does for the publishing context).

Alternatively, the circleci orb create command (and all related documentation) needs to make it 100% clear that its use will irrevocably prevent the use of circleci orb init for that orb, forever.
i.e. It should never come as a surprise to the user that they've screwed up their only chance of using orb init.

@zbenhadi
Copy link
Contributor

Hello @Peter-Darton-i2, thank you for this very detailed issue. Just letting you know that we are considering this issue (along with #803 ) and trying to come up with a coherent solution between create & init behaviors.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants