jupyter-widgets / ipywidgets

Interactive Widgets for the Jupyter Notebook
https://ipywidgets.readthedocs.io
BSD 3-Clause "New" or "Revised" License
3.1k stars 946 forks source link

Compatibility issue on Windows with `requests` library #3917

Closed nanaeaubry closed 1 month ago

nanaeaubry commented 1 month ago

We are building a custom widget and it uses the requests library. We noticed that for requests>=2.32 there is an issue but only on Windows machines.

Are there any known issues or fixes for this?

When using requests version 2.31.0 the widget works.

martinRenou commented 1 month ago

Can you elaborate on the mentioned issue?

nanaeaubry commented 1 month ago
import requests
with requests.Session() as session:
   print(session.get("https://www.arcgis.com/sharing/rest/portals/self?f=json").text)

Fails when your library is installed in our environment. If we do this in a python script it works but not within a jupyter environment with our widget.

Our concern is the compatibility at the latest version of ipywidgets and requests as well as with later versions.

nanaeaubry commented 1 month ago

@martinRenou Closing because we saw that the issue is within requests library. Thanks!