Skip to content

Conversation

@freddyaboulton
Copy link

@freddyaboulton freddyaboulton commented Sep 5, 2021

The issue with the unit tests originally failing is that cibuildwheel will run the unit tests from the {package} directory, which in this case is prophet/python. This means that pkg_resources.resource_filename will look first in the local prophet/python/prophet/stan_model/ directory since the current directory is first in sys.path. You can sanity-check this logic by pip installing one of the wheels, cd-ing into prophet/python and running the unit tests. That should fail provided you don't have any compiled models in prophet/stan_model.

The solution I found was to run the unit tests from the package directory with pytest --pyargs prophet. I aslo added some cmdtanpy-backend unit tests to sanity check that.

You can see the unit tests passing on my for here

@freddyaboulton freddyaboulton marked this pull request as ready for review September 5, 2021 19:27
@tcuongd tcuongd merged commit a76d33a into facebook:tcuongd-cmdstanpy-wheel Oct 2, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants