Ticket #163 (new defect)
CustomMonitor throws IndentationError when no arguments given
| Reported by: | mmckerns | Owned by: | mmckerns |
|---|---|---|---|
| Priority: | minor | Milestone: | mystic-0.3a |
| Component: | mystic.tools | Keywords: | |
| Cc: |
Description (last modified by mmckerns) (diff)
CustomMonitor throws IndentationError when no arguments given, should have better error/default behavior
also, CustomMonitor behavior for unnamed channels should be improved
Change History
comment:2 Changed 5 years ago by mmckerns
>>> c = CustomMonitor('x','y',x="Params")
>>> c(1,1)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: __call__() takes exactly 2 arguments (3 given)
>>> c(1)
>>> c.x
[1]
>>> c.y
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
AttributeError: 'Monitor' object has no attribute 'y'
Note: See
TracTickets for help on using
tickets.

>>> c = CustomMonitor() Traceback (most recent call last): File "<stdin>", line 1, in <module> File "build/bdist.macosx-10.3-i386/egg/mystic/monitors.py", line 222, in CustomMonitor File "build/bdist.macosx-10.3-i386/egg/mystic/_genSow.py", line 37, in __call__ File "<string>", line 6 def __call__(self, **kwds): ^ IndentationError: expected an indented block