#15648: lazy import attributes of a class are not substituted back after the
import
---------------------------------+------------------------
Reporter: nthiery | Owner:
Type: PLEASE CHANGE | Status: new
Priority: major | Milestone: sage-6.1
Component: misc | Resolution:
Keywords: | Merged in:
Authors: | Reviewers:
Report Upstream: N/A | Work issues:
Branch: | Commit:
Dependencies: | Stopgaps:
---------------------------------+------------------------
Comment (by SimonKing):
Strange. Shouldn't `LazyImport` already act as a class attribute? After
all, I see the following code:
{{{
#!python
if owner is None:
if self._namespace and self._namespace[alias] is self:
self._namespace[alias] = self._object
else:
from inspect import getmro
for cls in getmro(owner):
if cls.__dict__.get(alias, None) is self:
setattr(cls, alias, self._object)
break
}}}
This should actually do the trick.
--
Ticket URL: <http://trac.sagemath.org/ticket/15648#comment:2>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica,
and MATLAB
--
You received this message because you are subscribed to the Google Groups
"sage-trac" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sage-trac.
For more options, visit https://groups.google.com/groups/opt_out.