To me the error looks like you have an undefined Tensor (aka None) showing up unexpectedly.
I would try to cut down the model (or just the JITed part) a bit to zoom into where it happens. (You can see a method I use to grab a submodule when searching for DebugWrap in my blog Post on PyTorch and TVM 10).
Naturally, we would be most grateful if you found a reproducing snippet that you can share to fix this in PyTorch.
Best regards
Thomas