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

adapt manage_bootstrap_user.py to change in lib/galaxy/web/security introduced in Galaxy release_19.05 #61

Merged
merged 4 commits into from
Sep 29, 2019

Conversation

drosofff
Copy link
Member

see changes here galaxyproject/galaxy@528497f

The fix allows successfully bootstrapping a user in release_19.05 and preserves backward compatibility with < release_19.05

@bgruening
Copy link
Member

@drosofff I think there is a 19.05 branch. If you want to apply it to this one. I will merge 19.05 as soon as the release is out.

@drosofff
Copy link
Member Author

Hi @bgruening It's late I am sleepy: applying what ? ;-)

@bgruening
Copy link
Member

Oh, lol, no I'm sleepy all good. I thought that's the bootstrap script in ansible-extras :) Uha. going to bed now :)

@drosofff
Copy link
Member Author

Too many ansible roles ? ;-) Have a good night, I am going to bed too

@monprin
Copy link

monprin commented Jul 3, 2019

Is there an estimate for when this may be merged into master?

I am using this role in the deployment I am developing and would like to be able to use it with the most recent release.

@drosofff
Copy link
Member Author

drosofff commented Jul 8, 2019

Hi @bgruening
Any chance to get this PR reviewed ? I think @monprin would be as happy as me !
Chris

@drosofff
Copy link
Member Author

Hi,
@nuwang @afgane @mvdbeek you all three contributed to this code. Could you please help in resolving this PR ? This is required to accommodate the 19_05 galaxy release in GalaxyKickStart, as well as with this specific playbook of course.
Thanks for your help, the PR is opened since May 24th

Copy link
Member

@nuwang nuwang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Sorry about the delay - good that you pinged individual reviewers, it's easy to miss things because so many things are happening in so many repositories!

from galaxy.web import security

try:
from galaxy.web.security import SecurityHelper as Security
Copy link
Member

@mvdbeek mvdbeek Sep 27, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you switch this around so that the new import is tried first, and add a comment in the except clause that this maintains backwards compatibility with galaxy versions < 19.05 ? fwiw the PR that modified this was galaxyproject/galaxy#7560

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok, this is done, together with a bit of code cleaning

@@ -268,6 +277,7 @@ def delete_bootstrap_user(ini_file, username):
args = parser.parse_args()

if args.action == "create":
create_bootstrap_user(args.config, args.username, args.email, args.password, args.preset_api_key)
create_bootstrap_user(args.config, args.username, args.email,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When breaking up long argument lines we usually make this one argument per line:

Suggested change
create_bootstrap_user(args.config, args.username, args.email,
create_bootstrap_user(args.config,
args.username,
args.email,

@@ -268,6 +277,7 @@ def delete_bootstrap_user(ini_file, username):
args = parser.parse_args()

if args.action == "create":
create_bootstrap_user(args.config, args.username, args.email, args.password, args.preset_api_key)
create_bootstrap_user(args.config, args.username, args.email,
args.password, args.preset_api_key)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
args.password, args.preset_api_key)
args.password,
args.preset_api_key)

@mvdbeek mvdbeek merged commit 9b5d75f into galaxyproject:master Sep 29, 2019
@mvdbeek
Copy link
Member

mvdbeek commented Sep 29, 2019

Thanks @drosofff!

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 this pull request may close these issues.

5 participants