-
-
Notifications
You must be signed in to change notification settings - Fork 8
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
Add chart revision suggester and enhance World Bank WDI bulk import #5
Merged
Merged
Changes from all commits
Commits
Show all changes
18 commits
Select commit
Hold shift + click to select a range
cb456c1
wdi: add data cleaning script for 2021.03 dataset
bnjmacdonald e227507
wdi: add chart update scripts for 2021.03 dataset
bnjmacdonald 2de157f
bugfix: fix issue with long dataset namespace
bnjmacdonald 605c0e2
remove config + output files with hardcoded db ids
bnjmacdonald 4583a27
fix(wdi): attempt xls download if csv download fails
bnjmacdonald 770e1c8
refactor(worldbank_wdi): move suggested revision upsert code to `stan…
bnjmacdonald d54b583
data(worldbank_wdi): update WDI dataset to version 2021.05.25
bnjmacdonald 90f0fb6
fix(standard_importer): update `delete_dataset` to work with newly re…
bnjmacdonald ad42394
docs(readme): add more detail
bnjmacdonald 231f639
docs(standard_importer): minor doc improvements
bnjmacdonald bc7d17f
fix(worldbank_wdi): fix bug with reading xlsx via pandas
bnjmacdonald 80b22b4
fix(worldbank_wdi): fix error with >1 old variable version
bnjmacdonald 0699d38
fix(chart_revision_suggester): remove on duplicate key update
bnjmacdonald 0ecf4ff
refactor(chart_revision_suggester): minor refactoring
bnjmacdonald a349de4
style(chart_revision_suggester): add suggested changes
bnjmacdonald 6f5e878
style(chart_revision_suggester): autoformat with `black`
bnjmacdonald 14c28f7
style(import_dataset): autoformat with `black`
bnjmacdonald b3102d1
style(worldbank_wdi): autoformat with `black`
bnjmacdonald File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,3 +3,5 @@ DB_HOST="localhost" | |
DB_PORT=3306 | ||
DB_USER="user" | ||
DB_PASS="password" | ||
USER_ID=57 | ||
DEBUG=False |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
Sorry I haven't read this in detail, so totally uninformed question: Does this mean we are not importing all variables available in the WDI dataset? And if yes, is it possible to easily import others later?
Asking because as I understand, authors can decide to use any WDI variable at any point, it's likely not the case that the ones in the database are the only ones we want to use.
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.
That's correct – the variables stored in
variables_to_clean.json
at the end of step 2 are a subset of all variables in the dataset.In the case of the WDI bulk import in this PR, I've written
init_variables_to_clean.py
(which constructsvariables_to_clean.json
) so as to only keep the WDI variables that have been used in at least 1 chart.My thinking is that this is probably a good rule of thumb for effectively keeping db clutter to a minimum while still providing authors with >90% of the variables they are ever going to use. But more discussion is certainly needed here, and it would be easy enough to alter
init_variables_to_clean.py
to include more variables.