Skip to content

Commit

Permalink
Merge pull request #8822 from internetarchive/fix-solr-reindex
Browse files Browse the repository at this point in the history
Make osp-dump optional argument
  • Loading branch information
mekarpeles authored Feb 24, 2024
2 parents 07b33c5 + 4012c1f commit a30c9ac
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion openlibrary/solr/update.py
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ def load_configs(

async def main(
keys: list[str],
osp_dump: Path,
osp_dump: Path | None = None,
ol_url="http://openlibrary.org",
ol_config="openlibrary.yml",
output_file: str | None = None,
Expand Down
2 changes: 1 addition & 1 deletion openlibrary/utils/open_syllabus_project.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ def get_osp_dump_location() -> Path | None:
return osp_dump_location


def set_osp_dump_location(val: Path):
def set_osp_dump_location(val: Path | None):
global osp_dump_location
osp_dump_location = val

Expand Down
2 changes: 1 addition & 1 deletion scripts/solr_builder/solr_builder/solr_builder.py
Original file line number Diff line number Diff line change
Expand Up @@ -378,7 +378,7 @@ def build_job_query(
async def main(
cmd: Literal['index', 'fetch-end'],
job: Literal['works', 'orphans', 'authors', 'lists'],
osp_dump: Path,
osp_dump: Path | None = None,
postgres="postgres.ini",
ol="http://ol/",
ol_config="../../conf/openlibrary.yml",
Expand Down
2 changes: 1 addition & 1 deletion scripts/solr_updater.py
Original file line number Diff line number Diff line change
Expand Up @@ -244,7 +244,7 @@ async def update_keys(keys):

async def main(
ol_config: str,
osp_dump: Path,
osp_dump: Path | None = None,
debugger: bool = False,
state_file: str = 'solr-update.state',
exclude_edits_containing: str | None = None,
Expand Down

0 comments on commit a30c9ac

Please sign in to comment.