-
Notifications
You must be signed in to change notification settings - Fork 382
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
OT endpoints use new ot_use_counter_bucket_number
field
#4624
base: main
Are you sure you want to change the base?
Conversation
Accidentally close and open the PR! How often are the OT endpoints used? Should we fetch these files every time vs store them through a separate cron job daily? |
These are only fetched when an origin trial creation form is submitted, which is usually less than once a day, so I think it's fine to keep fetching them as needed. Additionally, the files will block submission if the contents are not up-to-date, so it's useful to get the most recent version if a feature owner just landed the requirements for submitting the origin trial |
api/origin_trials_api.py
Outdated
def get_chromium_files_for_validation() -> dict: | ||
"""Get all chromium file contents stored in a dictionary""" | ||
chromium_files = {} # Chromium source file contents. | ||
with concurrent.futures.ThreadPoolExecutor(max_workers=5) as executor: |
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.
Do we need 5 workers? CHROMIUM_SRC_FILES only has 4 files so far
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.
It seems fine to drop it to 4 to match 🙂
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.
LGTM with a comment to consider
This field is needed for the purpose of WebFeature and WebDXFeature use counter monitoring for origin trials. Its value will be inferred based on the number value that use counters are listed as in web_feature.mojom and webdx_feature.mojom.