Closed givsly-stephen closed 3 months ago
There are potential problems with legacy code and go1.2.1 around the use of init functions - I'm going to start looking there.
Note that this is a problem of xlsx v1.0.5 not the v3 version.
Another piece of information - I ran the code above (fixing the variable name rowOfferName
to rowName
), it compiled, ran and the output loaded fine in LibreOffice. I suspect that this is one of those occasions where Excel is extremely picky about the XML (it wants the XML exactly as it would write it, and won't accept it in any other logically valid form). I don't have Excel to hand, but if you send me the working and not-working xlsx files I can try and work out what changed between them. @givsly-stephen
@givsly-stephen - if you're in fact using V3 you should try the latest release as I have recently fixed an issue with similar results. (See #786 )
Yes, I was using github.com/tealeg/xlsx v1.0.5
see my go.mod
OK - I will take a look at v3.
It's funny though it works perfectly with golang 1.20, but fails with 1.21 -- did golang break compatibility???
Yeah, I did think so. Moving to V3 would require quite a lot of changes on your front, but it's likely to be better maintained going forward.
注释掉golang 源码里这几行就解决了
Stale issue message
UPDATE: Rolledback to golang 1.20.10 and it's all back -- Seems 1.21 is incompatible.
Went back to basics to make a simple HELLO WORLD and still empty. Baffled. Production runs on AWS, but now happening even on my mac.
my go.mod