-
-
Notifications
You must be signed in to change notification settings - Fork 404
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
Magic preprocessors for conversion to vanilla Python #1491
Changes from 52 commits
3f645bb
b7264ff
eb273c4
f02c959
48dbfe3
86af334
a1bb4e1
6f6dda3
b291d63
5fde8ba
642f8e7
3f3e560
31fe462
59750c1
ca68c67
c39e32a
c2b8780
9eea15f
0b5677f
4df77bf
421f446
33140ac
7ffb61c
071f4e1
9f4a189
6470d16
bd8b5d6
9070d2b
9f6d623
5a34cfc
e7be1e1
9280c6d
27915d5
20481c4
26e08d0
a258e8d
a731085
cb2926b
d390228
7d920dc
c71b009
b2b86df
746db40
29ce705
33589d6
d60f78d
9b4e250
c9009f4
98eecbb
9cfbfe0
d4054fb
80ad114
f5f12c2
a325041
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
|
||
When working on a notebook in examples/ make sure to run ``python | ||
examples.py reference Example.ipynb`` to locate any references to that | ||
notebook in the documenation. | ||
|
||
If there are any such references, please check that the content of those | ||
pages is still correct. |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
""" | ||
Stub for script that will do things like generate an index and check for | ||
references in the documentation. | ||
""" |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -1077,13 +1077,24 @@ def __unicode__(self): | |
return unicode(PrettyPrinter.pprint(self)) | ||
|
||
|
||
|
||
def __call__(self, options=None, **kwargs): | ||
return self.opts(options, **kwargs) | ||
|
||
def opts(self, options=None, **kwargs): | ||
""" | ||
Apply the supplied options to a clone of the object which is | ||
then returned. Note that if no options are supplied at all, | ||
all ids are reset. | ||
""" | ||
from ..util.parser import OptsSpec | ||
if isinstance(options, basestring): | ||
try: | ||
options = OptsSpec.parse(options) | ||
except: | ||
options = OptsSpec.parse( | ||
'{clsname} {options}'.format(clsname=self.__class__.__name__, | ||
options=options)) | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Seems okay for now but it might be better to list an explicit exception. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Sure. This falls under my bullet points for something to improve. The exception is part of it, but the whole There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Specified |
||
|
||
groups = set(Store.options().groups.keys()) | ||
if kwargs and set(kwargs) <= groups: | ||
if not all(isinstance(v, dict) for v in kwargs.values()): | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How come we need
Dimensioned
in the top-level namespace?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks! That is a stray/unnecessary import now - I still need
Dimensioned
inutil.__init__.py
though...There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed in f5f12c2