Skip to content

Failure when there is no master pseudoclock is ungraceful #12

Closed
@philipstarkey

Description

@philipstarkey

Original report (archived issue) by Chris Billington (Bitbucket: cbillington, GitHub: chrisjbillington).


If you don't define a master pseudoclock (or any devices), you get this obtuse thing:

#!python

Traceback (most recent call last):
  File "/home/bilbo/Desktop/user_scripts/labscriptlib/spinor/__init__.py", line 8, in <module>
    start()
  File "/home/bilbo/bitbucket_clones/labscript/labscript.py", line 1593, in start
    master_pseudoclock, = [pseudoclock for pseudoclock in all_pseudoclocks if pseudoclock.is_master_pseudoclock]
ValueError: need more than 0 values to unpack

This is pretty simple, let's put a better error message there if stop() gets called and there is no master pseudoclock

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingmajor

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions