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

co19/LibTest/io/Link/rename_A02_t03 flaky -> RuntimeError #53274

Closed
alexmarkov opened this issue Aug 18, 2023 · 2 comments
Closed

co19/LibTest/io/Link/rename_A02_t03 flaky -> RuntimeError #53274

alexmarkov opened this issue Aug 18, 2023 · 2 comments
Assignees
Labels
area-vm Use area-vm for VM related issues, including code coverage, and the AOT and JIT backends. gardening library-io

Comments

@alexmarkov
Copy link
Contributor

The test

co19/LibTest/io/Link/rename_A02_t03 RuntimeError (expected Pass)

is failing on configuration

vm-aot-win-debug-x64c

This test was flaky, and now it is failing consistently.

Log:

--- Command "vm_compile_to_kernel" (took 02.000749s):
set DART_CONFIGURATION=DebugX64C & set DART_SUPPRESS_WER=1 & set DART_CRASHPAD_HANDLER=C:\b\s\w\ir\out\DebugX64C\crashpad_handler.exe & C:\b\s\w\ir\pkg\vm\tool\gen_kernel.bat --aot --platform=out/DebugX64C/vm_platform_strong.dill -o C:\b\s\w\ir\out\DebugX64C\generated_compilations\vm-aot-win-debug-x64c\tests_co19_src_LibTest_io_Link_rename_A02_t03\out.dill C:\b\s\w\ir\tests\co19\src\LibTest\io\Link\rename_A02_t03.dart -Dtest_runner.configuration=vm-aot-win-debug-x64c --packages=C:\b\s\w\ir\.dart_tool\package_config.json -Ddart.vm.product=false --sound-null-safety

exit code:
0

--- Command "precompiler" (took 19.000764s):
set DART_CONFIGURATION=DebugX64C & set DART_SUPPRESS_WER=1 & set DART_CRASHPAD_HANDLER=C:\b\s\w\ir\out\DebugX64C\crashpad_handler.exe & out\DebugX64C\gen_snapshot --snapshot-kind=app-aot-elf --elf=C:/b/s/w/ir/out/DebugX64C/generated_compilations/vm-aot-win-debug-x64c/tests_co19_src_LibTest_io_Link_rename_A02_t03/out.aotsnapshot --loading-unit-manifest=C:/b/s/w/ir/out/DebugX64C/generated_compilations/vm-aot-win-debug-x64c/tests_co19_src_LibTest_io_Link_rename_A02_t03/ignored.json --sound-null-safety -Dtest_runner.configuration=vm-aot-win-debug-x64c --ignore-unrecognized-flags --packages=C:\b\s\w\ir\.dart_tool\package_config.json C:\b\s\w\ir\out\DebugX64C\generated_compilations\vm-aot-win-debug-x64c\tests_co19_src_LibTest_io_Link_rename_A02_t03\out.dill

exit code:
0

--- Command "remove_kernel_file" (took 93ms):
set DART_CONFIGURATION=DebugX64C & set DART_SUPPRESS_WER=1 & set DART_CRASHPAD_HANDLER=C:\b\s\w\ir\out\DebugX64C\crashpad_handler.exe & cmd.exe /c del C:\b\s\w\ir\out\DebugX64C\generated_compilations\vm-aot-win-debug-x64c\tests_co19_src_LibTest_io_Link_rename_A02_t03\out.dill

exit code:
0

--- Command "vm" (took 534ms):
set DART_CONFIGURATION=DebugX64C & set DART_SUPPRESS_WER=1 & set DART_CRASHPAD_HANDLER=C:\b\s\w\ir\out\DebugX64C\crashpad_handler.exe & set TEST_COMPILATION_DIR=C:/b/s/w/ir/out/DebugX64C/generated_compilations/vm-aot-win-debug-x64c/tests_co19_src_LibTest_io_Link_rename_A02_t03 & out\DebugX64C\dart_precompiled_runtime.exe --sound-null-safety -Dtest_runner.configuration=vm-aot-win-debug-x64c --ignore-unrecognized-flags --packages=C:\b\s\w\ir\.dart_tool\package_config.json C:/b/s/w/ir/out/DebugX64C/generated_compilations/vm-aot-win-debug-x64c/tests_co19_src_LibTest_io_Link_rename_A02_t03/out.aotsnapshot

exit code:
255

stdout:
unittest-suite-wait-for-done

stderr:
Unhandled exception:
Expect.fail(FileSystemException expected)
#0      _fail (file:///C:/b/s/w/ir/tests/co19/src/Utils/expect.dart:18)
#1      Expect.fail (file:///C:/b/s/w/ir/tests/co19/src/Utils/expect_common.dart:59)
#2      _main.<anonymous closure> (file:///C:/b/s/w/ir/tests/co19/src/LibTest/io/Link/rename_A02_t03.dart:39)
<asynchronous suspension>
#3      _main (file:///C:/b/s/w/ir/tests/co19/src/LibTest/io/Link/rename_A02_t03.dart:38)
<asynchronous suspension>
#4      inSandbox (file:///C:/b/s/w/ir/tests/co19/src/LibTest/io/file_utils.dart:22)
<asynchronous suspension>
#5      main (file:///C:/b/s/w/ir/tests/co19/src/LibTest/io/Link/rename_A02_t03.dart:30)
<asynchronous suspension>

--- Re-run this test:
python3 tools/test.py -n vm-aot-win-debug-x64c co19/LibTest/io/Link/rename_A02_t03

/cc @brianquinlan

@alexmarkov alexmarkov added area-vm Use area-vm for VM related issues, including code coverage, and the AOT and JIT backends. library-io gardening labels Aug 18, 2023
@brianquinlan brianquinlan self-assigned this Sep 18, 2023
@brianquinlan
Copy link
Contributor

brianquinlan commented Sep 18, 2023

I think that the documentation:

If newPath identifies an existing link, that link is removed first. If newPath identifies an existing file or directory, the operation fails and the future completes with an exception.

Does not match the actual behavior. We even have explicit tests that verify that existing files are overwritten.

The code seems to do that deliberately.

copybara-service bot pushed a commit that referenced this issue Sep 19, 2023
CoreLibraryReviewExempt: Documentation-only change
Bug: #53274
Change-Id: Ifa3e94c6d8503790d3f6d29e9a99700e83d511d2
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/326862
Reviewed-by: Alexander Aprelev <aam@google.com>
Commit-Queue: Brian Quinlan <bquinlan@google.com>
@brianquinlan
Copy link
Contributor

I've filed a bug (dart-lang/co19#2284) to modify the co19 tests based on the corrected documentation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-vm Use area-vm for VM related issues, including code coverage, and the AOT and JIT backends. gardening library-io
Projects
None yet
Development

No branches or pull requests

3 participants
@brianquinlan @alexmarkov and others