Skip to content
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

ability to set target-path to a dynamic value #1320

Closed
Vamanan opened this issue Feb 26, 2019 · 1 comment · Fixed by #1441
Closed

ability to set target-path to a dynamic value #1320

Vamanan opened this issue Feb 26, 2019 · 1 comment · Fixed by #1441
Labels
enhancement New feature or request

Comments

@Vamanan
Copy link

Vamanan commented Feb 26, 2019

Feature

Feature description

It would be nice to set target-path to a dynamic value. For eg: target_<current_time>

Currently target-path can be assigned to the value of a variable that is passed as a command line argument. However, since command line args are parsed as simple strings, the value of such a variable cannot be dynamic.

Who will this benefit?

The target directory contains run stats in its run_results.json file. If one were to automate the process of parsing this file after every run for alarming/monitoring, then it is important to not have one run's stats overwrite another before it is parsed. This can be prevented by "versioning" each run by the target directory name which would be a function of current timestamp.

@drewbanin drewbanin added this to the Wilt Chamberlain milestone Feb 28, 2019
@drewbanin drewbanin added the enhancement New feature or request label Feb 28, 2019
@drewbanin
Copy link
Contributor

thanks for the report @Vamanan! Let's solve this by adding the modules dict to the minimal compilation context. That would let you do something like:

target-path: "target_{{ modules.datetime.datetime.now().strftime(...) }}"

We could conceivably also add static context variables like run_started_at and invocation_id, which are reasonable and i think doable here.

Prioritized for the Wilt Chamberlain release, pending any unforeseen issues with this approach.

beckjake added a commit that referenced this issue May 7, 2019
…et-paths

Add modules and tracking info to the configuration parsing context (#1320)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants