diff --git a/requirements.in b/requirements.in index cad7ecd7e..8d86b1856 100644 --- a/requirements.in +++ b/requirements.in @@ -1,4 +1,4 @@ -https://github.com/codecov/shared/archive/5c6de0f898bfa32ef64a23b3519e44fa99028845.tar.gz#egg=shared +https://github.com/codecov/shared/archive/a0d0333196f1c9577243ff15c85515754849127c.tar.gz#egg=shared https://github.com/codecov/opentelem-python/archive/refs/tags/v0.0.4a1.tar.gz#egg=codecovopentelem https://github.com/codecov/test-results-parser/archive/5515e960d5d38881036e9127f86320efca649f13.tar.gz#egg=test-results-parser boto3 diff --git a/requirements.txt b/requirements.txt index 6fbcc27ef..5bee67b63 100644 --- a/requirements.txt +++ b/requirements.txt @@ -355,7 +355,7 @@ screen==1.0.1 # via excel-base sentry-sdk==1.40.0 # via -r requirements.in -shared @ https://github.com/codecov/shared/archive/5c6de0f898bfa32ef64a23b3519e44fa99028845.tar.gz +shared @ https://github.com/codecov/shared/archive/a0d0333196f1c9577243ff15c85515754849127c.tar.gz # via -r requirements.in six==1.15.0 # via diff --git a/rollouts/__init__.py b/rollouts/__init__.py index 943652123..2d41d3a5b 100644 --- a/rollouts/__init__.py +++ b/rollouts/__init__.py @@ -2,15 +2,11 @@ from database.models import Owner, Repository -# Declare the feature variants via Django Admin -LIST_REPOS_GENERATOR_BY_OWNER_ID = Feature( - "list_repos_generator", - 0.0, -) +# Declare the feature variants and parameters via Django Admin +LIST_REPOS_GENERATOR_BY_OWNER_ID = Feature("list_repos_generator") # Eventually we want all repos to use this # This flag will just help us with the rollout process USE_LABEL_INDEX_IN_REPORT_PROCESSING_BY_REPO_ID = Feature( - "use_label_index_in_report_processing", - 0.0, + "use_label_index_in_report_processing" ) diff --git a/services/report/raw_upload_processor.py b/services/report/raw_upload_processor.py index 4565d7a96..b93ca2797 100644 --- a/services/report/raw_upload_processor.py +++ b/services/report/raw_upload_processor.py @@ -106,7 +106,7 @@ def process_raw_upload( should_use_encoded_labels = ( upload and USE_LABEL_INDEX_IN_REPORT_PROCESSING_BY_REPO_ID.check_value( - upload.report.commit.repository.repoid, default=False + repo_id=upload.report.commit.repository.repoid, default=False ) ) # [javascript] check for both coverage.json and coverage/coverage.lcov @@ -343,7 +343,7 @@ def _adjust_sessions( if ( upload and USE_LABEL_INDEX_IN_REPORT_PROCESSING_BY_REPO_ID.check_value( - upload.report.commit.repository.repoid, default=False + repo_id=upload.report.commit.repository.repoid, default=False ) and to_partially_overwrite_flags ): diff --git a/tasks/sync_repos.py b/tasks/sync_repos.py index 589936e81..8157fe7f7 100644 --- a/tasks/sync_repos.py +++ b/tasks/sync_repos.py @@ -242,7 +242,9 @@ def process_repos(repos): db_session, git, owner, repository_service_ids ) repoids = repoids_added - elif LIST_REPOS_GENERATOR_BY_OWNER_ID.check_value(ownerid, default=False): + elif LIST_REPOS_GENERATOR_BY_OWNER_ID.check_value( + owner_id=ownerid, default=False + ): with metrics.timer( f"{metrics_scope}.sync_repos_using_integration.list_repos_generator" ): @@ -340,7 +342,9 @@ def process_repos(repos): db_session.commit() try: - if LIST_REPOS_GENERATOR_BY_OWNER_ID.check_value(ownerid, default=False): + if LIST_REPOS_GENERATOR_BY_OWNER_ID.check_value( + owner_id=ownerid, default=False + ): with metrics.timer(f"{metrics_scope}.sync_repos.list_repos_generator"): async for page in git.list_repos_generator(): process_repos(page)