zed
zed copied to clipboard
VNG dict vectors don't always roundtrip succesfully
To reproduce:
> git checkout origin/jamii-fuzz-vng-repro
> cd vng
> ZED_USE_DICT=1 go test -run FuzzVngRoundtripGen/0169eec3758e54cb
--- FAIL: FuzzVngRoundtripGen (0.00s)
--- FAIL: FuzzVngRoundtripGen/0169eec3758e54cb (0.00s)
vng_test.go:123: comparing: len(in)=2 vs len(out)=2
vng_test.go:132: comparing: in[0]=<ip> vs out[0]=<uint8>
vng_test.go:137: values have different zng bytes: [26] vs [0]
vng_test.go:132: comparing: in[1]=<uint8> vs out[1]=<uint8>
FAIL
exit status 1
I believe that at least one of the issues here is that makeDictVector is called multiple times while Metadata is called only once. So some intermediate vectors are created with a dict that is different from the one stored in the metadata.
Fixed in #4862.