facultyai / faculty-sync

Synchronise a local directory with your Faculty platform workspace
https://pypi.org/project/faculty_sync/
Apache License 2.0
10 stars 1 forks source link

Vendor Python prompt toolkit #14

Closed pbugnion closed 6 years ago

pbugnion commented 6 years ago

Depending on branch 2.0 of Python prompt toolkit makes sml-sync less stable (since we have no guarantees about backwards compatibility of changes) and harder to install. The easiest fix is probably to vendor Python prompt toolkit and distribute it as part of sml-sync for now.

Happy to hear other suggestions.

pbugnion commented 6 years ago

This may be moot -- Prompt toolkit 2.0 just got merged.

https://pypi.org/project/prompt_toolkit/

janfreyberg commented 6 years ago

That's great news!

pbugnion commented 6 years ago

I was a bit worried that our custom installation would be broken now that branch 2.0 of python prompt toolkit doesn't exist any more, but everything seems to work. It just pulls version 2.0.1 from pypi.

janfreyberg commented 6 years ago

Great! Do you know if ipython has been updated to use the new prompt toolkit? I think ipython breaking was a common pain point but if it still depends on <2.0 then we will still have to recommend a virtual environment...

srstevenson commented 6 years ago

Perhaps packaging sml-sync as a ZIP archive (see PEP 441) would allow sml-sync to be run from a virtual environment with IPython and prompt_toolkit < 2.0 already installed, without breaking them?

Also, Buck and Pants (Facebook and Twitter's respective clones of Google's Bazel build tool) allow you to build PEX files, which are effectively hermetic, relocatable virtual environments. Either Buck or Pants is a very large new dev dependency though.

pbugnion commented 6 years ago

Thanks for that -- very useful.

I've opened a issue #20 about allowing sml-sync and IPython to coexist in an environment with those suggestions. Closing this now.