Fokko commented on code in PR #1976:
URL: https://github.com/apache/iceberg-python/pull/1976#discussion_r2079377868
##########
pyiceberg/avro/codecs/__init__.py:
##########
@@ -26,15 +26,21 @@
from __future__ import annotations
-from typing import Dict, Optional, Type
+from typing import Dict, Literal, Optional, Type
+
+from typing_extensions import TypeAlias
from pyiceberg.avro.codecs.bzip2 import BZip2Codec
from pyiceberg.avro.codecs.codec import Codec
from pyiceberg.avro.codecs.deflate import DeflateCodec
from pyiceberg.avro.codecs.snappy_codec import SnappyCodec
from pyiceberg.avro.codecs.zstandard_codec import ZStandardCodec
-KNOWN_CODECS: Dict[str, Optional[Type[Codec]]] = {
+AvroCompressionCodec: TypeAlias = Literal["null", "bzip2", "snappy",
"zstandard", "deflate"]
Review Comment:
Hey @ndrluis that's a great catch! We should use `zstd` instead. Avro uses
`zstandard`, that's why I copied it here, but it is actually wrong.
--
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]