-
Notifications
You must be signed in to change notification settings - Fork 1
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
Update crc_squeue #231
Update crc_squeue #231
Conversation
…into keystone_update
Output remaining SUs on each clsuter using keystone requests and sreport
…into keystone_update
Added warning message to notify users within 30 days of proposal expiration date.
Updated requests with group_id
…into keystone_update
Use Slurm utility function to check account
Import correct modules
* Update crc_proposal_end.py Added authentication procedure * Update crc_proposal_end.py * Update crc_proposal_end.py * Update crc_proposal_end.py Updated requests with group_id * Update crc_proposal_end.py Update requests * working version of crc_proposal_end * remove unused imports --------- Co-authored-by: Nickolas Comeau <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@chnixi Looking through this, I realized the arguments do not take in an account or set a default account to use as args.account
. If you can add that and test with a example AllocationRequest under the sam
group or something (you can set it up in the admin console for keystone from Viz) just so we know the functionality works, I think the changes here are OK to include. Otherwise we can try to add it as functionality separate from merging and tagging a release downstream of #233.
Check for expiration date of active proposals of default Slurm account
@chnixi There were some issues with the imports and some syntax errors that I fixed. The utility functions for touching keystone have been changed a bit since this last had main merged in. They should still return the right things, I think I just changed the names to be more accurate. Can you make the corresponding changes here? |
Updated keystone utility function name to get active requests
Not sure why it is giving the error "AttributeError: 'function' object has no attribute 'getuser". Did we change something in getpass? crc-scancel uses the same routine to get the user name. |
This is not importing You can change the import to |
Import entire getpass module
Fixed this, Now it is complaining about: 'username': os.environ["USER"], The call where this happens is the same as in crc-usage: |
Is the $USER environment variable defined in the shell you are running from? I'll see if I can reproduce the problem |
I see where you ran into that problem. It looks like the tests break in the CI when trying to find the |
Adding the call to keystone makes it impossible to run some of these tests properly because the CI can't get the password for authenticating, and even if it could it wouldn't be able to reach out deployment of keystone. I think we make an issue to rework utils so it can do it's functionality independent from the application logic for any given wrapper (Daniel gave me some note on how I might start doing this) and be more easily mocked in these tests. If we can test that the output for a expiring allocation shows up for this version of crc-squeue on the cluster, I'm content to merge it in and revisit the tests another time (or just defer until we have email notifications in place) |
Added warning message to notify users within 30 days of proposal expiration date.