1 Tips and tricks on how to debug things as a Prepack developer
Nikolai Tillmann edited this page 2018-08-16 10:14:21 -07:00

I got an invariant failures with a message similar to "serialized N of M" (where N !== M)

Comment out the invariant in the code (and possibly other subsequently failing invariants) so that Prepack generates code. Look at the debugging output on the console and generated code to identify the problematic values. Look at next section for information how to debug issues around particular values.

What's up with particular values

If you wonder if why a value like _5 got emitted in the way it was, use the CLI arguments --debugIdentifiers _5 --debugScopes to get an annotated program and additional debugging output on the console.