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

Upgrade to sagenb 0.10.7 #14330

Closed
kini opened this issue Mar 22, 2013 · 88 comments
Closed

Upgrade to sagenb 0.10.7 #14330

kini opened this issue Mar 22, 2013 · 88 comments

Comments

@kini
Copy link
Contributor

kini commented Mar 22, 2013

Next minor version of sagenb. Will contain LDAP functionality by Robin Martinjak (finally) and some other minor adjustments.

SPKG: http://wstein.org/home/keshav/files/sagenb-0.10.7.1.spkg

When this is merged, merge also #14273.

Depends on #10637

CC: @novoselt @ppurka @ohanar @kcrisman

Component: packages: standard

Author: Keshav Kini

Branch: u/tkluck/ticket/14330

Reviewer: Dmitrii Pasechnik, Karl-Dieter Crisman, Jeroen Demeyer, Andrey Novoseltsev, Punarbasu Purkayastha

Merged: sage-5.12.beta0

Issue created by migration from https://trac.sagemath.org/ticket/14330

@kini kini added this to the sage-5.10 milestone Mar 22, 2013
@jdemeyer

This comment has been minimized.

@ppurka
Copy link
Member

ppurka commented Apr 13, 2013

Dependencies: #10637

@ppurka ppurka changed the title Upgrade to sagenb 0.10.5 Upgrade to sagenb 0.10.6 Apr 13, 2013
@ohanar
Copy link
Member

ohanar commented Apr 27, 2013

comment:5

Any ETA on this?

@ppurka
Copy link
Member

ppurka commented Apr 28, 2013

comment:6

It should be in by the next release. Too late for 5.9.

@ohanar
Copy link
Member

ohanar commented Apr 28, 2013

comment:7

I'm aware of that, but it would be nice to get it in an early 5.10 beta since sagenb won't work in the git releases until this is merged.

@kini
Copy link
Contributor Author

kini commented Apr 28, 2013

comment:8

ppurka just cleaned up a bunch of PRs so I think I'll release 0.10.6 now. Hang on a bit.

@kini
Copy link
Contributor Author

kini commented Apr 28, 2013

comment:9

OK, SPKG is up.

@kini

This comment has been minimized.

@dimpase
Copy link
Member

dimpase commented Apr 30, 2013

comment:10

#10637 includes patches to sagenb Sage repo (sic!). Shouldn't they be patches to the upstream sagenb?

Actually, should #10637 really be a dependency of this ticket?

@ppurka
Copy link
Member

ppurka commented Apr 30, 2013

comment:11

Replying to @dimpase:

#10637 includes patches to sagenb Sage repo (sic!). Shouldn't they be patches to the upstream sagenb?

Actually, should #10637 really be a dependency of this ticket?

If I am not incorrect, these patches are upstream already. So, #10637 is indeed a dependency of this ticket.

@dimpase
Copy link
Member

dimpase commented Apr 30, 2013

comment:12

Replying to @ppurka:

Replying to @dimpase:

#10637 includes patches to sagenb Sage repo (sic!). Shouldn't they be patches to the upstream sagenb?

Actually, should #10637 really be a dependency of this ticket?

If I am not incorrect, these patches are upstream already. So, #10637 is indeed a dependency of this ticket.

If so, the instructions on #10637 are quite unclear.

@kini
Copy link
Contributor Author

kini commented Apr 30, 2013

comment:13

Fixed.

@ppurka
Copy link
Member

ppurka commented Apr 30, 2013

comment:14

The notebook spkg works fine for me. I have a question though, now that ldap is in the notebook. Are there any other (system) requirements for getting the ldap functionality working?

@jdemeyer
Copy link

comment:15
sage -t devel/sagenb-main/sagenb/notebook/cell.py
**********************************************************************
File "devel/sagenb-main/sagenb/notebook/cell.py", line 228, in sagenb.notebook.cell.Cell_generic.worksheet
Failed example:
    W = nb.create_new_worksheet('Test', 'admin')
Exception raised:
    Traceback (most recent call last):
      File "/mazur/release/merger/sage-5.10.beta2/local/lib/python2.7/site-packages/sage/doctest/forker.py", line 454, in _run
        self.execute(example, compiled, test.globs)
      File "/mazur/release/merger/sage-5.10.beta2/local/lib/python2.7/site-packages/sage/doctest/forker.py", line 813, in execute
        exec compiled in globs
      File "<doctest sagenb.notebook.cell.Cell_generic.worksheet[3]>", line 1, in <module>
        W = nb.create_new_worksheet('Test', 'admin')
      File "/mazur/release/merger/sage-5.10.beta2/devel/sagenb/sagenb/notebook/notebook.py", line 461, in create_new_worksheet
        W = self.worksheet(username)
      File "/mazur/release/merger/sage-5.10.beta2/devel/sagenb/sagenb/notebook/notebook.py", line 757, in worksheet
        id_number = self.new_id_number(username)
      File "/mazur/release/merger/sage-5.10.beta2/devel/sagenb/sagenb/notebook/notebook.py", line 769, in new_id_number
        u = self.user(username).conf()
      File "/mazur/release/merger/sage-5.10.beta2/devel/sagenb/sagenb/notebook/notebook.py", line 279, in user
        return self.user_manager().user(username)
      File "/mazur/release/merger/sage-5.10.beta2/devel/sagenb/sagenb/notebook/user_manager.py", line 110, in user
        return self._user(username)
      File "/mazur/release/merger/sage-5.10.beta2/devel/sagenb/sagenb/notebook/user_manager.py", line 520, in _user
        raise KeyError, "no user '%s'"%username
    KeyError: "no user 'admin'"
**********************************************************************

PS: the value of a KeyError should be the missing key. So you should either

raise KeyError(username)

or

raise LookupError("no user '%s'"%username)

@jdemeyer
Copy link

comment:16
sage -t devel/sagenb-main/sagenb/notebook/user_manager.py
**********************************************************************
File "devel/sagenb-main/sagenb/notebook/user_manager.py", line 571, in sagenb.notebook.user_manager.OpenIDUserManager.get_username_from_openid
Failed example:
    UM.create_new_openid('https://www.google.com/accounts/o8/id?id=AItdaWgzjV1HJTa552549o1csTDdfeH6_bPxF14', 'thedude')
Exception raised:
    Traceback (most recent call last):
      File "/mazur/release/merger/sage-5.10.beta2/local/lib/python2.7/site-packages/sage/doctest/forker.py", line 454, in _run
        self.execute(example, compiled, test.globs)
      File "/mazur/release/merger/sage-5.10.beta2/local/lib/python2.7/site-packages/sage/doctest/forker.py", line 813, in execute
        exec compiled in globs
      File "<doctest sagenb.notebook.user_manager.OpenIDUserManager.get_username_from_openid[3]>", line 1, in <module>
        UM.create_new_openid('https://www.google.com/accounts/o8/id?id=AItdaWgzjV1HJTa552549o1csTDdfeH6_bPxF14', 'thedude')
      File "/mazur/release/merger/sage-5.10.beta2/devel/sagenb/sagenb/notebook/user_manager.py", line 594, in create_new_openid
        if not self._conf['openid']:
    KeyError: 'openid'
**********************************************************************

@ppurka
Copy link
Member

ppurka commented May 3, 2013

comment:17

@jdemeyer Can you say why there are ImportError and IOError on doctesting files which have no doctests in them? The specific issue I am talking about is in this sagenb ticket.

@kcrisman
Copy link
Member

kcrisman commented May 7, 2013

comment:18

When using this ticket, I get the following problem with sage -n. I can't say whether this is unique to me.

Executing twistd  --pidfile="sage_notebook.sagenb/sagenb.pid" -ny "sage_notebook.sagenb/twistedconf.tac"
Unhandled Error
Traceback (most recent call last):
  File "/Users/.../sage-5.9.rc1/local/lib/python2.7/site-packages/Twisted-12.3.0-py2.7-macosx-10.7-x86_64.egg/twisted/application/app.py", line 652, in run
    runApp(config)
  File "/Users/.../sage-5.9.rc1/local/lib/python2.7/site-packages/Twisted-12.3.0-py2.7-macosx-10.7-x86_64.egg/twisted/scripts/twistd.py", line 23, in runApp
    _SomeApplicationRunner(config).run()
  File "/Users/.../sage-5.9.rc1/local/lib/python2.7/site-packages/Twisted-12.3.0-py2.7-macosx-10.7-x86_64.egg/twisted/application/app.py", line 386, in run
    self.application = self.createOrGetApplication()
  File "/Users/.../sage-5.9.rc1/local/lib/python2.7/site-packages/Twisted-12.3.0-py2.7-macosx-10.7-x86_64.egg/twisted/application/app.py", line 451, in createOrGetApplication
    application = getApplication(self.config, passphrase)
--- <exception caught here> ---
  File "/Users/.../sage-5.9.rc1/local/lib/python2.7/site-packages/Twisted-12.3.0-py2.7-macosx-10.7-x86_64.egg/twisted/application/app.py", line 462, in getApplication
    application = service.loadApplication(filename, style, passphrase)
  File "/Users/.../sage-5.9.rc1/local/lib/python2.7/site-packages/Twisted-12.3.0-py2.7-macosx-10.7-x86_64.egg/twisted/application/service.py", line 405, in loadApplication
    application = sob.loadValueFromFile(filename, 'application', passphrase)
  File "/Users/.../sage-5.9.rc1/local/lib/python2.7/site-packages/Twisted-12.3.0-py2.7-macosx-10.7-x86_64.egg/twisted/persisted/sob.py", line 210, in loadValueFromFile
    exec fileObj in d, d
  File "sage_notebook.sagenb/twistedconf.tac", line 15, in <module>
    import base as flask_base
  File "/Users/.../sage-5.9.rc1/devel/sagenb/flask_version/base.py", line 10, in <module>
    from flaskext.openid import OpenID
exceptions.ImportError: No module named openid

Failed to load application: No module named openid

Traceback (most recent call last):
  File "/Users/.../sage-5.9.rc1/local/bin/sage-notebook", line 34, in <module>
    notebook()
  File "/Users/.../sage-5.9.rc1/devel/sagenb/sagenb/notebook/notebook_object.py", line 219, in __call__
    return self.notebook(*args, **kwds)
  File "/Users/.../sage-5.9.rc1/devel/sagenb/sagenb/notebook/run_notebook.py", line 608, in notebook_run
    raise socket.error
socket.error

@ppurka
Copy link
Member

ppurka commented May 7, 2013

comment:19

Are you using the git version of sage-5.9.rc1? I have seen this when using the git version and it is a known bug. Normal sage-5.9.rc1 worked fine here (Linux).

@kcrisman
Copy link
Member

kcrisman commented May 8, 2013

comment:20

Are you using the git version of sage-5.9.rc1? I have seen this when using the git version and it is a known bug. Normal sage-5.9.rc1 worked fine here (Linux).

No, just the git version of the sagenb (latest). I don't know how to use the git version of 5.9.rc1 :)

@ppurka
Copy link
Member

ppurka commented May 8, 2013

comment:21

Ok. I have tested

  1. sage-5.9.beta1 on my Gentoo Linux laptop with (i) sagenb from git and (ii) the sagenb-0.10.6 spkg here.
  2. sage-5.9 on a Gentoo Linux desktop with (i) sagenb from git and (ii) the spkg here.
  3. sage-5.9.rc1 on a Debian 6 server with (i) sagenb from git and (ii) the spkg here.

All of them work.

@jdemeyer
Copy link

comment:22

In SPKG.txt, the following is wrong:

== License ==

GPLv2+

MathJax is licensed under Apache 2.0, which is compatible with GPLv3 but not GPLv2.

@jdemeyer
Copy link

comment:23

Also in setup.py:

    code = setup(name = 'sagenb',
          version     = '0.10.6',
          description = 'The Sage Notebook',
          license     = 'GNU General Public License (GPL) v2+',

@novoselt
Copy link
Member

comment:67

If this is the case, perhaps we should not ship sanitation with Sage. Those who run world-accessible servers should know what they are doing, what are the risks, and how to deal with them, in particular they are free to install the branch with sanitation. For those who run servers for trusted/known users only, sanitation is not really necessary...

@ppurka
Copy link
Member

ppurka commented Jun 25, 2013

comment:68

I just tried and it is possible to remove (not revert) the commits by running

git rebase -i

and removing the commits corresponding to

| * | 003436a - Remove the remainder of the whatwg unsafe tags. 9 months ago <Jason Grout>
| * | 9f5bcf4 - Don't scrub html twice. 9 months ago <Jason Grout>
| * | 941299f - Add nofollow to html scrubbing.  Thanks to Volker Braun for bringing it up. 9 months ago <Jason Grout>
| * | 77fb49a - Sanitize the output and text cells of published worksheets. 9 months ago <Jason Grout>

Then we need to push (force) this update to sagenb master.

Do we want to do that? Will this automatically revert the status of jason's pull request to "open" again?

@kini
Copy link
Contributor Author

kini commented Jun 25, 2013

comment:69

No, we don't want to force push to master. That's a very bad practice and will screw up anyone else who has pulled from the repo since I released 0.10.7. This will have to be 0.10.7.1, I'm afraid :P I'll cut it, give me a sec

@kini
Copy link
Contributor Author

kini commented Jun 25, 2013

@kini

This comment has been minimized.

@kini
Copy link
Contributor Author

kini commented Jun 25, 2013

Changed reviewer from Dmitrii Pasechnik to Dmitrii Pasechnik, Karl-Dieter Crisman, Jeroen Demeyer, Andrey Novoseltsev, Punarbasu Purkayastha

@novoselt
Copy link
Member

comment:72

Thanks Keshav, published formulas and pictures are back, will keep testing!

@kcrisman
Copy link
Member

comment:73

Thanks for catching this, Andrey! Sorry for missing this somehow :(

@ppurka
Copy link
Member

ppurka commented Jun 30, 2013

comment:74

I see [Math Processing Error] on published worksheets when the renderer is set to SVG. It works fine when it is kept at the default HTML-CSS.

3D plots show up fine (the 2D static version at least), and plots show up fine. I think this ticket is good to go.

@tkluck
Copy link

tkluck commented Jul 22, 2013

Branch: u/tkluck/ticket/134330

@tkluck
Copy link

tkluck commented Jul 22, 2013

comment:76

I added a git branch containing just the spkg meta files. It needs the file sagenb-0.10.7.1.tar.gz, which is available to people with accounts on boxen in my home directory (/home/tkluck/sagenb-0.10.7.1.tar.gz)

This does not (yet?) incorporate #10637 or #14273.

@tkluck
Copy link

tkluck commented Jul 22, 2013

Changed branch from u/tkluck/ticket/134330 to u/tkluck/ticket/14330

@tkluck
Copy link

tkluck commented Jul 23, 2013

comment:78

I also put the tarball on http://www.infty.nl/misc/sagenb-0.10.7.1.tar.gz

@tkluck
Copy link

tkluck commented Jul 23, 2013

comment:79

Why does this ticket depend on #10637?

On the one hand, we need to update to version 0.10.7.1 of the notebook to be able to switch to the integrated git repository. On the other hand, we try to keep the number of changes to a minimum. Is it okay to update the sage notebook in the git repository without applying #10637 there?

@ppurka
Copy link
Member

ppurka commented Jul 23, 2013

comment:80

Replying to @tkluck:

Why does this ticket depend on #10637?

The changes to the notebook to support sws2rst have already been merged and is present in 0.10.7.1.

As such you don't really need to apply #10637 to Sage to get a functional notebook. You won't lose any functionality in Sage, except that the sws2rst option won't be present. Doctests in sagenb should not fail, as long as you do not doctest the optional parts.

@jdemeyer
Copy link

Changed work issues from published formulas to none

@jdemeyer
Copy link

jdemeyer commented Aug 2, 2013

Merged: sage-5.12.beta0

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

No branches or pull requests

8 participants