VZ4 tester error message

At VZ4, I get the following error:

Initiating test run...

⚡ This is a turbo test run. https://codecrafters.io/turbo

Running tests. Logs should appear shortly...

[compile]    Compiling codecrafters-shell v0.1.0 (/app)
[compile]     Finished `release` profile [optimized] target(s) in 1.53s
[compile] Moved ./.codecrafters/run.sh → ./your_program.sh
[compile] Compilation successful.

Debug = true

[tester::#VZ4] Running tests for Stage #VZ4 (Redirection - Redirect stderr)
[tester::#VZ4] [setup] export PATH=/tmp/grape/apple/blueberry:$PATH
[tester::#VZ4] Running ./your_program.sh
[tester::#VZ4] [setup] echo -n "blueberry" > "/tmp/quz/blueberry"
[your-program] $ ls -1 nonexistent 2> /tmp/foo/bar.md
[your-program] $ cat /tmp/foo/bar.md
[your-program] ls: nonexistent: No such file or directory
[tester::#VZ4] ✓ Received redirected error message
[tester::#VZ4] Expected file "/tmp/foo/baz.md" to exist. Error: open /tmp/foo/baz.md: no such file or directory
[your-program] $ echo 'Maria file cannot be found' 2> /tmp/foo/baz.md
[your-program] Maria file cannot be found
[your-program] $ 
[tester::#VZ4] Assertion failed.
[tester::#VZ4] Test failed

The error [tester::#VZ4] Expected file "/tmp/foo/baz.md" to exist. Error: open /tmp/foo/baz.md: no such file or directory seems to be generated out of order (before executing the next command $ echo 'Maria file cannot be found' 2> /tmp/foo/baz.md)

Hey @ShahriarJavidi, thanks for highlighting the issue! We’re addressing it in this PR.

Let me know if you notice anything else or need help with anything!

Just a quick note: while the error message appears before the command, the command is actually executed first. It’s just a display order issue.

This should be fixed now. Feel free to test it and let me know if anything’s still off.

@andy1li thank you for considering it! The issue has been addressed :folded_hands:

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.