---
title: "The last two years in Miri"
categories: rust
+reddit: /rust/comments/vq3mmu/the_last_two_years_in_miri/
---
It has been [almost two years]({% post_url 2020-09-28-miri %}) since my last Miri status update.
This means you can explore various different possible choices by passing different *seeds* for Miri to use for its pseudo-random number generator.
The following little shell snippet will run Miri with many different seeds, which is great to be able to locally reproduce a failure that you saw on CI, but that you are having trouble reproducing:
```
-for seed in $({ echo obase=16; seq 0 255; } | bc); do
- MIRIFLAGS="-Zmiri-seed=$seed" cargo miri test || { echo "Failing seed: $seed"; break; };
+for SEED in $({ echo obase=16; seq 0 255; } | bc); do
+ echo "Trying seed: $SEED"
+ MIRIFLAGS=-Zmiri-seed=$SEED cargo miri test || { echo "Failing seed: $SEED"; break; };
done
```
It is important that you use exactly the same `MIRIFLAGS` as CI to ensure the failure can even happen!