Streamlit_pandas_profiling and ydata profiling dependency issues

─────────────────────────────────────── uv ───────────────────────────────────────────Using uv pip install.  × No solution found when resolving dependencies:  ╰─▶ Because the current Python version (3.12.7) does not satisfy      Python>=3.10,<3.12 and streamlit-ydata-profiling==0.2.1      depends on Python>=3.10,<3.12, we can conclude that      streamlit-ydata-profiling==0.2.1 cannot be used.      And because you require streamlit-ydata-profiling==0.2.1, we can      conclude that the requirements are unsatisfiable.Checking if Streamlit is installed─────────────────────────────────────────────────────────────────────────────────────

facing this error while deploying on the streamlit working fine on local host

Hi @Ghulam1, welcome to the forum!

Based on the error message, it looks like one of your dependencies doesn’t support python 3.12 yet (Python>=3.10,<3.12) – if you go to your app settings and change the python version to 3.11, I would guess that it will work.

let me try

i am unable to find python version in app settings

Ah, sorry – I thought there was a way to change it in settings. You might need to delete the app and re-create it. And, when you re-create it, you can click “Advanced Settings” and select a different python version.

Note that you could probably also change your requirements.txt to not specify a specific version of that package, and that might work instead of changing your python version.

Python version is change to 3.11

now facing this error
visions[type-image-path] 0.7.5 depends on visions 0.7.5

andas-profiling 3.2.0 depends on visions==0.7.4
    ydata-profiling 4.7.0 depends on visions<0.7.7 and >=0.7.5
    visions[type-image-path] 0.7.5 depends on visions 0.7.5 (from https://files.pythonhosted.org/packages/62/fa/6a8539c83d2ccbd08d5f0c843b1784af9ff514e77f4c9d5d6800fdd340f6/visions-0.7.5-py3-none-any.whl (from https://pypi.org/simple/visions/) (requires-python:>=3.6))
    pandas-profiling 3.1.0 depends on visions==0.7.4
    ydata-profiling 4.7.0 depends on visions<0.7.7 and >=0.7.5
    visions[type-image-path] 0.7.5 depends on visions 0.7.5 (from https://files.pythonhosted.org/packages/62/fa/6a8539c83d2ccbd08d5f0c843b1784af9ff514e77f4c9d5d6800fdd340f6/visions-0.7.5-py3-none-any.whl (from https://pypi.org/simple/visions/) (requires-python:>=3.6))
    pandas-profiling 3.0.0 depends on visions==0.7.1

To fix this you could try to:
1. loosen the range of package versions you've specified
2. remove package versions to allow pip attempt to solve the dependency conflict

ERROR: ResolutionImpossible: for help visit https://pip.pypa.io/en/latest/topics/dependency-resolution/#dealing-with-dependency-conflicts

[notice] A new release of pip is available: 24.0 -> 24.2

this is my repositry link

using ydata-profiling =4.8

I did some fiddling with the app and dependencies – I think the streamlit_pandas_profiling package was really the issue, was just out of date. Fortunately, the ydata-profiling package works as a standalone package if you just use st.html(profile.html)

Here’s my version of the app, and requirements.txt which now works – it’s currently running on python 3.12

Repo: GitHub - sfc-gh-zblackwood/new_data
App: https://newdata-95at7sqj7whk2lzjbxnnom.streamlit.app/

1 Like

Thanks a lot blackary ,
so next i should only use ydata profiling ?

Yes, that’s what I would recommend – just use ydata-profiling, rather than using the streamlit-pandas-profiling

That package would probably work fine if this PR got merged in Switch to ydata-profiling by bwest2397 · Pull Request #46 · okld/streamlit-pandas-profiling · GitHub, but for now it’s not really working, so I would just use st.html(profile.html) like I did in my app.

There is also streamlit-ydata-profiling.

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.