-
Notifications
You must be signed in to change notification settings - Fork 105
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
Crash "SIGABRT: abort"/"signal arrived during cgo execution" during store code on Alpine 3.19 #523
Comments
Thank you for the report. This is an issue we got reported elsewhere already too. The common error is above your log snippet:
What we know so far is that it is some sort of problem with more recent Alpine versions. E.g. one reporter said
We never saw this issue on GNU linux. |
The root cause is very likely inside Wasmer related to the muslc logic, I've left a comment here. And relevant Wasmer code is here. At Injective we resolved it by using Debian image (which uses glibc) instead of Alpine Linux. And Babylon chain had the same issue and resolved it the same way: babylonchain/babylon#427. |
@sampocs Do you have more info about which alpine 3.16 setup you used initially? Alpine 3.16 being affected is irritating. For us the problem is rather new (late 2023, after Alpine 3.19 release), and we did not hear about it from older Alpine versions. Also I don't see anything open in Wasmer, so it is likely most Alpine versions are not affected. |
Found it. The version before this commit Stride-Labs/stride@6a8f0ce used |
Okay, it seems like Wasmtime had the same issue and fixed it. Essentially the deal is
Wasmer ticket here now: wasmerio/wasmer#4488 |
@webmaster128 sorry for late reply, but yeah you're right we were building with 3.19 and running with 3.16! Glad to hear you tracked down the issue though! |
## Description Closes: #XXXX This PR drops alpine of building environment to 3.18 to avoid from the issues with wasmer. References: CosmWasm/wasmvm#523 wasmerio/wasmer#4488 <!-- Add a description of the changes that this PR introduces and the files that are the most critical to review. --> --- ### Author Checklist *All items are required. Please add a note to the item if the item is not applicable and please add links to any relevant follow up issues.* I have... - [ ] included the correct [type prefix](https://github.com/commitizen/conventional-commit-types/blob/v3.0.0/index.json) in the PR title - [ ] added `!` to the type prefix if API or client breaking change - [ ] targeted the correct branch (see [PR Targeting](https://github.com/desmos-labs/desmos/blob/master/CONTRIBUTING.md#pr-targeting)) - [ ] provided a link to the relevant issue or specification - [ ] followed the guidelines for [building modules](https://docs.cosmos.network/v0.44/building-modules/intro.html) - [ ] included the necessary unit and integration [tests](https://github.com/desmos-labs/desmos/blob/master/CONTRIBUTING.md#testing) - [ ] added a changelog entry to `CHANGELOG.md` - [ ] included comments for [documenting Go code](https://blog.golang.org/godoc) - [ ] updated the relevant documentation or specification - [ ] reviewed "Files changed" and left comments if necessary - [ ] confirmed all CI checks have passed ### Reviewers Checklist *All items are required. Please add a note if the item is not applicable and please add your handle next to the items reviewed if you only reviewed selected items.* I have... - [ ] confirmed the correct [type prefix](https://github.com/commitizen/conventional-commit-types/blob/v3.0.0/index.json) in the PR title - [ ] confirmed `!` in the type prefix if API or client breaking change - [ ] confirmed all author checklist items have been addressed - [ ] reviewed state machine logic - [ ] reviewed API design and naming - [ ] reviewed documentation is accurate - [ ] reviewed tests and test coverage - [ ] manually tested (if applicable) <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **Chores** - Updated the base image for the Desmos Builder to `golang:1.20-alpine3.18` for improved stability and performance. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
This is now fixed in Wasmer but not yet included in a Wasmer release. So we'll likely close this as part of CosmWasm 2.2 |
Done in 2.1 |
If anyone needs to support Go 1.23+ and wasmvm < 2.1 you can create a custom Alpine 3.18 image and install the Go version you need as follows: #576 (comment). However, the recommended solution is to upgrade an up-to-date version of wasmvm and wasmd. |
Context
Stride recently added cosmwasm to the chain and when testing we were noticing stochastic panics when uploading contracts. We eventually resolved this by upgrading the dockerfile from alpine 3.16 to 3.17 but I'd imagine there should also be a change to wasmvm to gracefully catch this exception instead of crashing the chain.
Specifics
This occurred on wasmd
v0.45.0
and wasmvmv1.5.2
(although, I believe we tried out a few other version combinations while debugging and saw the same issue). This was also reproduced on both mac M1 and linux.To test, we started up a network locally with docker and uploaded the same contract repeatedly. We noticed that eventually one of the uploads would fail and take down the chain. The exact upload that caused the panic seemed to be stochastic (e.g. during one run, it would be the 3rd upload, then we'd restart the chain from scratch and this time the panic would occur on the 5th upload, etc.)
The error log is shown below (full logs here). We traced it back to this line, bit it's a bit out of my depth to debug beyond that unfortunately.
Next Steps
I'll defer to you all on how best to handle this. I'm happy to put together a branch with instructions to recreate if it'd be helpful - just let me know!
The text was updated successfully, but these errors were encountered: