geyanggang commented on PR #13596:
URL: https://github.com/apache/gravitino/pull/13596#issuecomment-5887880413

   > Non-blocking, pre-existing dependency compatibility issue noticed while 
reviewing this change:
   > 
   > With `uv sync --locked`, `test_legacy_metadata_fullname_is_still_accepted` 
fails for both statistic tools: `metadata_fullname` is rejected as an 
unexpected argument and `metadata_full_name` is reported missing. `uv.lock` 
pins Pydantic 2.11.7, which does not honor 
`Field(validation_alias=AliasChoices(...))` during function argument 
validation. The upstream fix shipped in Pydantic 2.12.0: 
[pydantic/pydantic#12340](https://github.com/pydantic/pydantic/pull/12340).
   > 
   > I reproduced the same failures on the target base. Changing only Pydantic 
and its matching pydantic-core to 2.13.5/2.46.5 made all five statistic-tool 
tests pass. The Gradle run also passed all 269 tests, but it resolves 
dependencies via `uv pip install -e .` rather than the lockfile and installed 
Pydantic 2.13.5. The passing MCP integration job runs `tests/integration`, 
which does not include this unit test.
   > 
   > Could we address this in a follow-up by declaring `pydantic>=2.12` as a 
runtime dependency, updating `uv.lock`, and running the existing compatibility 
tests against the locked environment? This is not a regression introduced by 
this PR.
   
   OK. I'll fix the issue you mentioned in this PR.
   Declared `pydantic>=2.12.0,<3` as a runtime dependency and regenerated 
uv.lock
   (pydantic 2.11.7 → 2.13.5, pydantic-core 2.33.2 → 2.46.5). Verified against 
the
   locked environment as you suggested: with `uv sync --locked`, all 5 tests in
   test_statistic.py pass, including 
test_legacy_metadata_fullname_is_still_accepted.
   The Gradle run (269 tests) and pylint still pass, and uv sync --no-dev still
   ships none of the dev tools.


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