tolleybot commented on code in PR #34616:
URL: https://github.com/apache/arrow/pull/34616#discussion_r1317926097
##########
python/pyarrow/_dataset_parquet.pyx:
##########
@@ -631,7 +752,13 @@ cdef class ParquetFileWriteOptions(FileWriteOptions):
coerce_timestamps=None,
allow_truncated_timestamps=False,
use_compliant_nested_type=True,
+ encryption_config=None,
)
+ IF PARQUET_ENCRYPTION_ENABLED:
+ if self._properties["encryption_config"] is not None:
+ print("Encryption is not enabled in this build of pyarrow. "
+ "Please reinstall pyarrow with encryption enabled.")
+
Review Comment:
1. I've changed the behavior from printing a message to throwing an
exception. This ensures that users are immediately aware if they're trying to
use encryption in a build that doesn't support it, mitigating the risk of
thinking data is encrypted when it's not.
2. I've added a test to ensure this behavior is correctly implemented and to
prevent any future regressions.
--
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]