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

eval statement in env_batch can produce unexpected results #1613

Closed
jedwards4b opened this issue May 26, 2017 · 0 comments
Closed

eval statement in env_batch can produce unexpected results #1613

jedwards4b opened this issue May 26, 2017 · 0 comments
Assignees
Labels

Comments

@jedwards4b
Copy link
Contributor

When setting the JOB_QUEUE=long we notice that the eval statement in env_batch.py unexpectedly
evaluates the string long to be <type 'long'>
The solution is to only use the eval statement if the setting includes whitespace.

@jedwards4b jedwards4b self-assigned this May 26, 2017
jgfouca added a commit that referenced this issue May 26, 2017
do not eval words - only strings with whitespace

eval on a word sometimes gives unexpected results, for example eval('long') results in
<type 'long'> avoid this by only using eval if the string contains whitespace.

Test suite: on hobart: create_test cime_developer --queue long, scripts_regression_tests.py --fast
Test baseline:
Test namelist changes:
Test status: bit for bit

Fixes #1613

User interface changes?:

Code review:
@ghost ghost removed the in progress label May 26, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant