Re: [I] [Failing Test]: beam_PreCommit_Python_Coverage suite fails with ModuleNotFoundError: No module named 'pydantic._hypothesis_plugin' [beam]

2024-04-05 Thread via GitHub


tvalentyn commented on issue #30852:
URL: https://github.com/apache/beam/issues/30852#issuecomment-2040443750

   One other problem that causes additional failures in this suite is that in 
the test environment we first install test environment dependencies (e.g., 
tensorflow), then install the Beam package. This has implication on dependency 
resolution, and pip fails to resolve the conflicts.

   We might be able to prevent that if we install both deps in the same 
command, asked on 
https://github.com/tox-dev/tox/issues/2386#issuecomment-2040435212 if that is 
possible.


-- 
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: github-unsubscr...@beam.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



Re: [I] [Failing Test]: beam_PreCommit_Python_Coverage suite fails with ModuleNotFoundError: No module named 'pydantic._hypothesis_plugin' [beam]

2024-04-04 Thread via GitHub


tvalentyn commented on issue #30852:
URL: https://github.com/apache/beam/issues/30852#issuecomment-2038404492

   > the fact that old version of pydantic gets installed due to --pre flag may 
or may not be a factor.
   
   that _is_ the factor. The  pydantic-2.0a4 distribution has the following:
   
   (py38b) :py38b$ cat 
lib/python3.8/site-packages/pydantic-2.0a4.dist-info/entry_points.txt 
   [hypothesis]
   _ = pydantic._hypothesis_plugin


-- 
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: github-unsubscr...@beam.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



Re: [I] [Failing Test]: beam_PreCommit_Python_Coverage suite fails with ModuleNotFoundError: No module named 'pydantic._hypothesis_plugin' [beam]

2024-04-04 Thread via GitHub


tvalentyn commented on issue #30852:
URL: https://github.com/apache/beam/issues/30852#issuecomment-2038213168

   The hypothesis plugin might be provided by hypothesis itself, and we might 
need it for tests that use hypothesis. 
   But looks like Pydantic 2 doesn't work with hypothesis: 
https://github.com/pydantic/pydantic/discussions/5979 , and somehow pydantic 
(which i believe we didn't have in our dependency chain before), now  intefers 
with pytest/hypothesis. the fact that old version of pydantic gets installed 
due to `--pre` flag may or may not be a factor. 
   


-- 
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: github-unsubscr...@beam.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



Re: [I] [Failing Test]: beam_PreCommit_Python_Coverage suite fails with ModuleNotFoundError: No module named 'pydantic._hypothesis_plugin' [beam]

2024-04-04 Thread via GitHub


tvalentyn commented on issue #30852:
URL: https://github.com/apache/beam/issues/30852#issuecomment-2038186835

   
https://stackoverflow.com/questions/71394400/how-to-block-the-hypothesis-pytest-plugin
 has some discussion how to disable it


-- 
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: github-unsubscr...@beam.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



Re: [I] [Failing Test]: beam_PreCommit_Python_Coverage suite fails with ModuleNotFoundError: No module named 'pydantic._hypothesis_plugin' [beam]

2024-04-04 Thread via GitHub


tvalentyn commented on issue #30852:
URL: https://github.com/apache/beam/issues/30852#issuecomment-2038183904

   even though pip selects a  bizzare version for pydantic, pydantic 2, this 
pydantic-hypothesis plugin seems broken
   
   `from pydantic import _hypothesis_plugin` fails, the more correct import 
`from pydantic.v1 import _hypothesis_plugin` also fails with recent versions of 
hypthesis



-- 
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: github-unsubscr...@beam.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



Re: [I] [Failing Test]: beam_PreCommit_Python_Coverage suite fails with ModuleNotFoundError: No module named 'pydantic._hypothesis_plugin' [beam]

2024-04-04 Thread via GitHub


tvalentyn commented on issue #30852:
URL: https://github.com/apache/beam/issues/30852#issuecomment-2038144463

   < 
- pydantic [required: <3, installed: 2.0a4]
   this seems to be an incorrect installer behavior. 2.0a4 shouln't be 
installed under these constraints.
   
   Actually I misread this, it still fits the range but chose version is 
strange, there might be more constraints.
   


-- 
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: github-unsubscr...@beam.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



Re: [I] [Failing Test]: beam_PreCommit_Python_Coverage suite fails with ModuleNotFoundError: No module named 'pydantic._hypothesis_plugin' [beam]

2024-04-04 Thread via GitHub


tvalentyn commented on issue #30852:
URL: https://github.com/apache/beam/issues/30852#issuecomment-2038142141

   from pipdeptree:
   
   ```
   * google-cloud-aiplatform==1.46.0
- proto-plus [required: >=1.22.0,<2.0.0dev, installed: 1.24.0.dev0]
- pydantic [required: <3, installed: 2.0a4]
   ```
   
   this seems to be an incorrect installer behavior. 2.0a4 shouln't be 
installed under these constraints.
   
   not sure how that happens.
   
   Likely what triggered the error for us was a recent release in 
https://pypi.org/project/google-cloud-aiplatform/#history , which added the 
pydantic dependency.


-- 
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: github-unsubscr...@beam.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



Re: [I] [Failing Test]: beam_PreCommit_Python_Coverage suite fails with ModuleNotFoundError: No module named 'pydantic._hypothesis_plugin' [beam]

2024-04-04 Thread via GitHub


tvalentyn commented on issue #30852:
URL: https://github.com/apache/beam/issues/30852#issuecomment-2038121140

   Beam test infra installs pre-released dependencies to detect possible issues 
ahead of releases. The comand: 
   
   ```
pip install --pre "tensorflow_transform>=1.13.0,<1.14.0" 
apache-beam[gcp,test]
   ```
   
   installs pydantic==2.0a4
   
   The command
   
   ```
pip install  "tensorflow_transform>=1.13.0,<1.14.0" apache-beam[gcp,test]
   ```
   
   installs pydantic==1.10.15
   
   The tft requirement comes from:   
https://github.com/apache/beam/blob/21129a41e031c150c3f610639d71a95a3a941243/sdks/python/tox.ini#L316



-- 
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: github-unsubscr...@beam.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



Re: [I] [Failing Test]: beam_PreCommit_Python_Coverage suite fails with ModuleNotFoundError: No module named 'pydantic._hypothesis_plugin' [beam]

2024-04-04 Thread via GitHub


tvalentyn commented on issue #30852:
URL: https://github.com/apache/beam/issues/30852#issuecomment-2037998636

   Not sure how pydantic comes in the picture here yet, but for  
'pydantic._hypothesis_plugin' to be available, it seems that we need to have 
1.0.0

Re: [I] [Failing Test]: beam_PreCommit_Python_Coverage suite fails with ModuleNotFoundError: No module named 'pydantic._hypothesis_plugin' [beam]

2024-04-04 Thread via GitHub


tvalentyn commented on issue #30852:
URL: https://github.com/apache/beam/issues/30852#issuecomment-2037827468

   Sample error: 
https://github.com/apache/beam/actions/runs/8548288262/job/23421776246?pr=30843


-- 
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: github-unsubscr...@beam.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org