-
-
Notifications
You must be signed in to change notification settings - Fork 8
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
translate WDL's sub() as replaceAll() equivalent not replace() #128
Comments
Good catch! We should add a test case with data that would demonstrate this |
This workflow is using it to replace spaces by underscores (for filename): https://github.com/broadinstitute/viral-pipelines/blob/f009d869ddb75770ae0aa69d9dd8bcaf1390502e/pipes/WDL/tasks/tasks_reports.wdl#L367 That workflow has a lot more than what we need, so we can just extract the test case for a string with spaces, then replace space by |
|
😮 thought it was available in that spec. Sounds like the global flag is the way to go then 👍 |
From WDL spec:
But I think what we have in the
get_expr_apply
is a call to.replace()
which only replaces one occurrence (different than the Python function with same name!)Instead I think we must use JS'
replaceAll()
.The text was updated successfully, but these errors were encountered: