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

ACAS-1023 -- Adjusted checkExistance to use FindByProtocolNameLike #85

Conversation

philippcheung
Copy link

Description

Related Issue

How Has This Been Tested?

@philippcheung philippcheung self-assigned this Jun 20, 2023
@philippcheung
Copy link
Author

Hi @brianbolt -- this is pull request that is dependent upon mcneilco/acas-roo-server#444, which implements a protocol name like. Let me know the best way to tie these pull requests together.

Thanks!

Phil

Copy link
Contributor

@brianbolt brianbolt left a comment

Choose a reason for hiding this comment

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

Overall this LGTM but a few changes I think needed:

  • Can you fill in a Description and How it was tested?
  • I think the user should be warned that the protocol they entered in the upload sheet is different than what was entered. That is, once the R code recognizes that there is a match, get the name and compare exact with what they entered. If it's not an exact match then do something like:
  • untested just wrote this inline
protcolNameLabel <- paste0(racas::applicationSettings$client.protocol.label, " name")
warnUser(paste0("The ", protcolNameLabel, " you entered '", protocolName, "' does not exactly match the ", protocolNameLabel, " found.")
  • This seems like something we should have acasclient tests for. A test where you upload a file with a unique protocol name which has upper case characters, then you load the file again with lower case. The test should verify that the warnings are thrown (there are example in the acasclient tests for checking warnings/errors, and also that if you proceed, the file is uploaded to the correct protocol.

@brianbolt brianbolt requested a review from bffrost June 23, 2023 16:10
@brianbolt
Copy link
Contributor

Added @bffrost just so he's aware of this incoming change.

@bffrost
Copy link
Contributor

bffrost commented Jun 23, 2023

Thanks @brianbolt . I agree with your feedback. Right now if I understand this correctly, it seems like this change would prevent users from creating any two protocols where one's name is a substring of the other's name.
This whole feature makes sense if it's a "did you mean?" type check where the user gets warned about the similarly-named protocol but isn't blocked.

FWIW we had a similar feature request from the Data Team:

Add Fuzzy/Levenshtein Matching to Existing Assay Protocols on Creation
Something that would be of great value and assistance to the team would be additional redundancy checking on the creation of a new protocol to avoid the creation of divergent or redundant protocol names.
Currently, ACAS will prompt us if a user is creating a duplicate name, but we'd also like checking for case-insensitivity, and protocol name fuzzy matching or Levenshtein distance to existing protocol names.
The expected result would be such that if a user is trying to create a new protocol ADME_mLM, on-create ACAS would prompt us if a protocol called adme_mlm already exists, and would return an array of (95% or so) similar matches: ["ADME_hLM", "ADME_dogLM", etc].
The user would then have to opt to continue with the creation process. Similar to the dry-run ACAS experiment loading process.

@philippcheung any interest in extending your Roo implementation to do a fuzzy match instead of just a "like"?

@bffrost bffrost closed this Oct 11, 2024
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.

3 participants