labgrid.remote package

Submodules

labgrid.remote.authenticator module

labgrid.remote.client module

The remote.client module contains the functionality to connect to a coordinator, acquire a place and interact with the connected resources

exception labgrid.remote.client.Error[source]

Bases: Exception

__module__ = 'labgrid.remote.client'
__weakref__

list of weak references to the object (if defined)

exception labgrid.remote.client.UserError[source]

Bases: labgrid.remote.client.Error

__module__ = 'labgrid.remote.client'
exception labgrid.remote.client.ServerError[source]

Bases: labgrid.remote.client.Error

__module__ = 'labgrid.remote.client'
labgrid.remote.client.start_session(url, realm, extra)[source]
labgrid.remote.client.find_role_by_place(config, place)[source]
labgrid.remote.client.find_any_role_with_place(config)[source]
labgrid.remote.client.main()[source]

labgrid.remote.common module

class labgrid.remote.common.ResourceEntry(data)[source]

Bases: object

__attrs_post_init__()[source]
property acquired
property avail
property cls
property params
property args

arguments for resource construction

property extra

extra resource information

asdict()[source]
update(data)[source]

apply updated information from the exporter on the coordinator

acquire(place_name)[source]
release()[source]
__attrs_attrs__ = (Attribute(name='data', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False),)
__dict__ = mappingproxy({'__module__': 'labgrid.remote.common', '__attrs_post_init__': <function ResourceEntry.__attrs_post_init__>, 'acquired': <property object>, 'avail': <property object>, 'cls': <property object>, 'params': <property object>, 'args': <property object>, 'extra': <property object>, 'asdict': <function ResourceEntry.asdict>, 'update': <function ResourceEntry.update>, 'acquire': <function ResourceEntry.acquire>, 'release': <function ResourceEntry.release>, '__dict__': <attribute '__dict__' of 'ResourceEntry' objects>, '__weakref__': <attribute '__weakref__' of 'ResourceEntry' objects>, '__doc__': None, '__attrs_attrs__': (Attribute(name='data', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False),), '__repr__': <function ResourceEntry.__repr__>, '__init__': <function ResourceEntry.__init__>})
__init__(data) → None

Initialize self. See help(type(self)) for accurate signature.

__module__ = 'labgrid.remote.common'
__repr__()

Automatically created by attrs.

__weakref__

list of weak references to the object (if defined)

class labgrid.remote.common.ResourceMatch(exporter, group, cls, name=None, rename=None)[source]

Bases: object

classmethod fromstr(pattern)[source]
__repr__()[source]

Return repr(self).

__str__()[source]

Return str(self).

ismatch(resource_path)[source]

Return True if this matches the given resource

__attrs_attrs__ = (Attribute(name='exporter', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='group', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='cls', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='name', default=None, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='rename', default=None, validator=None, repr=True, cmp=False, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False))
__dict__ = mappingproxy({'__module__': 'labgrid.remote.common', 'fromstr': <classmethod object>, '__repr__': <function ResourceMatch.__repr__>, '__str__': <function ResourceMatch.__str__>, 'ismatch': <function ResourceMatch.ismatch>, '__dict__': <attribute '__dict__' of 'ResourceMatch' objects>, '__weakref__': <attribute '__weakref__' of 'ResourceMatch' objects>, '__doc__': None, '__attrs_attrs__': (Attribute(name='exporter', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='group', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='cls', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='name', default=None, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='rename', default=None, validator=None, repr=True, cmp=False, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False)), '__eq__': <function ResourceMatch.__eq__>, '__ne__': <function ResourceMatch.__ne__>, '__lt__': <function ResourceMatch.__lt__>, '__le__': <function ResourceMatch.__le__>, '__gt__': <function ResourceMatch.__gt__>, '__ge__': <function ResourceMatch.__ge__>, '__hash__': None, '__init__': <function ResourceMatch.__init__>})
__eq__(other)

Return self==value.

__ge__(other)

Automatically created by attrs.

__gt__(other)

Automatically created by attrs.

__hash__ = None
__init__(exporter, group, cls, name=None, rename=None) → None

Initialize self. See help(type(self)) for accurate signature.

__le__(other)

Automatically created by attrs.

__lt__(other)

Automatically created by attrs.

__module__ = 'labgrid.remote.common'
__ne__(other)

Check equality and either forward a NotImplemented or return the result negated.

__weakref__

list of weak references to the object (if defined)

class labgrid.remote.common.Place(name, aliases=NOTHING, comment='', tags=NOTHING, matches=NOTHING, acquired=None, acquired_resources=NOTHING, allowed=NOTHING, created=NOTHING, changed=NOTHING, reservation=None)[source]

Bases: object

asdict()[source]
update(config)[source]
show(level=0)[source]
getmatch(resource_path)[source]

Return the ResourceMatch object for the given resource path or None if not found.

A resource_path has the structure (exporter, group, cls, name).

hasmatch(resource_path)[source]

Return True if this place as a ResourceMatch object for the given resource path.

A resource_path has the structure (exporter, group, cls, name).

touch()[source]
__attrs_attrs__ = (Attribute(name='name', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='aliases', default=Factory(factory=<class 'set'>, takes_self=False), validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=<class 'set'>, kw_only=False), Attribute(name='comment', default='', validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='tags', default=Factory(factory=<class 'dict'>, takes_self=False), validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='matches', default=Factory(factory=<class 'list'>, takes_self=False), validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='acquired', default=None, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='acquired_resources', default=Factory(factory=<class 'list'>, takes_self=False), validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='allowed', default=Factory(factory=<class 'set'>, takes_self=False), validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=<class 'set'>, kw_only=False), Attribute(name='created', default=Factory(factory=<built-in function time>, takes_self=False), validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='changed', default=Factory(factory=<built-in function time>, takes_self=False), validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='reservation', default=None, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False))
__dict__ = mappingproxy({'__module__': 'labgrid.remote.common', 'asdict': <function Place.asdict>, 'update': <function Place.update>, 'show': <function Place.show>, 'getmatch': <function Place.getmatch>, 'hasmatch': <function Place.hasmatch>, 'touch': <function Place.touch>, '__dict__': <attribute '__dict__' of 'Place' objects>, '__weakref__': <attribute '__weakref__' of 'Place' objects>, '__doc__': None, '__attrs_attrs__': (Attribute(name='name', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='aliases', default=Factory(factory=<class 'set'>, takes_self=False), validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=<class 'set'>, kw_only=False), Attribute(name='comment', default='', validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='tags', default=Factory(factory=<class 'dict'>, takes_self=False), validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='matches', default=Factory(factory=<class 'list'>, takes_self=False), validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='acquired', default=None, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='acquired_resources', default=Factory(factory=<class 'list'>, takes_self=False), validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='allowed', default=Factory(factory=<class 'set'>, takes_self=False), validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=<class 'set'>, kw_only=False), Attribute(name='created', default=Factory(factory=<built-in function time>, takes_self=False), validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='changed', default=Factory(factory=<built-in function time>, takes_self=False), validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='reservation', default=None, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False)), '__repr__': <function Place.__repr__>, '__init__': <function Place.__init__>})
__init__(name, aliases=NOTHING, comment='', tags=NOTHING, matches=NOTHING, acquired=None, acquired_resources=NOTHING, allowed=NOTHING, created=NOTHING, changed=NOTHING, reservation=None) → None

Initialize self. See help(type(self)) for accurate signature.

__module__ = 'labgrid.remote.common'
__repr__()

Automatically created by attrs.

__weakref__

list of weak references to the object (if defined)

class labgrid.remote.common.ReservationState[source]

Bases: enum.Enum

An enumeration.

waiting = 0
allocated = 1
acquired = 2
expired = 3
invalid = 4
__module__ = 'labgrid.remote.common'
class labgrid.remote.common.Reservation(owner, token=NOTHING, state='waiting', prio=0.0, filters=NOTHING, allocations=NOTHING, created=NOTHING, timeout=NOTHING)[source]

Bases: object

asdict()[source]
refresh(delta=60)[source]
property expired
show(level=0)[source]
__attrs_attrs__ = (Attribute(name='owner', default=NOTHING, validator=<instance_of validator for type <class 'str'>>, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='token', default=Factory(factory=<function Reservation.<lambda>>, takes_self=False), validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='state', default='waiting', validator=<instance_of validator for type <enum 'ReservationState'>>, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=<function Reservation.<lambda>>, kw_only=False), Attribute(name='prio', default=0.0, validator=<instance_of validator for type <class 'float'>>, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='filters', default=Factory(factory=<class 'dict'>, takes_self=False), validator=<instance_of validator for type <class 'dict'>>, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='allocations', default=Factory(factory=<class 'dict'>, takes_self=False), validator=<instance_of validator for type <class 'dict'>>, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='created', default=Factory(factory=<built-in function time>, takes_self=False), validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='timeout', default=Factory(factory=<function Reservation.<lambda>>, takes_self=False), validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False))
__dict__ = mappingproxy({'__module__': 'labgrid.remote.common', 'asdict': <function Reservation.asdict>, 'refresh': <function Reservation.refresh>, 'expired': <property object>, 'show': <function Reservation.show>, '__dict__': <attribute '__dict__' of 'Reservation' objects>, '__weakref__': <attribute '__weakref__' of 'Reservation' objects>, '__doc__': None, '__attrs_attrs__': (Attribute(name='owner', default=NOTHING, validator=<instance_of validator for type <class 'str'>>, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='token', default=Factory(factory=<function Reservation.<lambda>>, takes_self=False), validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='state', default='waiting', validator=<instance_of validator for type <enum 'ReservationState'>>, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=<function Reservation.<lambda>>, kw_only=False), Attribute(name='prio', default=0.0, validator=<instance_of validator for type <class 'float'>>, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='filters', default=Factory(factory=<class 'dict'>, takes_self=False), validator=<instance_of validator for type <class 'dict'>>, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='allocations', default=Factory(factory=<class 'dict'>, takes_self=False), validator=<instance_of validator for type <class 'dict'>>, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='created', default=Factory(factory=<built-in function time>, takes_self=False), validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='timeout', default=Factory(factory=<function Reservation.<lambda>>, takes_self=False), validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False)), '__repr__': <function Reservation.__repr__>, '__init__': <function Reservation.__init__>})
__init__(owner, token=NOTHING, state='waiting', prio=0.0, filters=NOTHING, allocations=NOTHING, created=NOTHING, timeout=NOTHING) → None

Initialize self. See help(type(self)) for accurate signature.

__module__ = 'labgrid.remote.common'
__repr__()

Automatically created by attrs.

__weakref__

list of weak references to the object (if defined)

labgrid.remote.common.enable_tcp_nodelay(session)[source]

asyncio/autobahn does not set TCP_NODELAY by default, so we need to do it like this for now.

labgrid.remote.config module

class labgrid.remote.config.ResourceConfig(filename)[source]

Bases: object

__attrs_post_init__()[source]
__attrs_attrs__ = (Attribute(name='filename', default=NOTHING, validator=<instance_of validator for type <class 'str'>>, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False),)
__dict__ = mappingproxy({'__module__': 'labgrid.remote.config', '__attrs_post_init__': <function ResourceConfig.__attrs_post_init__>, '__dict__': <attribute '__dict__' of 'ResourceConfig' objects>, '__weakref__': <attribute '__weakref__' of 'ResourceConfig' objects>, '__doc__': None, '__attrs_attrs__': (Attribute(name='filename', default=NOTHING, validator=<instance_of validator for type <class 'str'>>, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False),), '__repr__': <function ResourceConfig.__repr__>, '__init__': <function ResourceConfig.__init__>})
__init__(filename) → None

Initialize self. See help(type(self)) for accurate signature.

__module__ = 'labgrid.remote.config'
__repr__()

Automatically created by attrs.

__weakref__

list of weak references to the object (if defined)

labgrid.remote.coordinator module

The coordinator module coordinates exported resources and clients accessing them.

class labgrid.remote.coordinator.Action[source]

Bases: enum.Enum

An enumeration.

ADD = 0
DEL = 1
UPD = 2
__module__ = 'labgrid.remote.coordinator'
class labgrid.remote.coordinator.RemoteSession[source]

Bases: object

class encapsulating a session, used by ExporterSession and ClientSession

property key

Key of the session

property name

Name of the session

__attrs_attrs__ = (Attribute(name='coordinator', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='session', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='authid', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='version', default='unknown', validator=None, repr=True, cmp=True, hash=None, init=False, metadata=mappingproxy({}), type=None, converter=None, kw_only=False))
__dict__ = mappingproxy({'__module__': 'labgrid.remote.coordinator', '__doc__': 'class encapsulating a session, used by ExporterSession and ClientSession', 'key': <property object>, 'name': <property object>, '__dict__': <attribute '__dict__' of 'RemoteSession' objects>, '__weakref__': <attribute '__weakref__' of 'RemoteSession' objects>, '__attrs_attrs__': (Attribute(name='coordinator', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='session', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='authid', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='version', default='unknown', validator=None, repr=True, cmp=True, hash=None, init=False, metadata=mappingproxy({}), type=None, converter=None, kw_only=False)), '__repr__': <function RemoteSession.__repr__>})
__module__ = 'labgrid.remote.coordinator'
__repr__()

Automatically created by attrs.

__weakref__

list of weak references to the object (if defined)

class labgrid.remote.coordinator.ExporterSession(coordinator, session, authid)[source]

Bases: labgrid.remote.coordinator.RemoteSession

An ExporterSession is opened for each Exporter connecting to the coordinator, allowing the Exporter to get and set resources

set_resource(groupname, resourcename, resourcedata)[source]
get_resources()[source]

Method invoked by the client, get the resources from the coordinator

__attrs_attrs__ = (Attribute(name='coordinator', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='session', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='authid', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='version', default='unknown', validator=None, repr=True, cmp=True, hash=None, init=False, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='groups', default=Factory(factory=<class 'dict'>, takes_self=False), validator=None, repr=True, cmp=True, hash=None, init=False, metadata=mappingproxy({}), type=None, converter=None, kw_only=False))
__init__(coordinator, session, authid) → None

Initialize self. See help(type(self)) for accurate signature.

__module__ = 'labgrid.remote.coordinator'
__repr__()

Automatically created by attrs.

class labgrid.remote.coordinator.ClientSession(coordinator, session, authid)[source]

Bases: labgrid.remote.coordinator.RemoteSession

__attrs_attrs__ = (Attribute(name='coordinator', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='session', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='authid', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='version', default='unknown', validator=None, repr=True, cmp=True, hash=None, init=False, metadata=mappingproxy({}), type=None, converter=None, kw_only=False))
__init__(coordinator, session, authid) → None

Initialize self. See help(type(self)) for accurate signature.

__module__ = 'labgrid.remote.coordinator'
__repr__()

Automatically created by attrs.

class labgrid.remote.coordinator.ResourceImport(data, *, path)[source]

Bases: labgrid.remote.common.ResourceEntry

Represents a local resource exported from an exporter.

The ResourceEntry attributes contain the information for the client.

__attrs_attrs__ = (Attribute(name='data', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='path', default=NOTHING, validator=<instance_of validator for type <class 'tuple'>>, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=True))
__init__(data, *, path) → None

Initialize self. See help(type(self)) for accurate signature.

__module__ = 'labgrid.remote.coordinator'
__repr__()

Automatically created by attrs.

labgrid.remote.coordinator.locked(func)[source]

labgrid.remote.exporter module

The remote.exporter module exports resources to the coordinator and makes them available to other clients on the same coordinator

class labgrid.remote.exporter.ResourceExport(data, host='build-9688300-project-82349-labgrid', proxy=None, proxy_required=False)[source]

Bases: labgrid.remote.common.ResourceEntry

Represents a local resource exported via a specific protocol.

The ResourceEntry attributes contain the information for the client.

__attrs_post_init__()[source]
start()[source]
stop()[source]
poll()[source]
acquire(*args, **kwargs)[source]
release(*args, **kwargs)[source]
__attrs_attrs__ = (Attribute(name='data', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='host', default='build-9688300-project-82349-labgrid', validator=<instance_of validator for type <class 'str'>>, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='proxy', default=None, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='proxy_required', default=False, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='local', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=False, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='local_params', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=False, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='start_params', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=False, metadata=mappingproxy({}), type=None, converter=None, kw_only=False))
__init__(data, host='build-9688300-project-82349-labgrid', proxy=None, proxy_required=False) → None

Initialize self. See help(type(self)) for accurate signature.

__module__ = 'labgrid.remote.exporter'
__repr__()

Automatically created by attrs.

class labgrid.remote.exporter.USBSerialPortExport(data, host='build-9688300-project-82349-labgrid', proxy=None, proxy_required=False)[source]

Bases: labgrid.remote.exporter.ResourceExport

ResourceExport for a USB SerialPort

__attrs_post_init__()[source]
__del__()[source]
__attrs_attrs__ = (Attribute(name='data', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='host', default='build-9688300-project-82349-labgrid', validator=<instance_of validator for type <class 'str'>>, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='proxy', default=None, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='proxy_required', default=False, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='local', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=False, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='local_params', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=False, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='start_params', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=False, metadata=mappingproxy({}), type=None, converter=None, kw_only=False))
__init__(data, host='build-9688300-project-82349-labgrid', proxy=None, proxy_required=False) → None

Initialize self. See help(type(self)) for accurate signature.

__module__ = 'labgrid.remote.exporter'
__repr__()

Automatically created by attrs.

class labgrid.remote.exporter.USBEthernetExport(data, host='build-9688300-project-82349-labgrid', proxy=None, proxy_required=False)[source]

Bases: labgrid.remote.exporter.ResourceExport

ResourceExport for a USB ethernet interface

__attrs_post_init__()[source]
__attrs_attrs__ = (Attribute(name='data', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='host', default='build-9688300-project-82349-labgrid', validator=<instance_of validator for type <class 'str'>>, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='proxy', default=None, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='proxy_required', default=False, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='local', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=False, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='local_params', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=False, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='start_params', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=False, metadata=mappingproxy({}), type=None, converter=None, kw_only=False))
__init__(data, host='build-9688300-project-82349-labgrid', proxy=None, proxy_required=False) → None

Initialize self. See help(type(self)) for accurate signature.

__module__ = 'labgrid.remote.exporter'
__repr__()

Automatically created by attrs.

class labgrid.remote.exporter.USBGenericExport(data, host='build-9688300-project-82349-labgrid', proxy=None, proxy_required=False)[source]

Bases: labgrid.remote.exporter.ResourceExport

ResourceExport for USB devices accessed directly from userspace

__attrs_post_init__()[source]
__attrs_attrs__ = (Attribute(name='data', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='host', default='build-9688300-project-82349-labgrid', validator=<instance_of validator for type <class 'str'>>, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='proxy', default=None, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='proxy_required', default=False, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='local', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=False, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='local_params', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=False, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='start_params', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=False, metadata=mappingproxy({}), type=None, converter=None, kw_only=False))
__init__(data, host='build-9688300-project-82349-labgrid', proxy=None, proxy_required=False) → None

Initialize self. See help(type(self)) for accurate signature.

__module__ = 'labgrid.remote.exporter'
__repr__()

Automatically created by attrs.

class labgrid.remote.exporter.USBSigrokExport(data, host='build-9688300-project-82349-labgrid', proxy=None, proxy_required=False)[source]

Bases: labgrid.remote.exporter.USBGenericExport

ResourceExport for USB devices accessed directly from userspace

__attrs_post_init__()[source]
__attrs_attrs__ = (Attribute(name='data', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='host', default='build-9688300-project-82349-labgrid', validator=<instance_of validator for type <class 'str'>>, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='proxy', default=None, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='proxy_required', default=False, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='local', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=False, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='local_params', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=False, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='start_params', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=False, metadata=mappingproxy({}), type=None, converter=None, kw_only=False))
__init__(data, host='build-9688300-project-82349-labgrid', proxy=None, proxy_required=False) → None

Initialize self. See help(type(self)) for accurate signature.

__module__ = 'labgrid.remote.exporter'
__repr__()

Automatically created by attrs.

class labgrid.remote.exporter.USBSDMuxExport(data, host='build-9688300-project-82349-labgrid', proxy=None, proxy_required=False)[source]

Bases: labgrid.remote.exporter.USBGenericExport

ResourceExport for USB devices accessed directly from userspace

__attrs_post_init__()[source]
__attrs_attrs__ = (Attribute(name='data', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='host', default='build-9688300-project-82349-labgrid', validator=<instance_of validator for type <class 'str'>>, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='proxy', default=None, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='proxy_required', default=False, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='local', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=False, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='local_params', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=False, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='start_params', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=False, metadata=mappingproxy({}), type=None, converter=None, kw_only=False))
__init__(data, host='build-9688300-project-82349-labgrid', proxy=None, proxy_required=False) → None

Initialize self. See help(type(self)) for accurate signature.

__module__ = 'labgrid.remote.exporter'
__repr__()

Automatically created by attrs.

class labgrid.remote.exporter.USBPowerPortExport(data, host='build-9688300-project-82349-labgrid', proxy=None, proxy_required=False)[source]

Bases: labgrid.remote.exporter.USBGenericExport

ResourceExport for ports on switchable USB hubs

__attrs_post_init__()[source]
__attrs_attrs__ = (Attribute(name='data', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='host', default='build-9688300-project-82349-labgrid', validator=<instance_of validator for type <class 'str'>>, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='proxy', default=None, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='proxy_required', default=False, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='local', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=False, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='local_params', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=False, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='start_params', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=False, metadata=mappingproxy({}), type=None, converter=None, kw_only=False))
__init__(data, host='build-9688300-project-82349-labgrid', proxy=None, proxy_required=False) → None

Initialize self. See help(type(self)) for accurate signature.

__module__ = 'labgrid.remote.exporter'
__repr__()

Automatically created by attrs.

class labgrid.remote.exporter.USBDeditecRelaisExport(data, host='build-9688300-project-82349-labgrid', proxy=None, proxy_required=False)[source]

Bases: labgrid.remote.exporter.USBGenericExport

ResourceExport for outputs on deditec relais

__attrs_post_init__()[source]
__attrs_attrs__ = (Attribute(name='data', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='host', default='build-9688300-project-82349-labgrid', validator=<instance_of validator for type <class 'str'>>, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='proxy', default=None, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='proxy_required', default=False, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='local', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=False, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='local_params', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=False, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='start_params', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=False, metadata=mappingproxy({}), type=None, converter=None, kw_only=False))
__init__(data, host='build-9688300-project-82349-labgrid', proxy=None, proxy_required=False) → None

Initialize self. See help(type(self)) for accurate signature.

__module__ = 'labgrid.remote.exporter'
__repr__()

Automatically created by attrs.

class labgrid.remote.exporter.EthernetPortExport(data, host='build-9688300-project-82349-labgrid', proxy=None, proxy_required=False)[source]

Bases: labgrid.remote.exporter.ResourceExport

ResourceExport for a ethernet interface

__attrs_post_init__()[source]
__attrs_attrs__ = (Attribute(name='data', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='host', default='build-9688300-project-82349-labgrid', validator=<instance_of validator for type <class 'str'>>, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='proxy', default=None, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='proxy_required', default=False, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='local', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=False, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='local_params', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=False, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='start_params', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=False, metadata=mappingproxy({}), type=None, converter=None, kw_only=False))
__eq__(other)

Return self==value.

__ge__(other)

Automatically created by attrs.

__gt__(other)

Automatically created by attrs.

__hash__ = None
__init__(data, host='build-9688300-project-82349-labgrid', proxy=None, proxy_required=False) → None

Initialize self. See help(type(self)) for accurate signature.

__le__(other)

Automatically created by attrs.

__lt__(other)

Automatically created by attrs.

__module__ = 'labgrid.remote.exporter'
__ne__(other)

Check equality and either forward a NotImplemented or return the result negated.

__repr__()

Automatically created by attrs.

class labgrid.remote.exporter.GPIOGenericExport(data, host='build-9688300-project-82349-labgrid', proxy=None, proxy_required=False)[source]

Bases: labgrid.remote.exporter.ResourceExport

ResourceExport for GPIO lines accessed directly from userspace

__attrs_post_init__()[source]
__attrs_attrs__ = (Attribute(name='data', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='host', default='build-9688300-project-82349-labgrid', validator=<instance_of validator for type <class 'str'>>, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='proxy', default=None, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='proxy_required', default=False, validator=None, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='local', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=False, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='local_params', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=False, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='start_params', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=False, metadata=mappingproxy({}), type=None, converter=None, kw_only=False))
__init__(data, host='build-9688300-project-82349-labgrid', proxy=None, proxy_required=False) → None

Initialize self. See help(type(self)) for accurate signature.

__module__ = 'labgrid.remote.exporter'
__repr__()

Automatically created by attrs.

labgrid.remote.exporter.main()[source]

labgrid.remote.scheduler module

class labgrid.remote.scheduler.TagSet(name, tags)[source]

Bases: object

__attrs_attrs__ = (Attribute(name='name', default=NOTHING, validator=<instance_of validator for type <class 'str'>>, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='tags', default=NOTHING, validator=<instance_of validator for type <class 'set'>>, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False))
__dict__ = mappingproxy({'__module__': 'labgrid.remote.scheduler', '__dict__': <attribute '__dict__' of 'TagSet' objects>, '__weakref__': <attribute '__weakref__' of 'TagSet' objects>, '__doc__': None, '__attrs_attrs__': (Attribute(name='name', default=NOTHING, validator=<instance_of validator for type <class 'str'>>, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False), Attribute(name='tags', default=NOTHING, validator=<instance_of validator for type <class 'set'>>, repr=True, cmp=True, hash=None, init=True, metadata=mappingproxy({}), type=None, converter=None, kw_only=False)), '__repr__': <function TagSet.__repr__>, '__init__': <function TagSet.__init__>})
__init__(name, tags) → None

Initialize self. See help(type(self)) for accurate signature.

__module__ = 'labgrid.remote.scheduler'
__repr__()

Automatically created by attrs.

__weakref__

list of weak references to the object (if defined)

labgrid.remote.scheduler.schedule_step(places, filters)[source]

Find the filters that can be directly allocated without overlap.

labgrid.remote.scheduler.schedule_overlaps(places, filters)[source]

Iterate schedule_step until no more allocations are found.

labgrid.remote.scheduler.schedule(places, filters)[source]