Skip to content

Conversation

@akrolsmir
Copy link
Contributor

@akrolsmir akrolsmir commented Dec 16, 2020

Fixes #283

Pros: No one will ever have a problem installing Streamlit on Macs due to watchdog again
Cons: Mac users will use the slower(?) poll-based file watcher by default.
But we show them a command line warning, advising them to install watchdog themselves with xcode-select --install; pip install watchdog

The old check in setup.py was only run when a user installs Streamlit from source, but most of the time (e.g. pip install streamlit) will install from the binary wheelfile, so the check in setup.py will go unused. See #2452 for more information.

@akrolsmir akrolsmir requested a review from a team December 16, 2020 17:53
@akrolsmir akrolsmir marked this pull request as draft December 16, 2020 18:05
@akrolsmir akrolsmir marked this pull request as ready for review December 16, 2020 18:15
@akrolsmir akrolsmir requested a review from karriebear December 17, 2020 02:58
Copy link
Contributor

@karriebear karriebear left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't love the solution but haven't been able to find a better conditional dependency we can use instead. The only thing is more people will now see the below message but guess that's better than failing... Would love some classier solution in the future.

Side note, the performance change doesn't seem to be noticeable for local development which I assume is where you would see MacOS being used with Streamlit.

 For better performance, install the Watchdog module:
  
  $ xcode-select --install
  $ pip install watchdog

@akrolsmir
Copy link
Contributor Author

Agreed that I wish we could do better (mostly -- if we could do exactly what was suggested in setup.py, aka install watchdog if xcode tools and gcc are already there). But I didn't see a clear path to that either, and merging this in is an improvement upon the current situation.

@akrolsmir akrolsmir merged commit 9e02173 into streamlit:develop Dec 17, 2020
tconkling added a commit to tconkling/streamlit that referenced this pull request Dec 21, 2020
* develop:
  Extract st.container, columns, container out of delta_generator.py (streamlit#2487)
  Remove the unused variables inside protos (streamlit#2486)
  Stop running cypress-flaky-approval for each PR (streamlit#2490)
  Dynamically import git, and fail gracefully if missing (streamlit#2482)
  Bump React to 17.0.1 (streamlit#2453)
  Fix emojis (streamlit#2480)
  Add missing copyright headers (streamlit#2478)
  Stop requiring watchdog when installing Streamlit on Macs (streamlit#2470)
  Minor tweak to PyArrow warning message (streamlit#2472)
  Use a set literal (streamlit#2476)
  Add type annotations to DeltaGenerator mixins (streamlit#2475)
  Update change log
  Up version to 0.73.0
  Don't require pyarrow on 3.9, and show a warning on custom components (streamlit#2452)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Watchdog error on install (Mac)

2 participants