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

Remove quotes $artifacts_to_transpile in the for loop list of compile_then_transpile.sh #8845

Closed

Conversation

twt--
Copy link
Contributor

@twt-- twt-- commented Sep 27, 2024

This change remove quotes on $artifacts_to_transpile variable of the for loop list in compile_then-transpile.sh so it can be treated as a list instead of a single value.

When quotes are used here, transpilation of >1 artifact fails with an error like this:

thread 'main' panicked at src/main.rs:31:29:
Unable to read file: target/foo-Foo.json
target/bar-Bar.json
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

This is because the transpiler tries to read a file named target/foo-Foo.json\ntarget/bar-Bar.json instead of handling target/foo-Foo.json and target/bar-Bar.json separately.

twt-- and others added 2 commits September 26, 2024 19:13
With quotes on the `$artifacts_to_transpile` variable in the for loop,
the loop list is treated as a single string, so it only runs once and
fails with an error message like:
```
thread 'main' panicked at src/main.rs:31:29:
Unable to read file: target/foo-Foo.json
target/bar-Bar.json
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
```
because it tries to read a file named `target/foo-Foo.json\ntarget/bar-Bar.json`
instead of handling `target/foo-Foo.json` and `target/bar-Bar.json` separately.
@ludamad ludamad added the redo-typo-pr Automated. label Oct 2, 2024
@AztecBot AztecBot closed this Oct 2, 2024
ludamad added a commit that referenced this pull request Oct 3, 2024
… for loop list of compile_then_transpile.sh (#8932)

Thanks twt-- for
#8845. Our policy is
to redo typo changes to dissuade metric farming. This is an automated
script.

Co-authored-by: Tim Tickel <[email protected]>
Co-authored-by: ludamad <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
redo-typo-pr Automated.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants