|
24 | 24 |
|
25 | 25 | from minecode_pipelines.pipes import fetch_checkpoint_from_github |
26 | 26 | from minecode_pipelines.pipes import update_checkpoints_in_github |
| 27 | +from minecode_pipelines.pipes import update_checkpoint_state |
27 | 28 | from minecode_pipelines.pipes import get_mined_packages_from_checkpoint |
28 | 29 | from minecode_pipelines.pipes import update_mined_packages_in_checkpoint |
29 | 30 | from minecode_pipelines.pipes import get_packages_file_from_checkpoint |
30 | | -from minecode_pipelines.pipes import update_checkpoint_state |
31 | 31 | from minecode_pipelines.pipes import write_packages_json |
32 | 32 | from minecode_pipelines.pipes import MINECODE_PIPELINES_CONFIG_REPO |
33 | 33 | from minecode_pipelines.pipes import INITIAL_SYNC_STATE |
|
58 | 58 | PYPI_PACKAGES_CHECKPOINT_PATH = "pypi/packages_checkpoint.json" |
59 | 59 |
|
60 | 60 |
|
61 | | -# We are testing and storing mined packageURLs in one single repo per ecosystem for now |
62 | | -MINECODE_DATA_PYPI_REPO = "https://github.com/aboutcode-data/minecode-data-pypi-test" |
63 | | - |
64 | | - |
65 | 61 | def mine_pypi_packages(logger=None): |
66 | 62 | """ |
67 | 63 | Mine pypi package names from pypi simple and save to checkpoints, |
@@ -256,8 +252,8 @@ def save_mined_packages_in_checkpoint(packages_mined, config_repo, logger=None): |
256 | 252 | ) |
257 | 253 |
|
258 | 254 |
|
259 | | -def update_state_and_checkpoints(state, config_repo, last_serial, logger=None): |
260 | | - # If we are finished mining all the packages in the initial sync, we can now |
| 255 | +def update_state_and_checkpoints(config_repo, state, last_serial, logger=None): |
| 256 | + # If we are finshed mining all the packages in the intial sync, we can now |
261 | 257 | # periodically sync the packages from latest |
262 | 258 | if state == INITIAL_SYNC_STATE: |
263 | 259 | if logger: |
|
0 commit comments