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

.github_changelog_generator config file is not consistent with the internal options hash #312

Closed
stanislav-zaprudskiy opened this issue Dec 22, 2015 · 1 comment

Comments

@stanislav-zaprudskiy
Copy link

Currently, an option expected from the user is not usually consistent with the corresponding option hash key. For instance, --enhancement-label [LABEL] is stored as options[:enhancement_prefix] (_label part is stored as _prefix internally). This produces incompatibility with the parser_file.rb code.

That is why, there appear a situations similar to the following. One tries to use GitHub Enterprise, and provides the following entries in his .github_changelog_generator:

github-api=https://github.mycompany.com/api/v3
github-site=https://github.mycompany.com

Then, while invoking the binary, he receives the following error:

Bad credentials.
Error: wrong GitHub token

Since parser_file.rb placed github-api configuration entry as :github_api key in the hash, while :github_endpoint was expected. Then Github.new is being invoked as

{:per_page=>30, :oauth_token=>"eb188ed0b7ee67a7cf714f021ef2fcf48177ba75", :site=>nil}

which actually causes the error above. And that was not very straightforward to troubleshoot.

Do you think that is wise to add some additional conditionals/logics into parser_file.rb to deal with such non-conformant options? I might be able to take this on.

/CC: @dlanileonardo

@olleolleolle
Copy link
Collaborator

This is now released.

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

No branches or pull requests

2 participants