Thanks for taking a look, anyway
I did end up filing a bug on Delve and as suspected this did end up being an issue with compiler optimizations - I was using the wrong flags after all and only disabling optimizations for the main package. Apparently what I should be using is -gcflags='all=-N -l', not -gcflags '-N -l'.
Unfortunately even after fixing the above I am seeing the same issue. I still suspect optimizations are not fully disabled. The binary size is identical with and without the above flags, I’d expect the unoptimized binary to be larger…maybe I’m missing something else here. Anyway, here is the issue on Delve and any followup discussion will probably be there (it mentions GoLand handling optimized function warnings from Delve a bit better as well, vs just showing misleading nil/zero-value variables to the user): https://github.com/derekparker/delve/issues/1320
The ignored errors are not for brevity, this is a prototype with a lot of work to do so there is a lot of error handling and other issues to finish and resolve.