sundapeng opened a new pull request, #9173:
URL: https://github.com/apache/paimon/pull/9173

   ### Purpose
   
   Python counterpart of #7577. `DLFOpenApiSigner.sign_headers` built the RFC 
1123 `Date` header with `strftime("%a, %d %b %Y %H:%M:%S GMT")`. Python's 
`%a`/`%b` directives follow the process `LC_TIME`, so under non-English locales 
(e.g. zh_CN, ja_JP) the header is localized (e.g. `二, 11 8月 2026 14:30:05 GMT` 
instead of `Tue, 11 Aug 2026 14:30:05 GMT`), which breaks the Aliyun OpenAPI 
signature.
   
   This switches to `email.utils.format_datetime(..., usegmt=True)`, which is 
locale-independent and always emits English day/month names with the identical 
output format.
   
   ### Tests
   
   - Add `test_openapi_date_format_with_chinese_locale` and 
`test_openapi_date_format_with_japanese_locale`, mirroring the Java tests added 
in #7577 (skipped when the locale is not installed on the system).
   - All 11 tests in `dlf_signer_test.py` pass; flake8 clean.


-- 
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]

Reply via email to