various small fixes
- fix some earlyInit and initModules methods - remove some comments - change name of Done unique value to 'Done', this seems more useful for __repr__ and debug logging Change-Id: I73f0e09bfef858ddca11bba0e92e941ebc151160 Reviewed-on: https://forge.frm2.tum.de/review/c/sine2020/secop/playground/+/27907 Tested-by: Jenkins Automated Tests <pedersen+jenkins@frm2.tum.de> Reviewed-by: Enrico Faulhaber <enrico.faulhaber@frm2.tum.de> Reviewed-by: Markus Zolliker <markus.zolliker@psi.ch>
This commit is contained in:
@@ -879,6 +879,8 @@ class StructOf(DataType):
|
||||
:param optional: a list of optional members
|
||||
:param members: names as keys and types as values for all members
|
||||
"""
|
||||
# Remark: assignment of parameters containing partial structs in their datatype
|
||||
# are (and can) not be handled here! This has to be done manually in the write method
|
||||
def __init__(self, optional=None, **members):
|
||||
super().__init__()
|
||||
self.members = members
|
||||
|
||||
@@ -253,6 +253,7 @@ class StringIO(IOBase):
|
||||
if not self.is_connected:
|
||||
self.read_is_connected() # try to reconnect
|
||||
if not self._conn:
|
||||
self.log.debug('can not connect to %r' % self.uri)
|
||||
raise CommunicationSilentError('can not connect to %r' % self.uri)
|
||||
try:
|
||||
with self._lock:
|
||||
@@ -410,7 +411,7 @@ class BytesIO(IOBase):
|
||||
:return: the full reply (replyheader + additional bytes)
|
||||
|
||||
When the reply length is variable, :meth:`communicate` should be called
|
||||
with the `replylen` argument set to minimum expected length of the reply.
|
||||
with the `replylen` argument set to the minimum expected length of the reply.
|
||||
Typically this method determines then the length of additional bytes from
|
||||
the already received bytes (replyheader) and/or the request and calls
|
||||
:meth:`readBytes` to get the remaining bytes.
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
#!/usr/bin/env python
|
||||
# -*- coding: utf-8 -*-
|
||||
# *****************************************************************************
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify it under
|
||||
# the terms of the GNU General Public License as published by the Free Software
|
||||
# Foundation; either version 2 of the License, or (at your option) any later
|
||||
@@ -17,6 +18,7 @@
|
||||
#
|
||||
# Module authors:
|
||||
# Markus Zolliker <markus.zolliker@psi.ch>
|
||||
#
|
||||
# *****************************************************************************
|
||||
|
||||
|
||||
|
||||
@@ -41,7 +41,7 @@ from secop.logging import RemoteLogHandler, HasComlog
|
||||
|
||||
generalConfig.defaults['disable_value_range_check'] = False # check for problematic value range by default
|
||||
|
||||
Done = UniqueObject('already set')
|
||||
Done = UniqueObject('Done')
|
||||
"""a special return value for a read/write function
|
||||
|
||||
indicating that the setter is triggered already"""
|
||||
|
||||
Reference in New Issue
Block a user