7

In Jupyter Notebook, when I highlight text either from within a cell in the notebook or from outside the notebook, Middle-Button click doesn't paste anything as it is supposed to do in many other applications in linux. Is there any setting that would allow one to be able to paste with a Middle-Button click into an Ipython or Jupyter Notebook?

I'm using the notebook in firefox if that matters.

calocedrus
  • 2,430
  • 20
  • 25

1 Answers1

4

The fact that you're using Firefox definitely matters. See this issue on CodeMirror (CodeMirror is the text editor that Juypter uses): Issue #931

In that thread, it references this Firefox issue: https://bugzilla.mozilla.org/show_bug.cgi?id=846674 It seems as though the issue has only recently been fixed, so it may take a little bit to trickle into CodeMirror. You may want to comment on the issue in CodeMirror to inform them that the issue has been fixed on FF and it might prompt them to investigate.

However, Jupyter doesn't automatically use the most recent version of CodeMirror so again you may have to wait a while. If this issue is truly critical then I suggest switching to another browser.

Louise Davies
  • 14,781
  • 6
  • 38
  • 41
  • 1
    it's not truly critical but pasting with the middle-button click is often convenient. Works for Chrome indeed. Next is to set Chrome as default browser for Jupyter only, but that's another topic and there's answers on S.O. such as here http://stackoverflow.com/q/35229604/6358973 – calocedrus Mar 03 '17 at 04:02
  • 2
    3 years later, select-copying *from* Jupyter Notebook in Firefox *still* not working on ArchLinux, latest, Jupyter 6.0.3. – Christoph90 Jun 02 '20 at 10:32
  • @Christoph90 it should work now, having a quick look it seems it got fixed Jan last year (see https://github.com/codemirror/CodeMirror/pull/5751), and if you look at the Jupyter changelog it last upgraded codemirror in v6.0.2, to 5.48.4 (see https://jupyter-notebook.readthedocs.io/en/stable/changelog.html#release-6-0-2), which should include the fix I mentioned as I think it was fixed in 5.44.0 according to the codemirror changelog: https://github.com/codemirror/CodeMirror/releases/tag/5.44.0 – Louise Davies Jun 05 '20 at 14:11
  • it's still not working on Firefox under Manjaro linux – gccallie Apr 11 '22 at 11:15
  • It is not working either in Firefox under FreeBSD 13 – M.E. Aug 20 '22 at 14:40
  • Still not working in Arch – James Mar 30 '23 at 04:55