-
Notifications
You must be signed in to change notification settings - Fork 9
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
fix(finngen_study_index): improved tests for finngen study index #776
Conversation
@DSuveges tagged you as I want to understand if non changed sample size is going to affect much of downstream processing. If so, the previous size was used from R9 (R10 also used R9 sample size in our dags) |
The sample size doesn't have any downstream application besides showing on the UI. Relative sample sizes ( |
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.
Great test suite, however it would likely to be a pain to actualise when moving on to R12.
What do you mean exactly? What will be hard to actualise ? I expect that the |
Ah, OK, so these example datasets in the test: {
"assoc_files": [
"/cromwell_root/pheweb/generated-by-pheweb/pheno_gz/GLUCOSE.gz"
],
"category": "Glucose",
"category_index": 28,
"gc_lambda": {
"0.001": 1.1251,
"0.01": 1.062,
"0.1": 1.0531,
"0.5": 1.0599,
},
"num_cases": 43764,
"num_cases_prev": 39231,
"num_controls": 409969,
"num_controls_prev": 372950,
"num_gw_significant": 3,
"num_gw_significant_prev": 3,
"phenocode": "GLUCOSE",
"phenostring": "Glucose",
} Serves as mock for modelling the schema. |
@DSuveges just to clear things up. |
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.
This PR improves extensively the tests to generate a study index from Finngen, and updates the sample size values to match Finngen R11. I expect that tests won't fail when a new release is out as long as the input format is the same.
Approving, but please see my comments
✨ Context
This PR closes opentargets/issues#3484
The overall issue affecting CI tests was the get request to the
https://r11.finngen.fi/api/phenos
.In addition to this, I have found a few more things worth resolving and improved the test coverage of the step overall.
🛠 What does this PR implement
This PR implements following things:
urllib.request.urlopen
function to mimic get requests forstep_tests
marks to the pytest to be able to isolate integration tests from unit tests🙈 Missing
🚦 Before submitting
dev
branch?make test
)?poetry run pre-commit run --all-files
)?