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

Env variables interpolation doesn't work inside 'with_items_from_csv' #94

Closed
RicoGit opened this issue Dec 11, 2020 · 1 comment
Closed

Comments

@RicoGit
Copy link

RicoGit commented Dec 11, 2020

Looks like an interpolation in with_items_from_csv is not worked.

config contains:
with_items_from_csv': /fixtures/{{ RECIPE_IDS_FILE }}
error appeared:
thread 'main' panicked at 'couldn't open /fixtures/{{ RECIPE_IDS_FILE }}: No such file or directory (os error 2)'

Expected:
Unknown 'RECIPE_IDS_FILE' variable! if RECIPE_IDS_FILE is not defined.
Or reading csv file successfully is RECIPE_IDS_FILE is defined.

@fcsonline
Copy link
Owner

@RicoGit Sorry, but this is not supported right now. You can't have interpolations on these properties. drill reads the benchmark plan file and computes (expands) all the actions / requests to do before running it.

Your interpolation looks like an environment variable. This interpolation could be replaced to be able to open the right file, but the interpolation engine is only available on runtime and would require a huge refactor.

I created a pull request to expose this limitation and handle it better.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants