hdx-python-scraper 2.4.1__tar.gz → 2.5.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (134) hide show
  1. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/.config/pre-commit-config.yaml +2 -2
  2. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/CONTRIBUTING.md +2 -2
  3. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/PKG-INFO +3 -3
  4. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/documentation/main.md +4 -2
  5. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/documentation/pydoc-markdown.yaml +11 -14
  6. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/pyproject.toml +3 -3
  7. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/requirements.txt +32 -46
  8. {hdx_python_scraper-2.4.1/src/hdx/scraper → hdx_python_scraper-2.5.0/src/hdx/scraper/framework}/__init__.py +0 -0
  9. {hdx_python_scraper-2.4.1/src/hdx/scraper → hdx_python_scraper-2.5.0/src/hdx/scraper/framework}/_version.py +2 -2
  10. {hdx_python_scraper-2.4.1/src/hdx/scraper → hdx_python_scraper-2.5.0/src/hdx/scraper/framework}/runner.py +4 -4
  11. {hdx_python_scraper-2.4.1/tests/hdx/scraper → hdx_python_scraper-2.5.0/tests/hdx/scraper/framework}/conftest.py +4 -4
  12. hdx_python_scraper-2.5.0/tests/hdx/scraper/framework/custom/__init__.py +0 -0
  13. {hdx_python_scraper-2.4.1/tests/hdx/scraper → hdx_python_scraper-2.5.0/tests/hdx/scraper/framework/custom}/affected_targeted_reached.py +2 -2
  14. {hdx_python_scraper-2.4.1/tests/hdx/scraper → hdx_python_scraper-2.5.0/tests/hdx/scraper/framework/custom}/education_closures.py +1 -1
  15. {hdx_python_scraper-2.4.1/tests/hdx/scraper → hdx_python_scraper-2.5.0/tests/hdx/scraper/framework/custom}/education_enrolment.py +1 -1
  16. hdx_python_scraper-2.4.1/tests/hdx/scraper/test_scrapers_custom.py → hdx_python_scraper-2.5.0/tests/hdx/scraper/framework/custom/test_custom.py +5 -5
  17. hdx_python_scraper-2.5.0/tests/hdx/scraper/framework/outputs/__init__.py +0 -0
  18. {hdx_python_scraper-2.4.1/tests/hdx/scraper → hdx_python_scraper-2.5.0/tests/hdx/scraper/framework/outputs}/test_output.py +4 -4
  19. hdx_python_scraper-2.5.0/tests/hdx/scraper/framework/scrapers/__init__.py +0 -0
  20. hdx_python_scraper-2.4.1/tests/hdx/scraper/test_scrapers_aggregation.py → hdx_python_scraper-2.5.0/tests/hdx/scraper/framework/scrapers/test_aggregation.py +5 -5
  21. hdx_python_scraper-2.4.1/tests/hdx/scraper/test_scrapers_appenddata.py → hdx_python_scraper-2.5.0/tests/hdx/scraper/framework/scrapers/test_appenddata.py +7 -7
  22. hdx_python_scraper-2.4.1/tests/hdx/scraper/test_scrapers_global.py → hdx_python_scraper-2.5.0/tests/hdx/scraper/framework/scrapers/test_global.py +4 -4
  23. hdx_python_scraper-2.4.1/tests/hdx/scraper/test_scrapers_multipleurls.py → hdx_python_scraper-2.5.0/tests/hdx/scraper/framework/scrapers/test_multipleurls.py +4 -4
  24. hdx_python_scraper-2.4.1/tests/hdx/scraper/test_scrapers_national.py → hdx_python_scraper-2.5.0/tests/hdx/scraper/framework/scrapers/test_national.py +7 -7
  25. hdx_python_scraper-2.4.1/tests/hdx/scraper/test_scrapers_regionaltoplevel.py → hdx_python_scraper-2.5.0/tests/hdx/scraper/framework/scrapers/test_regionaltoplevel.py +7 -7
  26. hdx_python_scraper-2.4.1/tests/hdx/scraper/test_scrapers_resource_downloaders.py → hdx_python_scraper-2.5.0/tests/hdx/scraper/framework/scrapers/test_resource_downloaders.py +3 -3
  27. hdx_python_scraper-2.4.1/tests/hdx/scraper/test_scrapers_subnational.py → hdx_python_scraper-2.5.0/tests/hdx/scraper/framework/scrapers/test_subnational.py +6 -6
  28. hdx_python_scraper-2.4.1/tests/hdx/scraper/test_scrapers_timeseries.py → hdx_python_scraper-2.5.0/tests/hdx/scraper/framework/scrapers/test_timeseries.py +4 -4
  29. {hdx_python_scraper-2.4.1/tests/hdx/scraper → hdx_python_scraper-2.5.0/tests/hdx/scraper/framework}/test_runner.py +2 -2
  30. hdx_python_scraper-2.5.0/tests/hdx/scraper/framework/utilities/__init__.py +0 -0
  31. {hdx_python_scraper-2.4.1/tests/hdx/scraper → hdx_python_scraper-2.5.0/tests/hdx/scraper/framework/utilities}/test_readers.py +1 -1
  32. {hdx_python_scraper-2.4.1/tests/hdx/scraper → hdx_python_scraper-2.5.0/tests/hdx/scraper/framework/utilities}/test_regionlookup.py +1 -1
  33. {hdx_python_scraper-2.4.1/tests/hdx/scraper → hdx_python_scraper-2.5.0/tests/hdx/scraper/framework/utilities}/test_sources.py +5 -3
  34. {hdx_python_scraper-2.4.1/tests/hdx/scraper → hdx_python_scraper-2.5.0/tests/hdx/scraper/framework/utilities}/test_utils.py +1 -1
  35. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/.config/coveragerc +0 -0
  36. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/.config/pytest.ini +0 -0
  37. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/.config/ruff.toml +0 -0
  38. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/.github/workflows/publish.yaml +0 -0
  39. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/.github/workflows/run-python-tests.yaml +0 -0
  40. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/.gitignore +0 -0
  41. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/LICENSE +0 -0
  42. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/README.md +0 -0
  43. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/documentation/.readthedocs.yaml +0 -0
  44. {hdx_python_scraper-2.4.1/src/hdx/scraper → hdx_python_scraper-2.5.0/src/hdx/scraper/framework}/base_scraper.py +0 -0
  45. {hdx_python_scraper-2.4.1/src/hdx/scraper/configurable → hdx_python_scraper-2.5.0/src/hdx/scraper/framework/outputs}/__init__.py +0 -0
  46. {hdx_python_scraper-2.4.1/src/hdx/scraper → hdx_python_scraper-2.5.0/src/hdx/scraper/framework}/outputs/base.py +0 -0
  47. {hdx_python_scraper-2.4.1/src/hdx/scraper → hdx_python_scraper-2.5.0/src/hdx/scraper/framework}/outputs/excelfile.py +0 -0
  48. {hdx_python_scraper-2.4.1/src/hdx/scraper → hdx_python_scraper-2.5.0/src/hdx/scraper/framework}/outputs/googlesheets.py +0 -0
  49. {hdx_python_scraper-2.4.1/src/hdx/scraper → hdx_python_scraper-2.5.0/src/hdx/scraper/framework}/outputs/json.py +0 -0
  50. {hdx_python_scraper-2.4.1/src/hdx/scraper/outputs → hdx_python_scraper-2.5.0/src/hdx/scraper/framework/scrapers}/__init__.py +0 -0
  51. {hdx_python_scraper-2.4.1/src/hdx/scraper/configurable → hdx_python_scraper-2.5.0/src/hdx/scraper/framework/scrapers}/aggregator.py +0 -0
  52. /hdx_python_scraper-2.4.1/src/hdx/scraper/configurable/scraper.py → /hdx_python_scraper-2.5.0/src/hdx/scraper/framework/scrapers/configurable_scraper.py +0 -0
  53. {hdx_python_scraper-2.4.1/src/hdx/scraper/configurable → hdx_python_scraper-2.5.0/src/hdx/scraper/framework/scrapers}/resource_downloader.py +0 -0
  54. {hdx_python_scraper-2.4.1/src/hdx/scraper/configurable → hdx_python_scraper-2.5.0/src/hdx/scraper/framework/scrapers}/rowparser.py +0 -0
  55. {hdx_python_scraper-2.4.1/src/hdx/scraper/configurable → hdx_python_scraper-2.5.0/src/hdx/scraper/framework/scrapers}/timeseries.py +0 -0
  56. {hdx_python_scraper-2.4.1/src/hdx/scraper → hdx_python_scraper-2.5.0/src/hdx/scraper/framework}/utilities/__init__.py +0 -0
  57. {hdx_python_scraper-2.4.1/src/hdx/scraper → hdx_python_scraper-2.5.0/src/hdx/scraper/framework}/utilities/fallbacks.py +0 -0
  58. {hdx_python_scraper-2.4.1/src/hdx/scraper → hdx_python_scraper-2.5.0/src/hdx/scraper/framework}/utilities/reader.py +0 -0
  59. {hdx_python_scraper-2.4.1/src/hdx/scraper → hdx_python_scraper-2.5.0/src/hdx/scraper/framework}/utilities/region_lookup.py +0 -0
  60. {hdx_python_scraper-2.4.1/src/hdx/scraper → hdx_python_scraper-2.5.0/src/hdx/scraper/framework}/utilities/sources.py +0 -0
  61. {hdx_python_scraper-2.4.1/src/hdx/scraper → hdx_python_scraper-2.5.0/src/hdx/scraper/framework}/utilities/writer.py +0 -0
  62. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/config/project_configuration.yaml +0 -0
  63. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/access_2pacx-1vrszjzuyvt9i-mkrq2hbxrul2lx2vihkthqm-lae8nyhqty70zqtcufs3pxbhzgat1l2bkoa4-daoap-pub-gid-574237756-single-true-output-csv.csv +0 -0
  64. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/additional-json.json +0 -0
  65. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/altworldindata_data-tagger-match-all-on-tagger-01-header-location-tagger-01-tag.csv +0 -0
  66. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/casualties_2pacx-1vqidedbzz0ehrc0b4fswip14r7mdtu1mpmwakuxupelsah2awcurkgalfduhjvyjul8vzzat3r1b5qg-pub-gid-0-single-true-output-csv.csv +0 -0
  67. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/cbpf-allocations-and-contributions.json +0 -0
  68. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/cbpf2-allocations-and-contributions.json +0 -0
  69. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/cerf-covid-19-allocations.json +0 -0
  70. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/cerf2-covid-19-allocations.json +0 -0
  71. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/cerf2_global_download-full-pfmb-allocations.csv +0 -0
  72. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/cerf_global_download-full-pfmb-allocations.csv +0 -0
  73. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/covax_2pacx-1vtvzu79pptfaa2syevoqfyrrjy63djwitqu0ffbxiqczoun9k9timwmrvfgg1rbsnlmgyugzseiaye2-pub-gid-992438980-single-true-output-csv.csv +0 -0
  74. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/covidtests_data-owid-covid-data.xlsx +0 -0
  75. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/education_closures_broken.xls +0 -0
  76. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/education_closures_school_closures.csv +0 -0
  77. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/education_enrolment_enrollment_data.xlsx +0 -0
  78. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/ethiopia-drought-related-key-figures.json +0 -0
  79. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/ethiopia-pin-targeted-reached-by-location-and-cluster.json +0 -0
  80. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/ethiopia_drought_affected_targeted_reached_by_cluster.csv +0 -0
  81. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/fallbacks.json +0 -0
  82. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/gam_download-unicef-who-wb-global-expanded-databases-severe-wasting.xlsx +0 -0
  83. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/gam_other_download-unicef-who-wb-global-expanded-databases-severe-wasting.xlsx +0 -0
  84. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/global-school-closures-covid19.json +0 -0
  85. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/hno_2017_sahel_nutrition.csv +0 -0
  86. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/hno_2017_sahel_people_in_need.xlsx +0 -0
  87. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/idmc-internally-displaced-persons-idps.json +0 -0
  88. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/idps_download-displacement-data.csv +0 -0
  89. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/idps_override_population-widget-id-264111-geo-id-693-population-group-54074999.json +0 -0
  90. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/idps_somalia_som_unhcr_prmn_displacement_dataset.xlsx +0 -0
  91. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/ipc_somalia_som_food_insecurity_oct_dec2022_projection.csv +0 -0
  92. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/kenya-drought-related-key-figures.json +0 -0
  93. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/kenya-pin-targeted-reached-by-location-and-cluster.json +0 -0
  94. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/kenya_drought_affected_targeted_reached_by_cluster.csv +0 -0
  95. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/key_figures_2pacx-1vrppqx8jtkkkrckmzfncmmtfecvcpkbp9pdhs1sqtuyacmbsx8tlaxpgblfce-lcehukregguxja-4s-pub-gid-0-single-true-output-csv.csv +0 -0
  96. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/key_figures_2pacx-1vrppqx8jtkkkrckmzfncmmtfecvcpkbp9pdhs1sqtuyacmbsx8tlaxpgblfce-lcehukregguxja-4s-pub-gid-1275038715-single-true-output-csv.csv +0 -0
  97. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/key_figures_2pacx-1vrppqx8jtkkkrckmzfncmmtfecvcpkbp9pdhs1sqtuyacmbsx8tlaxpgblfce-lcehukregguxja-4s-pub-gid-2015311116-single-true-output-csv.csv +0 -0
  98. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/key_figures_eth_2pacx-1vrppqx8jtkkkrckmzfncmmtfecvcpkbp9pdhs1sqtuyacmbsx8tlaxpgblfce-lcehukregguxja-4s-pub-gid-2015311116-single-true-output-csv.csv +0 -0
  99. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/key_figures_ken_2pacx-1vrppqx8jtkkkrckmzfncmmtfecvcpkbp9pdhs1sqtuyacmbsx8tlaxpgblfce-lcehukregguxja-4s-pub-gid-1275038715-single-true-output-csv.csv +0 -0
  100. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/key_figures_som_2pacx-1vrppqx8jtkkkrckmzfncmmtfecvcpkbp9pdhs1sqtuyacmbsx8tlaxpgblfce-lcehukregguxja-4s-pub-gid-0-single-true-output-csv.csv +0 -0
  101. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/ourworldindata_data-tagger-match-all-on-tagger-01-header-location-tagger-01-tag.csv +0 -0
  102. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/ourworldindata_other_data-tagger-match-all-on-tagger-01-header-location-tagger-01-tag.csv +0 -0
  103. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/oxcgrt_oxcgrt_csv.csv +0 -0
  104. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/oxford-covid-19-government-response-tracker.json +0 -0
  105. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/population.json +0 -0
  106. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/population_indicator-sp-pop-downloadformat-excel-dataformat-list-totl.xls +0 -0
  107. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/population_other_indicator-sp-pop-downloadformat-excel-dataformat-list-totl.xls +0 -0
  108. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/regions_tbl_regcov_2020_ocha.xlsx +0 -0
  109. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/resource_downloader_xlsx_ukr_border_crossings_090622.xlsx +0 -0
  110. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/sadd-countries-to-include.csv +0 -0
  111. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/sadd_covid-data-dataset-fullvars-extype-csv.csv +0 -0
  112. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/sahel-humanitarian-needs-overview.json +0 -0
  113. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/sahel-humanitarian-needs-overview_prefix.json +0 -0
  114. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/somalia-acute-food-insecurity-country-data.json +0 -0
  115. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/somalia-drought-related-key-figures.json +0 -0
  116. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/somalia-internally-displaced-persons-idps.json +0 -0
  117. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/somalia-pin-targeted-reached-by-location-and-cluster.json +0 -0
  118. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/somalia_drought_affected_targeted_reached_by_cluster.csv +0 -0
  119. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/timeseries_casualties_2pacx-1vqidedbzz0ehrc0b4fswip14r7mdtu1mpmwakuxupelsah2awcurkgalfduhjvyjul8vzzat3r1b5qg-pub-gid-0-single-true-output-csv.csv +0 -0
  120. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/total-covid-19-tests-performed-by-country.json +0 -0
  121. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/ukraine-border-crossings.json +0 -0
  122. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/ukraine-who-does-what-where-3w.json +0 -0
  123. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/unocha-office-locations.json +0 -0
  124. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/who_national2_who-covid-19-global-data.csv +0 -0
  125. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/who_national3_who-covid-19-global-data.csv +0 -0
  126. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/who_national_who-covid-19-global-data.csv +0 -0
  127. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/whowhatwhere_afg_3w_data.csv +0 -0
  128. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/input/whowhatwhere_notags_3w_data.csv +0 -0
  129. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/test_output.xlsx +0 -0
  130. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/test_scraper_all.json +0 -0
  131. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/test_scraper_other.json +0 -0
  132. {hdx_python_scraper-2.4.1 → hdx_python_scraper-2.5.0}/tests/fixtures/test_scraper_population.json +0 -0
  133. {hdx_python_scraper-2.4.1/tests/hdx/scraper → hdx_python_scraper-2.5.0/tests/hdx/scraper/framework}/__init__.py +0 -0
  134. {hdx_python_scraper-2.4.1/tests/hdx/scraper → hdx_python_scraper-2.5.0/tests/hdx/scraper/framework/scrapers}/unhcr_myanmar_idps.py +0 -0
@@ -9,7 +9,7 @@ repos:
9
9
  exclude: test_scraper_.*\.json
10
10
  - id: check-ast
11
11
  - repo: https://github.com/astral-sh/ruff-pre-commit
12
- rev: v0.5.1
12
+ rev: v0.6.4
13
13
  hooks:
14
14
  # Run the linter.
15
15
  - id: ruff
@@ -18,7 +18,7 @@ repos:
18
18
  - id: ruff-format
19
19
  args: [--config, .config/ruff.toml]
20
20
  - repo: https://github.com/astral-sh/uv-pre-commit
21
- rev: 0.2.13
21
+ rev: 0.4.7
22
22
  hooks:
23
23
  # Run the pip compile
24
24
  - id: pip-compile
@@ -2,10 +2,10 @@
2
2
 
3
3
  ## Environment
4
4
 
5
- Development is currently done using Python 3.11. We recommend using a virtual
5
+ Development is currently done using Python 3.12. We recommend using a virtual
6
6
  environment such as ``venv``:
7
7
 
8
- python3.11 -m venv venv
8
+ python3.12 -m venv venv
9
9
  source venv/bin/activate
10
10
 
11
11
  In your virtual environment, please install all packages for
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: hdx-python-scraper
3
- Version: 2.4.1
3
+ Version: 2.5.0
4
4
  Summary: HDX Python scraper utilities to assemble data from multiple sources
5
5
  Project-URL: Homepage, https://github.com/OCHA-DAP/hdx-python-scraper
6
6
  Author-email: Michael Rans <rans@email.com>
@@ -26,8 +26,8 @@ Classifier: Programming Language :: Python :: 3.12
26
26
  Classifier: Topic :: Software Development :: Libraries :: Python Modules
27
27
  Requires-Python: >=3.8
28
28
  Requires-Dist: gspread
29
- Requires-Dist: hdx-python-api>=6.3.2
30
- Requires-Dist: hdx-python-country>=3.7.6
29
+ Requires-Dist: hdx-python-api>=6.3.4
30
+ Requires-Dist: hdx-python-country>=3.7.8
31
31
  Requires-Dist: hdx-python-utilities>=3.7.3
32
32
  Requires-Dist: regex
33
33
  Provides-Extra: dev
@@ -26,6 +26,8 @@ install with:
26
26
  pip install hdx-python-scraper[pandas]
27
27
 
28
28
  ## Breaking Changes
29
+ From 2.5.0, package names have changed to avoid name space clashes
30
+
29
31
  From 2.3.0, resource name is used when available instead of creating name from
30
32
  url so tests that use saved data from the Read class may break. file_type
31
33
  parameters in various Read methods renamed to format.
@@ -335,7 +337,7 @@ default is:
335
337
  ### Custom Scrapers
336
338
 
337
339
  It is possible to define custom scrapers written in Python which must inherit
338
- [BaseScraper](https://github.com/OCHA-DAP/hdx-python-scraper/blob/main/src/hdx/scraper/base_scraper.py),
340
+ [BaseScraper](https://github.com/OCHA-DAP/hdx-python-scraper/blob/main/src/hdx/scraper/framework/base_scraper.py),
339
341
  calling its constructor and providing a `run` method. Other methods where a default
340
342
  implementation has been provided can be overridden such as `add_sources` and
341
343
  `add_population`. There are also two hooks for running steps at particular points.
@@ -392,7 +394,7 @@ from regions to values. In this case, since national and regional each have only
392
394
  header and HXL hashtag, there is only one dictionary to populate for each.
393
395
 
394
396
  An example of a custom scraper can be seen
395
- [here](https://github.com/OCHA-DAP/hdx-python-scraper/blob/main/tests/hdx/scraper/education_closures.py).
397
+ [here](https://github.com/OCHA-DAP/hdx-python-scraper/blob/main/tests/hdx/scraper/framework/scrapers/education_closures.py).
396
398
 
397
399
  An example of overriding `add_sources` to customise the source information that is
398
400
  output is as follows:
@@ -3,7 +3,7 @@ loaders:
3
3
  search_path:
4
4
  - ../src
5
5
  packages:
6
- - hdx.scraper
6
+ - hdx.scraper.framework
7
7
  renderer:
8
8
  type: mkdocs
9
9
  output_directory: docs
@@ -21,21 +21,18 @@ renderer:
21
21
  source: main.md
22
22
  - title: API Documentation
23
23
  children:
24
- - title: Source Readers
24
+ - title: Runner
25
25
  contents:
26
- - hdx.scraper.utilities.readers.*
27
- - title: Configurable Scrapers
26
+ - hdx.scraper.framework.runner.Runner.*
27
+ - title: Scraper Base Class
28
28
  contents:
29
- - hdx.scraper.configurable.*
30
- - title: Base Class for Scrapers
29
+ - hdx.scraper.framework.base_scraper.BaseScraper.*
30
+ - title: Scrapers
31
31
  contents:
32
- - hdx.scraper.base_scraper.BaseScraper.*
33
- - title: Fallbacks
34
- contents:
35
- - hdx.scraper.utilities.fallbacks.Fallbacks
36
- - title: Run Scrapers
37
- contents:
38
- - hdx.scraper.runner.Runner.*
32
+ - hdx.scraper.framework.scrapers.*
39
33
  - title: Outputs
40
34
  contents:
41
- - hdx.scraper.outputs.*
35
+ - hdx.scraper.framework.outputs.*
36
+ - title: Utilities
37
+ contents:
38
+ - hdx.scraper.framework.utilities.*
@@ -34,8 +34,8 @@ classifiers = [
34
34
  requires-python = ">=3.8"
35
35
 
36
36
  dependencies = [
37
- "hdx-python-api>=6.3.2",
38
- "hdx-python-country>=3.7.6",
37
+ "hdx-python-api>=6.3.4",
38
+ "hdx-python-country>=3.7.8",
39
39
  "hdx-python-utilities>=3.7.3",
40
40
  "gspread",
41
41
  "regex",
@@ -65,7 +65,7 @@ dev = ["pre-commit"]
65
65
  packages = ["src/hdx"]
66
66
 
67
67
  [tool.hatch.build.hooks.vcs]
68
- version-file = "src/hdx/scraper/_version.py"
68
+ version-file = "src/hdx/scraper/framework/_version.py"
69
69
 
70
70
  # Versioning
71
71
 
@@ -2,18 +2,16 @@
2
2
  # uv pip compile pyproject.toml --resolver=backtracking --all-extras -o requirements.txt
3
3
  annotated-types==0.7.0
4
4
  # via pydantic
5
- attrs==23.2.0
5
+ attrs==24.2.0
6
6
  # via
7
7
  # frictionless
8
8
  # jsonlines
9
9
  # jsonschema
10
10
  # referencing
11
- cachetools==5.4.0
11
+ cachetools==5.5.0
12
12
  # via google-auth
13
- certifi==2024.7.4
13
+ certifi==2024.8.30
14
14
  # via requests
15
- cffi==1.16.0
16
- # via cryptography
17
15
  cfgv==3.4.0
18
16
  # via pre-commit
19
17
  chardet==5.2.0
@@ -24,10 +22,8 @@ ckanapi==4.8
24
22
  # via hdx-python-api
25
23
  click==8.1.7
26
24
  # via typer
27
- coverage==7.6.0
25
+ coverage==7.6.1
28
26
  # via pytest-cov
29
- cryptography==43.0.0
30
- # via pyopenssl
31
27
  defopt==6.4.0
32
28
  # via hdx-python-api
33
29
  distlib==0.3.8
@@ -44,11 +40,11 @@ email-validator==2.2.0
44
40
  # via hdx-python-api
45
41
  et-xmlfile==1.1.0
46
42
  # via openpyxl
47
- filelock==3.15.4
43
+ filelock==3.16.0
48
44
  # via virtualenv
49
- frictionless==5.17.0
45
+ frictionless==5.17.1
50
46
  # via hdx-python-utilities
51
- google-auth==2.32.0
47
+ google-auth==2.34.0
52
48
  # via
53
49
  # google-auth-oauthlib
54
50
  # gspread
@@ -56,9 +52,9 @@ google-auth-oauthlib==1.2.1
56
52
  # via gspread
57
53
  gspread==6.1.2
58
54
  # via hdx-python-scraper (pyproject.toml)
59
- hdx-python-api==6.3.2
55
+ hdx-python-api==6.3.4
60
56
  # via hdx-python-scraper (pyproject.toml)
61
- hdx-python-country==3.7.7
57
+ hdx-python-country==3.7.8
62
58
  # via
63
59
  # hdx-python-scraper (pyproject.toml)
64
60
  # hdx-python-api
@@ -69,15 +65,15 @@ hdx-python-utilities==3.7.3
69
65
  # hdx-python-country
70
66
  humanize==4.10.0
71
67
  # via frictionless
72
- identify==2.6.0
68
+ identify==2.6.1
73
69
  # via pre-commit
74
- idna==3.7
70
+ idna==3.10
75
71
  # via
76
72
  # email-validator
77
73
  # requests
78
74
  ijson==3.3.0
79
75
  # via hdx-python-utilities
80
- inflect==7.3.1
76
+ inflect==7.4.0
81
77
  # via quantulum3
82
78
  iniconfig==2.0.0
83
79
  # via pytest
@@ -111,15 +107,13 @@ markupsafe==2.1.5
111
107
  # via jinja2
112
108
  mdurl==0.1.2
113
109
  # via markdown-it-py
114
- more-itertools==10.3.0
110
+ more-itertools==10.5.0
115
111
  # via inflect
116
- ndg-httpsclient==0.5.1
117
- # via hdx-python-api
118
112
  nodeenv==1.9.1
119
113
  # via pre-commit
120
114
  num2words==0.5.13
121
115
  # via quantulum3
122
- numpy==2.0.1
116
+ numpy==2.1.1
123
117
  # via pandas
124
118
  oauthlib==3.2.2
125
119
  # via requests-oauthlib
@@ -131,7 +125,7 @@ pandas==2.2.2
131
125
  # via hdx-python-scraper (pyproject.toml)
132
126
  petl==1.7.15
133
127
  # via frictionless
134
- platformdirs==4.2.2
128
+ platformdirs==4.3.3
135
129
  # via virtualenv
136
130
  pluggy==1.5.0
137
131
  # via pytest
@@ -143,29 +137,21 @@ pockets==0.9.1
143
137
  # via sphinxcontrib-napoleon
144
138
  pre-commit==3.8.0
145
139
  # via hdx-python-scraper (pyproject.toml)
146
- pyasn1==0.6.0
140
+ pyasn1==0.6.1
147
141
  # via
148
- # hdx-python-api
149
- # ndg-httpsclient
150
142
  # pyasn1-modules
151
143
  # rsa
152
- pyasn1-modules==0.4.0
144
+ pyasn1-modules==0.4.1
153
145
  # via google-auth
154
- pycparser==2.22
155
- # via cffi
156
- pydantic==2.8.2
146
+ pydantic==2.9.1
157
147
  # via frictionless
158
- pydantic-core==2.20.1
148
+ pydantic-core==2.23.3
159
149
  # via pydantic
160
150
  pygments==2.18.0
161
151
  # via rich
162
- pyopenssl==24.2.1
163
- # via
164
- # hdx-python-api
165
- # ndg-httpsclient
166
152
  pyphonetics==0.5.3
167
153
  # via hdx-python-country
168
- pytest==8.3.2
154
+ pytest==8.3.3
169
155
  # via
170
156
  # hdx-python-scraper (pyproject.toml)
171
157
  # pytest-cov
@@ -183,9 +169,9 @@ python-slugify==8.0.4
183
169
  # via
184
170
  # ckanapi
185
171
  # frictionless
186
- pytz==2024.1
172
+ pytz==2024.2
187
173
  # via pandas
188
- pyyaml==6.0.1
174
+ pyyaml==6.0.2
189
175
  # via
190
176
  # frictionless
191
177
  # pre-commit
@@ -198,7 +184,7 @@ referencing==0.35.1
198
184
  # via
199
185
  # jsonschema
200
186
  # jsonschema-specifications
201
- regex==2024.7.24
187
+ regex==2024.9.11
202
188
  # via hdx-python-scraper (pyproject.toml)
203
189
  requests==2.32.3
204
190
  # via
@@ -214,9 +200,9 @@ requests-oauthlib==2.0.0
214
200
  # via google-auth-oauthlib
215
201
  rfc3986==2.0.0
216
202
  # via frictionless
217
- rich==13.7.1
203
+ rich==13.8.1
218
204
  # via typer
219
- rpds-py==0.19.1
205
+ rpds-py==0.20.0
220
206
  # via
221
207
  # jsonschema
222
208
  # referencing
@@ -226,13 +212,13 @@ ruamel-yaml==0.18.6
226
212
  # via hdx-python-utilities
227
213
  ruamel-yaml-clib==0.2.8
228
214
  # via ruamel-yaml
229
- setuptools==72.1.0
215
+ setuptools==75.0.0
230
216
  # via ckanapi
231
217
  shellingham==1.5.4
232
218
  # via typer
233
219
  simpleeval==0.9.13
234
220
  # via frictionless
235
- simplejson==3.19.2
221
+ simplejson==3.19.3
236
222
  # via ckanapi
237
223
  six==1.16.0
238
224
  # via
@@ -255,7 +241,7 @@ text-unidecode==1.3
255
241
  # via python-slugify
256
242
  typeguard==4.3.0
257
243
  # via inflect
258
- typer==0.12.3
244
+ typer==0.12.5
259
245
  # via frictionless
260
246
  typing-extensions==4.12.2
261
247
  # via
@@ -270,15 +256,15 @@ unidecode==1.3.8
270
256
  # via
271
257
  # libhxl
272
258
  # pyphonetics
273
- urllib3==2.2.2
259
+ urllib3==2.2.3
274
260
  # via
275
261
  # libhxl
276
262
  # requests
277
- validators==0.33.0
263
+ validators==0.34.0
278
264
  # via frictionless
279
- virtualenv==20.26.3
265
+ virtualenv==20.26.4
280
266
  # via pre-commit
281
- wheel==0.43.0
267
+ wheel==0.44.0
282
268
  # via libhxl
283
269
  xlrd==2.0.1
284
270
  # via hdx-python-utilities
@@ -12,5 +12,5 @@ __version__: str
12
12
  __version_tuple__: VERSION_TUPLE
13
13
  version_tuple: VERSION_TUPLE
14
14
 
15
- __version__ = version = '2.4.1'
16
- __version_tuple__ = version_tuple = (2, 4, 1)
15
+ __version__ = version = '2.5.0'
16
+ __version_tuple__ = version_tuple = (2, 5, 0)
@@ -5,11 +5,11 @@ from traceback import format_exc
5
5
  from typing import Any, Callable, Dict, List, Optional, Tuple, Union
6
6
 
7
7
  from .base_scraper import BaseScraper
8
- from .configurable.aggregator import Aggregator
9
- from .configurable.resource_downloader import ResourceDownloader
10
- from .configurable.scraper import ConfigurableScraper
11
- from .configurable.timeseries import TimeSeries
12
8
  from .outputs.base import BaseOutput
9
+ from .scrapers.aggregator import Aggregator
10
+ from .scrapers.configurable_scraper import ConfigurableScraper
11
+ from .scrapers.resource_downloader import ResourceDownloader
12
+ from .scrapers.timeseries import TimeSeries
13
13
  from .utilities import get_startend_dates_from_time_period
14
14
  from .utilities.fallbacks import Fallbacks
15
15
  from .utilities.reader import Read
@@ -8,10 +8,10 @@ from . import bool_assert
8
8
  from hdx.api.configuration import Configuration
9
9
  from hdx.api.locations import Locations
10
10
  from hdx.location.country import Country
11
- from hdx.scraper.base_scraper import BaseScraper
12
- from hdx.scraper.utilities import string_params_to_dict
13
- from hdx.scraper.utilities.fallbacks import Fallbacks
14
- from hdx.scraper.utilities.reader import Read
11
+ from hdx.scraper.framework.base_scraper import BaseScraper
12
+ from hdx.scraper.framework.utilities import string_params_to_dict
13
+ from hdx.scraper.framework.utilities.fallbacks import Fallbacks
14
+ from hdx.scraper.framework.utilities.reader import Read
15
15
  from hdx.utilities.dateparse import parse_date
16
16
 
17
17
 
@@ -1,7 +1,7 @@
1
1
  import logging
2
2
 
3
- from hdx.scraper.base_scraper import BaseScraper
4
- from hdx.scraper.utilities.sources import Sources
3
+ from hdx.scraper.framework.base_scraper import BaseScraper
4
+ from hdx.scraper.framework.utilities.sources import Sources
5
5
  from hdx.utilities.dateparse import default_date
6
6
  from hdx.utilities.dictandlist import dict_of_lists_add
7
7
  from hdx.utilities.text import number_format
@@ -1,7 +1,7 @@
1
1
  import logging
2
2
  from typing import Dict
3
3
 
4
- from hdx.scraper.base_scraper import BaseScraper
4
+ from hdx.scraper.framework.base_scraper import BaseScraper
5
5
  from hdx.utilities.dateparse import default_date, parse_date
6
6
 
7
7
  logger = logging.getLogger(__name__)
@@ -1,6 +1,6 @@
1
1
  import logging
2
2
 
3
- from hdx.scraper.base_scraper import BaseScraper
3
+ from hdx.scraper.framework.base_scraper import BaseScraper
4
4
  from hdx.utilities.text import get_fraction_str
5
5
 
6
6
  logger = logging.getLogger(__name__)
@@ -3,18 +3,18 @@ from datetime import datetime, timezone
3
3
 
4
4
  import pytest
5
5
 
6
+ from ..conftest import check_scraper, check_scrapers
6
7
  from .affected_targeted_reached import AffectedTargetedReached
7
- from .conftest import check_scraper, check_scrapers
8
8
  from .education_closures import EducationClosures
9
9
  from .education_enrolment import EducationEnrolment
10
10
  from hdx.location.adminlevel import AdminLevel
11
- from hdx.scraper.base_scraper import BaseScraper
12
- from hdx.scraper.runner import Runner
13
- from hdx.scraper.utilities.reader import Read
11
+ from hdx.scraper.framework.base_scraper import BaseScraper
12
+ from hdx.scraper.framework.runner import Runner
13
+ from hdx.scraper.framework.utilities.reader import Read
14
14
  from hdx.utilities.dateparse import parse_date
15
15
 
16
16
 
17
- class TestScrapersCustom:
17
+ class TestCustom:
18
18
  hapi_values_closure = {
19
19
  "hdx_id": "6a41be98-75b9-4365-9ea3-e33d0dd2668b",
20
20
  "hdx_stub": "global-school-closures-covid19",
@@ -6,10 +6,10 @@ import numpy as np
6
6
  import pandas
7
7
  import pytest
8
8
 
9
- from hdx.scraper.outputs.base import BaseOutput
10
- from hdx.scraper.outputs.excelfile import ExcelFile
11
- from hdx.scraper.outputs.googlesheets import GoogleSheets
12
- from hdx.scraper.outputs.json import JsonFile
9
+ from hdx.scraper.framework.outputs.base import BaseOutput
10
+ from hdx.scraper.framework.outputs.excelfile import ExcelFile
11
+ from hdx.scraper.framework.outputs.googlesheets import GoogleSheets
12
+ from hdx.scraper.framework.outputs.json import JsonFile
13
13
  from hdx.utilities.path import temp_dir
14
14
 
15
15
 
@@ -1,11 +1,11 @@
1
- from .conftest import run_check_scraper, run_check_scrapers
2
- from hdx.scraper.base_scraper import BaseScraper
3
- from hdx.scraper.runner import Runner
4
- from hdx.scraper.utilities.sources import Sources
1
+ from ..conftest import run_check_scraper, run_check_scrapers
2
+ from hdx.scraper.framework.base_scraper import BaseScraper
3
+ from hdx.scraper.framework.runner import Runner
4
+ from hdx.scraper.framework.utilities.sources import Sources
5
5
  from hdx.utilities.dateparse import parse_date
6
6
 
7
7
 
8
- class TestScrapersAggregation:
8
+ class TestAggregation:
9
9
  def test_get_aggregation_hxl(self, configuration):
10
10
  BaseScraper.population_lookup = {}
11
11
  today = parse_date("2020-10-01")
@@ -2,19 +2,19 @@ from copy import deepcopy
2
2
 
3
3
  import pytest
4
4
 
5
- from .conftest import run_check_scrapers
5
+ from ..conftest import run_check_scrapers
6
6
  from hdx.location.country import Country
7
- from hdx.scraper.base_scraper import BaseScraper
8
- from hdx.scraper.outputs.json import JsonFile
9
- from hdx.scraper.runner import Runner
10
- from hdx.scraper.utilities.sources import Sources
11
- from hdx.scraper.utilities.writer import Writer
7
+ from hdx.scraper.framework.base_scraper import BaseScraper
8
+ from hdx.scraper.framework.outputs.json import JsonFile
9
+ from hdx.scraper.framework.runner import Runner
10
+ from hdx.scraper.framework.utilities.sources import Sources
11
+ from hdx.scraper.framework.utilities.writer import Writer
12
12
  from hdx.utilities.dateparse import parse_date
13
13
 
14
14
 
15
15
  # Test that scrapers can add to output from previous scrapers
16
16
  # Also test producing sources per admin unit eg. #targeted+total+eth
17
- class TestScrapersAppendData:
17
+ class TestAppendData:
18
18
  @pytest.fixture
19
19
  def iso3s(self):
20
20
  return (
@@ -2,10 +2,10 @@ import logging
2
2
 
3
3
  import pytest
4
4
 
5
- from .conftest import run_check_scraper
6
- from hdx.scraper.base_scraper import BaseScraper
7
- from hdx.scraper.runner import Runner
8
- from hdx.scraper.utilities.sources import Sources
5
+ from ..conftest import run_check_scraper
6
+ from hdx.scraper.framework.base_scraper import BaseScraper
7
+ from hdx.scraper.framework.runner import Runner
8
+ from hdx.scraper.framework.utilities.sources import Sources
9
9
  from hdx.utilities.dateparse import parse_date
10
10
 
11
11
 
@@ -1,10 +1,10 @@
1
- from .conftest import run_check_scraper
2
- from hdx.scraper.base_scraper import BaseScraper
3
- from hdx.scraper.runner import Runner
1
+ from ..conftest import run_check_scraper
2
+ from hdx.scraper.framework.base_scraper import BaseScraper
3
+ from hdx.scraper.framework.runner import Runner
4
4
  from hdx.utilities.dateparse import parse_date
5
5
 
6
6
 
7
- class TestScrapersMultipleURLs:
7
+ class TestMultipleURLs:
8
8
  def test_get_key_figures(self, configuration):
9
9
  BaseScraper.population_lookup = {}
10
10
  today = parse_date("2020-10-01")
@@ -1,15 +1,15 @@
1
- from .conftest import run_check_scraper, run_check_scrapers
1
+ from ..conftest import run_check_scraper, run_check_scrapers
2
2
  from .unhcr_myanmar_idps import idps_post_run
3
- from hdx.scraper.base_scraper import BaseScraper
4
- from hdx.scraper.outputs.json import JsonFile
5
- from hdx.scraper.runner import Runner
6
- from hdx.scraper.utilities.reader import Read
7
- from hdx.scraper.utilities.writer import Writer
3
+ from hdx.scraper.framework.base_scraper import BaseScraper
4
+ from hdx.scraper.framework.outputs.json import JsonFile
5
+ from hdx.scraper.framework.runner import Runner
6
+ from hdx.scraper.framework.utilities.reader import Read
7
+ from hdx.scraper.framework.utilities.writer import Writer
8
8
  from hdx.utilities.dateparse import parse_date
9
9
  from hdx.utilities.errors_onexit import ErrorsOnExit
10
10
 
11
11
 
12
- class TestScrapersNational:
12
+ class TestNational:
13
13
  def test_get_national_afg(self, configuration):
14
14
  BaseScraper.population_lookup = {}
15
15
  today = parse_date("2020-10-01")
@@ -1,13 +1,13 @@
1
- from .conftest import run_check_scraper, run_check_scrapers
2
- from hdx.scraper.base_scraper import BaseScraper
3
- from hdx.scraper.outputs.json import JsonFile
4
- from hdx.scraper.runner import Runner
5
- from hdx.scraper.utilities.sources import Sources
6
- from hdx.scraper.utilities.writer import Writer
1
+ from ..conftest import run_check_scraper, run_check_scrapers
2
+ from hdx.scraper.framework.base_scraper import BaseScraper
3
+ from hdx.scraper.framework.outputs.json import JsonFile
4
+ from hdx.scraper.framework.runner import Runner
5
+ from hdx.scraper.framework.utilities.sources import Sources
6
+ from hdx.scraper.framework.utilities.writer import Writer
7
7
  from hdx.utilities.dateparse import parse_date
8
8
 
9
9
 
10
- class TestScrapersRegionalToplevel:
10
+ class TestRegionalToplevel:
11
11
  access_national_headers = (
12
12
  [
13
13
  "% of visas pending or denied",
@@ -2,13 +2,13 @@ from os.path import exists, join
2
2
 
3
3
  import pytest
4
4
 
5
- from hdx.scraper.base_scraper import BaseScraper
6
- from hdx.scraper.runner import Runner
5
+ from hdx.scraper.framework.base_scraper import BaseScraper
6
+ from hdx.scraper.framework.runner import Runner
7
7
  from hdx.utilities.dateparse import parse_date
8
8
  from hdx.utilities.path import temp_dir
9
9
 
10
10
 
11
- class TestScrapersResourceDownloader:
11
+ class TestResourceDownloader:
12
12
  @pytest.fixture(scope="function")
13
13
  def output_file(self, fixtures):
14
14
  return join(fixtures, "test_output.xlsx")
@@ -1,13 +1,13 @@
1
- from .conftest import run_check_scraper
1
+ from ..conftest import run_check_scraper
2
2
  from hdx.location.adminlevel import AdminLevel
3
- from hdx.scraper.base_scraper import BaseScraper
4
- from hdx.scraper.outputs.json import JsonFile
5
- from hdx.scraper.runner import Runner
6
- from hdx.scraper.utilities.writer import Writer
3
+ from hdx.scraper.framework.base_scraper import BaseScraper
4
+ from hdx.scraper.framework.outputs.json import JsonFile
5
+ from hdx.scraper.framework.runner import Runner
6
+ from hdx.scraper.framework.utilities.writer import Writer
7
7
  from hdx.utilities.dateparse import parse_date
8
8
 
9
9
 
10
- class TestScrapersSubnational:
10
+ class TestSubnational:
11
11
  def test_get_subnational(self, configuration):
12
12
  BaseScraper.population_lookup = {}
13
13
  today = parse_date("2020-10-01")
@@ -1,10 +1,10 @@
1
- from hdx.scraper.base_scraper import BaseScraper
2
- from hdx.scraper.outputs.json import JsonFile
3
- from hdx.scraper.runner import Runner
1
+ from hdx.scraper.framework.base_scraper import BaseScraper
2
+ from hdx.scraper.framework.outputs.json import JsonFile
3
+ from hdx.scraper.framework.runner import Runner
4
4
  from hdx.utilities.dateparse import parse_date
5
5
 
6
6
 
7
- class TestScrapersTimeSeries:
7
+ class TestTimeSeries:
8
8
  def test_timeseries(self, configuration):
9
9
  BaseScraper.population_lookup = {}
10
10
  iso3s = ("AFG", "MMR")
@@ -2,8 +2,8 @@ from copy import copy
2
2
  from datetime import datetime, timezone
3
3
 
4
4
  from .conftest import run_check_scrapers
5
- from hdx.scraper.base_scraper import BaseScraper
6
- from hdx.scraper.runner import Runner
5
+ from hdx.scraper.framework.base_scraper import BaseScraper
6
+ from hdx.scraper.framework.runner import Runner
7
7
  from hdx.utilities.dateparse import parse_date
8
8
 
9
9
 
@@ -4,7 +4,7 @@ import pytest
4
4
 
5
5
  from hdx.data.dataset import Dataset
6
6
  from hdx.data.resource import Resource
7
- from hdx.scraper.utilities.reader import Read
7
+ from hdx.scraper.framework.utilities.reader import Read
8
8
  from hdx.utilities.dateparse import parse_date
9
9
  from hdx.utilities.downloader import Download
10
10
  from hdx.utilities.path import temp_dir
@@ -1,4 +1,4 @@
1
- from hdx.scraper.utilities.region_lookup import RegionLookup
1
+ from hdx.scraper.framework.utilities.region_lookup import RegionLookup
2
2
 
3
3
 
4
4
  class TestRegionLookup:
@@ -1,9 +1,11 @@
1
1
  import pytest
2
2
 
3
3
  from hdx.location.adminlevel import AdminLevel
4
- from hdx.scraper.base_scraper import BaseScraper
5
- from hdx.scraper.configurable.scraper import ConfigurableScraper
6
- from hdx.scraper.utilities.sources import Sources
4
+ from hdx.scraper.framework.base_scraper import BaseScraper
5
+ from hdx.scraper.framework.scrapers.configurable_scraper import (
6
+ ConfigurableScraper,
7
+ )
8
+ from hdx.scraper.framework.utilities.sources import Sources
7
9
  from hdx.utilities.dateparse import parse_date
8
10
 
9
11
 
@@ -1,4 +1,4 @@
1
- from hdx.scraper.utilities import get_rowval, string_params_to_dict
1
+ from hdx.scraper.framework.utilities import get_rowval, string_params_to_dict
2
2
 
3
3
 
4
4
  class TestUtils: