Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

jupyter python2 notebook may truncate in firefox #1537

Closed
DrXyzzy opened this issue Jan 17, 2017 · 9 comments
Closed

jupyter python2 notebook may truncate in firefox #1537

DrXyzzy opened this issue Jan 17, 2017 · 9 comments
Assignees
Labels

Comments

@DrXyzzy
Copy link
Contributor

DrXyzzy commented Jan 17, 2017

Reported on sage-cloud mailing list here, including zip file: https://groups.google.com/d/msg/sage-cloud/b8tgmK8gZ14/5eFs9HFaEQAJ

To reproduce:

  • use firefox browser
  • upload Skill4.zip into an SMC project and unzip
  • in a .term, do wc -c Skill-04-ReadWriteFiles.ipynb; file length should be 20693
  • open Skill-04-ReadWriteFiles.ipynb
    • you may see a warning like the screen capture below
    • notebook appears truncated; last cell displayed ends with paragraph
      __Using np.savetxt to Write Data Files ... __
  • wait about a minute for the first jupyter auto-save
  • in .term, again do wc -c Skill-04-ReadWriteFiles.ipynb and note file length is now 4202

Error seen on opening Skill-04-ReadWriteFiles.ipynb in firefox:

screenshot 2017-01-17 12 01 49

Workaround 1 - use Google Chrome at least once

  • close jupyter notebook and restore Skill-04-ReadWriteFiles.ipynb by unzipping again
  • open Skill-04-ReadWriteFiles.ipynb in chrome
  • execute the first cell
  • save the notebook
  • close the SMC chrome browser tab
  • in firefox session
    • note wc -c Skill-04-ReadWriteFiles.ipynb now gives length 13384
    • open jupyter notebook and observe it is no longer truncated

Workaround 2 - convert to .sagews:

  • close jupyter notebook and restore Skill-04-ReadWriteFiles.ipynb by unzipping again
  • convert to sagews with smc-ipynb2sagews Skill-04-ReadWriteFiles.ipynb
  • open Skill-04-ReadWriteFiles.sagews and work with sagews
@DrXyzzy DrXyzzy added A-firefox A-jupyter P-blocker Critical -- Stop most things to fix labels Jan 17, 2017
@williamstein
Copy link
Contributor

Interesting: the fontSize is undefined error is the same thing that I fixed in #1343

@williamstein
Copy link
Contributor

My latest commit seems to fix this -- it's just a worse hack...

@DrXyzzy
Copy link
Contributor Author

DrXyzzy commented Jan 18, 2017

Problem is still there for me. Firefox 50.1.0. OS X 10.11.6. I reset my dev project, refreshed Firefox SMC browser tab, and unzipped a fresh copy of Skill-04-ReadWriteFiles.ipynb.

Screen capture shows where the notebook is truncated as indicated by drop shadow below In [3]: display.
screenshot 2017-01-18 04 48 12

@DrXyzzy DrXyzzy reopened this Jan 18, 2017
@DrXyzzy
Copy link
Contributor Author

DrXyzzy commented Jan 18, 2017

I see, the commit was reverted.

@williamstein
Copy link
Contributor

NOTE: I've completely disabled Jupyter + firefox for now.

@DrXyzzy
Copy link
Contributor Author

DrXyzzy commented Feb 27, 2017

As with #1650, I'm marking this blocked until the next release of Firefox (after 51.0.1).

@DrXyzzy
Copy link
Contributor Author

DrXyzzy commented Mar 21, 2017

I just tested in Firefox 52.0, getting around the FF block on .ipynb by overriding the user agent setting. Bug is still there, i.e. opening the test notebook mentioned above in FF results in truncation - in fact it is even worse, in that none of the test notebook is visible on opening the file. Character count of Skill-04-ReadWriteFiles.ipynb goes from 14913 after unzip to 617 after attempting to open in FF. File opens without truncation in Safari.

@DrXyzzy DrXyzzy assigned williamstein and unassigned DrXyzzy Mar 21, 2017
@DrXyzzy
Copy link
Contributor Author

DrXyzzy commented Mar 21, 2017

process: reassigning to @williamstein because it looks as if this issue will unblock when some work in progress with Jupyter is completed.

@williamstein
Copy link
Contributor

Closing this in favor of #1754, where Firefox will work perfectly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants