carloea2 opened a new pull request, #8174: URL: https://github.com/apache/texera/pull/8174
### What changes were proposed in this PR? Hash Python timestamp fields using epoch milliseconds, matching Java `Timestamp.hashCode`. Negative submillisecond values use floor semantics, preserving Java behavior before the epoch. Before: with three receivers, `1970-01-01T00:00:00.500Z` produced Python hash 31 and Scala hash 531, selecting different workers. After: both hashes are 531 and both select worker 0. ### Any related issues, documentation, discussions? Closes #8173 ### How was this PR tested? The new regression was red before the source change with two failures and one pass. After the fix, its negative, zero, and positive timestamp cases all pass. ```text python -c "import sys,pytest; sys.path[:0]=[r'<worktree>\amber\src\main\python',r'<checkout>\amber\src\main\python']; raise SystemExit(pytest.main([r'amber/src/test/python/core/models/test_tuple.py::TestTuple::test_timestamp_hash_matches_java_milliseconds','-q','-p','no:cacheprovider']))" ``` The complete tuple and partitioner suites pass: ```text python -c "import sys,pytest; sys.path[:0]=[r'<worktree>\amber\src\main\python',r'<checkout>\amber\src\main\python']; raise SystemExit(pytest.main([r'amber/src/test/python/core/models/test_tuple.py','-q','-p','no:cacheprovider']))" python -c "import sys,pytest; sys.path[:0]=[r'<worktree>\amber\src\main\python',r'<checkout>\amber\src\main\python']; raise SystemExit(pytest.main([r'amber/src/test/python/core/architecture/sendsemantics/test_partitioners.py','-q','-p','no:cacheprovider']))" ``` Results: 106 tuple tests and 35 partitioner tests passed. ```text ruff check amber/src/main/python amber/src/test/python ruff format --check amber/src/main/python amber/src/test/python ``` Ruff checked 213 files successfully. JDK 17 independently confirmed all affected expected hashes. The fixed production hash partitioner selected receiver A for the half-second timestamp, matching Scala bucket 0. ### Was this PR authored or co-authored using generative AI tooling? Generated-by: OpenAI Codex, GPT-5 -- 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]
