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

releases requiring --org, but fails when argument is passed #723

Closed
someguynamedmatt opened this issue Apr 29, 2020 · 4 comments · Fixed by getsentry/sentry-docs#1664
Closed

Comments

@someguynamedmatt
Copy link

someguynamedmatt commented Apr 29, 2020

sentry-cli: 1.52.3
MacOS: 10.14.6

I'm following the documentation to create releases, but it won't accept the args I'm passing. Specifically, it's complaining that I'm not passing an org, so I try that with (as suggested) --org. It will then throw an error saying it doesn't recognize the option:

without org being passed

$ sentry-cli releases new $VERSION --project my-project

error: An organization slug is required (provide with --org)

with org being passed

$ sentry-cli releases new $VERSION --project my-project --org my-organization

error: Found argument '--org' which wasn't expected, or isn't valid in this context
@jan-auer
Copy link
Member

This is because the argument is given in the wrong place. It should be:

sentry-cli releases --org my-org new $VERSION --project my-project

@someguynamedmatt
Copy link
Author

someguynamedmatt commented Apr 29, 2020

@jan-auer Ah, okay. That does seem to work for me. However, I'm confused because in config.rs it appears that it should be reading it from the env var SENTRY_ORG, which is set in my case.

Can the documentation to be made more clear to help future users out?

Thanks for taking the time clarify!

@jan-auer
Copy link
Member

jan-auer commented Apr 29, 2020

it appears that it should be reading it from the env var SENTRY_ORG

That's right. For me it does work, at least when I invoke like this (for example):

SENTRY_ORG=foobar sentry-cli releases list

To test this, I've removed the org= key from my .sentryclirc to ensure there's nothing configured. Even without removing, the environment takes precedence. Does this not work in your case?

Can the documentation to be made more clear to help future users out?

Definitely. What part of the documentation can we extend, or where would you expect this? We have the Working with Projects section, but that's indeed a bit hard to find.

@someguynamedmatt
Copy link
Author

someguynamedmatt commented Apr 30, 2020

@jan-auer Okay. I figured out why my env var wasn't being picked (TL;DR: I didn't export the var in my shell).

As for the documentation, at the very least a link to that Working with Projects page would be immensely helpful somewhere on the Releases page. Ideally near:

Then we’re creating a release tagged VERSION for the organization my-org for projects project1 and project2.

since that's where that arg is first referenced. Again, thank you for the assistance.

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

Successfully merging a pull request may close this issue.

2 participants