openforis / sepal

Geographical Data Processing in the Cloud
https://sepal.io/
MIT License
211 stars 46 forks source link

install a copy/paste mechanism on sepal ? #81

Closed 12rambau closed 3 years ago

12rambau commented 3 years ago

I would like to use the pyperclip lib in the sepal_ui lib. This Python lib mainly allows me to control the clipboard programatically. It would be extremelly useful when the outputs of the modules are link that you need to copy paste (any GEE asset).

Is your feature request related to a problem? Please describe. When I use it on my local computer it works no problem but when I try it on SEPAL I get the following error :

PyperclipException: Pyperclip could not find a copy/paste mechanism for your system.

Based on the documentation SEPAL is missing a copy/paste mechanism

Describe the solution you'd like

According to the doc the solution could be to install a copy/paste mechanism from this list :

note @cdanielw, I think it's typically the kind of bug that I can now handle myself. I will let you now in the comments if I find a solution

cdanielw commented 3 years ago

I assume pyperclip is about copy/paste for desktop applications - the APT dependencies certainly indicate that. You use Sepal either through a terminal or from a web browser. Managing the clipboard on the browser would be done with simple JavaScript code, rendered by your Jupyter Notebook.

12rambau commented 3 years ago

yeah but it's really tricky to call js from a .py file (I cannot use the Jupyter magic function) but that is where I'm heading effectively

cdanielw commented 3 years ago

Installing GTK and Qt related dependencies doesn't really make much sense on a non-desktop system.