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

Make BC Project Code Entry Case Insensitive #383

Open
MorganRodgers opened this Issue Aug 3, 2018 · 12 comments

Comments

Projects
None yet
3 participants
@MorganRodgers
Copy link
Contributor

MorganRodgers commented Aug 3, 2018

OSC Project Codes are always upper case, so there is no need to have a case sensitive check.

@achalker

This comment has been minimized.

Copy link

achalker commented Aug 3, 2018

@MorganRodgers

This comment has been minimized.

Copy link
Contributor Author

MorganRodgers commented Aug 3, 2018

On the backend sure, or are you suggesting that even the frontend only show upper case letters?

@achalker

This comment has been minimized.

Copy link

achalker commented Aug 3, 2018

@ericfranz

This comment has been minimized.

Copy link
Contributor

ericfranz commented Aug 3, 2018

Sounds like an OSC specific change. Required discussion. I’d say it belongs in the ihpc apps but would be annoying to duplicate knowledge across a dozen repos.

@ericfranz

This comment has been minimized.

Copy link
Contributor

ericfranz commented Aug 3, 2018

To clarify: OSC’s “accounts” are uppercase. Utah is at least one site I can confirm that use accounts that are lowercase. There may be others.

@achalker

This comment has been minimized.

Copy link

achalker commented Aug 4, 2018

@ericfranz

This comment has been minimized.

Copy link
Contributor

ericfranz commented Aug 14, 2018

we got slightly confused today by the lowercase / uppercase issue in OnDemand

What is confusing? The submit filter produces this error when I put a lowercase account name in:

ERROR: Your job has not been submitted to Quick for the following reason:

Account "pzs0002" is not valid because it is malformed.
Please choose one of the following instead.

Available accounts: PZS0002 PZS0530 PZS0562 PAN0014 PAN0026 PAS1215 PAN0067 PMIU0149 PZS0705 PZS0714

@MorganRodgers

This comment has been minimized.

Copy link
Contributor Author

MorganRodgers commented Aug 14, 2018

I think 'annoyed' might more a more accurate description than 'confused'. If there was a notification that the project code is case sensitive that might be good enough.

@ericfranz

This comment has been minimized.

Copy link
Contributor

ericfranz commented Aug 14, 2018

Then the two options are:

  1. Open a Service Now ticket to request that Systems modify the error message to specify:

    Account "pzs0002" is not valid because it is malformed. Note that account strings are case sensitive.
    

    Though I'm not sure whether this is OSC's or Torque's error message, since "Account" and not "Project" is used

  2. Modify each of OSC's batch connect apps so that the help text says this is case sensitive: https://github.com/OSC/bc_osc_rstudio_server/blob/34b19d829c54c38b5c137b70937f867e47403065/form.yml#L21-L23

    i.e. screen 2018-08-14 at 3 37 47 pm

@ericfranz

This comment has been minimized.

Copy link
Contributor

ericfranz commented Aug 15, 2018

Talked offline with @achalker. A third option to explore is some type of configuration that affects the account value of all jobs. IMHO this should be done at the ood_core level and in the cluster config.

Essentially we want to do something like this:

class OSCScript < OodCore::Job::Script
  def accounting_id
    @accounting_id.upcase
  end
end

Or maybe we support an explicit config option for the job adapters, to forcing accounts to be uppercase or lowercase when submitting jobs.

@MorganRodgers

This comment has been minimized.

Copy link
Contributor Author

MorganRodgers commented Aug 15, 2018

This was more or less what I meant by 'on the backend'. For OSC users I think that this would be a preferable experience.

@ericfranz

This comment has been minimized.

Copy link
Contributor

ericfranz commented Aug 17, 2018

So we could have a very special case (use_allcaps_for_account: true in cluster config) or a very general "ood_core submit filter" per cluster (`submit_filter(script:) # accepts Script object, returns new "modified?" Script object), or something in between.

@ericfranz ericfranz added this to the OOD1.5 milestone Jan 9, 2019

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