Skip to content

Commit

Permalink
adding lookback size
Browse files Browse the repository at this point in the history
Signed-off-by: Shashank Reddy Boyapally <[email protected]>
  • Loading branch information
shashank-boyapally committed Aug 19, 2024
1 parent 070bd4d commit cced3f7
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions orion.py
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,7 @@ def cli(max_content_width=120): # pylint: disable=unused-argument
@click.option("--convert-tinyurl", is_flag=True, help="Convert buildUrls to tiny url format for better formatting")
@click.option("--collapse", is_flag=True, help="Only outputs changepoints, previous and later runs in the xml format")
@click.option("--node-count", default=False, help="Match any node iterations count")
@click.option("--lookback-size", type=int, default=10000, help="Maximum number of entries to be looked back")
def cmd_analysis(**kwargs):
"""
Orion runs on command line mode, and helps in detecting regressions
Expand Down
2 changes: 1 addition & 1 deletion pkg/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,7 @@ def process_test(
# getting metadata
metadata = extract_metadata_from_test(test) if options["uuid"] in ("", None) else get_metadata_with_uuid(options["uuid"], match)
# get uuids, buildUrls matching with the metadata
runs = match.get_uuid_by_metadata(metadata, fingerprint_index, lookback_date=start_timestamp)
runs = match.get_uuid_by_metadata(metadata, fingerprint_index, lookback_date=start_timestamp, lookback_size=options['lookback_size'])
uuids = [run["uuid"] for run in runs]
buildUrls = {run["uuid"]: run["buildUrl"] for run in runs}
# get uuids if there is a baseline
Expand Down

0 comments on commit cced3f7

Please sign in to comment.