-
Notifications
You must be signed in to change notification settings - Fork 356
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
Miri test fails with thread_local storage #1360
Comments
Could you try |
This actually is the problem ... thanks! |
Yes, but it's WIP: #1284 |
Sounds great! A bit off-topic but: |
Have a look at the flags with Please open issues if you run into troubles with them or need more specific flags our output to help you debug. |
Btw, if you would like to share that bug and add it to our trophy case, a PR would be very welcome. :) |
Does the trophy also count if I was already having a suspicion about the code in question and then ran |
Hm... not sure.^^ So far we collected bugs that actually made it into a release, or at least into the master branch of a repo. Thank you so much for your kind words about Miri, this is the kind of feedback that motives me to keep working on it. :) |
I started testing my PRs using
miri
viacargo miri test
.In general it is an amazing tool and I already found some undefined behavior using it.
However, in some tests
cargo test
succeeds and yieldsok
for a test whereascargo miri test
yields inFAILED
.Example
Let's look at the PR: https://github.com/paritytech/ink/tree/redo-init-and-flush
Running
cargo test
should yield that all tests are fine.However, running
cargo miri test -- -- key_add
yields the following:Interesting fun fact: When we just test
key_add_sub
withoutkey_add
it starts to work fine as well:The output points to some entity that sits behind a thread local storage.
It seems that those tests have some shared state when using
miri
which causes them to fail.The text was updated successfully, but these errors were encountered: