Skip to content

[test] Fix test regressions in backdeployment bots #34925

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

Merged
merged 1 commit into from
Dec 10, 2020

Conversation

lorentey
Copy link
Member

@lorentey lorentey commented Dec 2, 2020

#34665 changed trap messages in debug builds, but the new format obviously doesn't apply in back deployment scenarios.

Resolves rdar://71902574.

@lorentey
Copy link
Member Author

lorentey commented Dec 2, 2020

@swift-ci test

@swift-ci
Copy link
Contributor

swift-ci commented Dec 2, 2020

Build failed
Swift Test Linux Platform
Git Sha - 20f807ba37a8b6968bb783ba7fa5adde96729f8a

@swift-ci
Copy link
Contributor

swift-ci commented Dec 2, 2020

Build failed
Swift Test OS X Platform
Git Sha - 20f807ba37a8b6968bb783ba7fa5adde96729f8a

@lorentey
Copy link
Member Author

lorentey commented Dec 5, 2020

[ RUN      ] OptionalTraps.UnwrapNone/location
stderr>>> Assert_Debug/OptionalTraps.swift:57: Fatal error: Unexpectedly found nil while unwrapping an Optional value
stderr>>> Current stack trace:
stderr>>> 0    libswiftCore.dylib                 0x0000000109c55980 _swift_stdlib_reportFatalErrorInFile + 109
stderr>>> 1    libswiftCore.dylib                 0x000000010988f990 closure #1 in closure #1 in closure #1 in _assertionFailure(_:_:file:line:flags:) + 478
stderr>>> 2    libswiftCore.dylib                 0x000000010988fe50 closure #1 in closure #1 in _assertionFailure(_:_:file:line:flags:) + 110
stderr>>> 3    libswiftCore.dylib                 0x000000010988f720 closure #1 in _assertionFailure(_:_:file:line:flags:) + 128
stderr>>> 4    libswiftCore.dylib                 0x000000010988f210 _assertionFailure(_:_:file:line:flags:) + 414
stderr>>> 5    Assert_Debug                       0x0000000109829d60 closure #4 in  + 258
stderr>>> 6    libswiftStdlibUnittest.dylib       0x000000010a481700 TestSuite._runTest(name:parameter:) + 943
stderr>>> 7    libswiftStdlibUnittest.dylib       0x000000010a480240 _childProcess() + 1121
stderr>>> 8    Assert_Debug                       0x0000000109828f20 main + 3135
stderr>>> 9    libdyld.dylib                      0x00007fff7099ecc8 start + 1
stderr>>> OK: saw expected "crashed: sigill"
did not find expected string after crash: "OptionalTraps.swift:45:"
[     FAIL ] OptionalTraps.UnwrapNone/location

@lorentey
Copy link
Member Author

lorentey commented Dec 5, 2020

[ RUN      ] Error.try!/location
stderr>>> main/Error.swift:140: Fatal error: 'try!' expression unexpectedly raised an error: main.SillyError.JazzHands
stderr>>> Current stack trace:
stderr>>> 0    libswiftCore.dylib                 0x0000000105a13980 _swift_stdlib_reportFatalErrorInFile + 109
stderr>>> 1    libswiftCore.dylib                 0x000000010564e0b0 closure #1 in closure #1 in closure #1 in _assertionFailure(_:_:file:line:flags:) + 243
stderr>>> 2    libswiftCore.dylib                 0x000000010564de50 closure #1 in closure #1 in _assertionFailure(_:_:file:line:flags:) + 110
stderr>>> 3    libswiftCore.dylib                 0x000000010564e2d0 specialized String.withUTF8<A>(_:) + 169
stderr>>> 4    libswiftCore.dylib                 0x000000010564cf40 _assertionFailure(_:_:file:line:flags:) + 443
stderr>>> 5    libswiftCore.dylib                 0x00000001056a9c40 swift_unexpectedError + 216
stderr>>> 6    Error                              0x00000001055e0940 closure #8 in  + 137
stderr>>> 7    libswiftStdlibUnittest.dylib       0x000000010624c700 TestSuite._runTest(name:parameter:) + 943
stderr>>> 8    libswiftStdlibUnittest.dylib       0x000000010624b240 _childProcess() + 1121
stderr>>> 9    Error                              0x00000001055db470 main + 4335
stderr>>> 10   libdyld.dylib                      0x00007fff7099ecc8 start + 1
stderr>>> OK: saw expected "crashed: sigill"
did not find expected string after crash: "main/Error.swift:128"
[     FAIL ] Error.try!/location

@lorentey
Copy link
Member Author

lorentey commented Dec 5, 2020

Ah, it turns out that inserting new lines may have the side effect of changing the line numbers. Fascinating

@lorentey lorentey force-pushed the trap-msg-backdeployment-tests branch from 20f807b to 634c582 Compare December 5, 2020 02:57
@lorentey
Copy link
Member Author

lorentey commented Dec 5, 2020

@swift-ci test

@swift-ci
Copy link
Contributor

swift-ci commented Dec 5, 2020

Build failed
Swift Test OS X Platform
Git Sha - 634c582

@swift-ci
Copy link
Contributor

swift-ci commented Dec 5, 2020

Build failed
Swift Test Linux Platform
Git Sha - 634c582

@lorentey
Copy link
Member Author

lorentey commented Dec 8, 2020

@swift-ci test

@lorentey lorentey merged commit 186a311 into swiftlang:main Dec 10, 2020
@lorentey lorentey deleted the trap-msg-backdeployment-tests branch December 10, 2020 23:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants