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

param to run ALL GO rules in ontobio-parse-assocs does not run all rules #558

Closed
dustine32 opened this issue May 14, 2021 · 2 comments · Fixed by #559
Closed

param to run ALL GO rules in ontobio-parse-assocs does not run all rules #558

dustine32 opened this issue May 14, 2021 · 2 comments · Fixed by #559

Comments

@dustine32
Copy link
Collaborator

Related to #544

@dougli1sqrd Was having some trouble getting all rules to run using the new -l all param. I had a WB GPAD with two lines annotated to CC root but they used relation located_in, which violates GO rule 61. These didn't get repaired when running ontobio-parse-assocs.py with the -l all param.

Throwing on my debugger, I traced it to this line in assocparser.py:

elif rule_set == RuleSet.ALL:

Here, rule_set was coming in as list ["all"] but RuleSet.ALL is just the str "all":
ALL: ClassVar[str] = "all"

To fix, I just "listified" RuleSet.ALL in the conditional:

elif rule_set == [RuleSet.ALL]:

@dougli1sqrd I can PR this change and you can trash it if you don't like it. Thanks!

@dougli1sqrd
Copy link
Contributor

Oh good catch. The reason, though, this is coming in as a list is because the command line option in ontobio-parse-assocs is being created as a list, so "all" is being inserted as an item.

My thought is that since this is an artifact of the argument parsing, we should parse that there in ontobio-parse-assocs. If the incoming args.rule_set contains RuleSet.ALL then we should just set the config to be RuleSet.ALL rather than a list, as expected by the logic in the config init.

@dustine32
Copy link
Collaborator Author

@dougli1sqrd Thanks! I just corrected it in the PR.

dustine32 added a commit that referenced this issue May 19, 2021
Fixing ontobio-parse-assocs to run all rules; for #558
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 a pull request may close this issue.

2 participants