Fokko commented on issue #8530:
URL: https://github.com/apache/iceberg/issues/8530#issuecomment-1712482320

   Now including the `pyd` files in the build, and that fixed it.
   
   Now there seems to be an issue with decoding the extreme values:
   ```
   ______________ test_read_int_custom_encode[<lambda>-4294967296] 
_______________
     
     decoder_class = <function <lambda> at 0x00000151BBE3F9D0>
     expected_value = 4294967296
     
         @pytest.mark.parametrize(
             "decoder_class, expected_value",
             list(itertools.product(AVAILABLE_DECODERS, [0, -1, 2**32, 
-(2**32), (2**63 - 1), -(2**63)])),
         )
         def test_read_int_custom_encode(decoder_class: CALLABLE_DECODER, 
expected_value: int) -> None:
             encoded = zigzag_encode(expected_value)
             mis = io.BytesIO(encoded)
             decoder = decoder_class(mis)
             decoded = decoder.read_int()
     >       assert decoded == expected_value, f"Decoded value does not match 
decoded={decoded} expected={expected_value}"
     E       AssertionError: Decoded value does not match decoded=0 
expected=4294967296
     E       assert 0 == 4294967296
     
     
D:\a\incubator-iceberg\incubator-iceberg\python\tests\avro\test_decoder.py:96: 
AssertionError
     ______________ test_read_int_custom_encode[<lambda>--4294967296] 
______________
     
     decoder_class = <function <lambda> at 0x00000151BBE3F9D0>
     expected_value = -4294967296
     
         @pytest.mark.parametrize(
             "decoder_class, expected_value",
             list(itertools.product(AVAILABLE_DECODERS, [0, -1, 2**32, 
-(2**32), (2**63 - 1), -(2**63)])),
         )
         def test_read_int_custom_encode(decoder_class: CALLABLE_DECODER, 
expected_value: int) -> None:
             encoded = zigzag_encode(expected_value)
             mis = io.BytesIO(encoded)
             decoder = decoder_class(mis)
             decoded = decoder.read_int()
     >       assert decoded == expected_value, f"Decoded value does not match 
decoded={decoded} expected={expected_value}"
     E       AssertionError: Decoded value does not match decoded=-2147483648 
expected=-4294967296
     E       assert -2147483648 == -4294967296
     
     
D:\a\incubator-iceberg\incubator-iceberg\python\tests\avro\test_decoder.py:96: 
AssertionError
     __________ 
test_read_int_custom_encode[<lambda>-92233720368[547](https://github.com/Fokko/incubator-iceberg/actions/runs/6130435761/job/16639517931#step:7:555)75807]
 __________
     
     decoder_class = <function <lambda> at 0x00000151BBE3F9D0>
     expected_value = 9223372036854775807
     
         @pytest.mark.parametrize(
             "decoder_class, expected_value",
             list(itertools.product(AVAILABLE_DECODERS, [0, -1, 2**32, 
-(2**32), (2**63 - 1), -(2**63)])),
         )
         def test_read_int_custom_encode(decoder_class: CALLABLE_DECODER, 
expected_value: int) -> None:
             encoded = zigzag_encode(expected_value)
             mis = io.BytesIO(encoded)
             decoder = decoder_class(mis)
             decoded = decoder.read_int()
     >       assert decoded == expected_value, f"Decoded value does not match 
decoded={decoded} expected={expected_value}"
     E       AssertionError: Decoded value does not match decoded=2147483647 
expected=9223372036854775807
     E       assert 2147483647 == 9223372036854775807
     
     
D:\a\incubator-iceberg\incubator-iceberg\python\tests\avro\test_decoder.py:96: 
AssertionError
     _________ test_read_int_custom_encode[<lambda>--9223372036854775808] 
__________
     
     decoder_class = <function <lambda> at 0x00000151BBE3F9D0>
     expected_value = -9223372036854775808
     
         @pytest.mark.parametrize(
             "decoder_class, expected_value",
             list(itertools.product(AVAILABLE_DECODERS, [0, -1, 2**32, 
-(2**32), (2**63 - 1), -(2**63)])),
         )
         def test_read_int_custom_encode(decoder_class: CALLABLE_DECODER, 
expected_value: int) -> None:
             encoded = zigzag_encode(expected_value)
             mis = io.BytesIO(encoded)
             decoder = decoder_class(mis)
             decoded = decoder.read_int()
     >       assert decoded == expected_value, f"Decoded value does not match 
decoded={decoded} expected={expected_value}"
     E       AssertionError: Decoded value does not match decoded=-2147483648 
expected=-922337203685477[580](https://github.com/Fokko/incubator-iceberg/actions/runs/6130435761/job/16639517931#step:7:588)8
     E       assert -2147483648 == -9223372036854775808
   ```
   
   cc @rustyconover 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to