All notable changes to the sdc11073 module will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
- the
http.client.NotConnectedraised bySoapClientnow carries the reason of the underlying connection/SSL error, and the consumer now logs the SSL error when it falls back from an encrypted to an unencrypted connection #427
SubscriptionEndmessages now use the full WS-Eventing status URI (e.g.http://schemas.xmlsoap.org/ws/2004/08/eventing/SourceShuttingDown) instead of the bare local name, and are sent to theEndToendpoint reference of the subscribe request. If noEndTowas provided, noSubscriptionEndmessage is sent #404- the parameter and return type in
RequestManipulatorProtocol.manipulate_stringfromstrtobytes
- Deprecation info to the
commlogmodule. - support for python 3.14 #438
- context manager support to
WSDiscovery. isoduration.XsdDatetime#446- sanity check that fully qualified hostname for the SDC Provider resolves to wsdiscovery active address
- add a flag to indicate that a state is an AlertSystemState
- MDIB lock is now an RLock - this enables locking of the mdib and prevents failures when accessing MDIB entities #481
- renamed parameter in
SdcConsumer.do_subscribefromexpire_minutestoexpire_seconds. It was already handled as seconds but was named wrong #436 - increase the default timeout for starting the HTTP server and make this timeout configurable to mitigate startup delays, issue #320
- descriptor and state containers can not be checked for equivalence (e.g., when processing description-modification reports and state-update reports) - as a result, no error is logged if a descriptor or state version is updated without any actual content change
- no implied value for the pm:CodedValue/@CodingSystem is provided (the implied value is defined differently in BICEPS IEEE 11073-10207-2017 and BICEPS IEEE 11073-10207-2017/Cor 1-2025)
- comparison of pm:CodedValue and pm:Translation instances is not provided with the sdc11073 package and will raise an exception - for further details, refer to src/sdc11073/mdib/mdibaccessor.py and tutorial/codedvaluecomparator.py in the project’s source code
- implementation of SDC Provider Roles is not part of the sdc11073 package - example implementations can be found in the tutorial folder of the project’s source code
- several API changes were introduced, including the renaming and relocation of classes and methods (e.g., the SdcConsumer and SDCProvider interfaces, SdcProviderComponents and SdcConsumerComponents interfaces)
PatientDemographicsCoreData.DateOfBirthnow requiresisoduration.XsdDatetimeas type #446- wsdiscovery method
get_active_addressesto propertyactive_address - command line parameter changed from --adapter to --ip for both provider and consumer
- SDC Consumer parameter renamed from
device_locationtoprovider_addressto better reflect the expected value - DiscoProxyClient parameter renamed from
my_addresstohost_addressto better reflect the expected value - change interface of ExecuteResult used as return value for SDC Provider operation implementation
- when generating dpws:Scope entries based on pm:AbstractComplexDeviceComponentDescriptor/pm:Type the implied value for a pm:Type/@CodingSystem is not set explicitly anymore, in addition the used values are now %-encoded before usage
- fixed schema validation error when using lxml>=6.0.0 #432
sourceindex #444- fix type annotation of EnumStringMetricDescriptor/AllowedValue/Identification
- parsing of duration and datetimes #446
- deadlock during initialization of mdib due to a wrong registered method #452
- remove dns resolution to prevent http server start issues #320
- when a consumer subscribed without an
EndToand the provider tries to send an unsubscribe this would result in anAttributeError#475 - when a consumer subscribed with an
EndTothe provider now sends theSubscriptionEndactually to the end to url instead of notify to url #475 - operation handling with regard to returned MdibVersion, SequenceId and InstanceId
isoduration.UTCclass. Usedatetime.timezone.utcinstead. #435- support for python 3.9
- MDIBs with entity handling #462
- method
network.NetworkAdapterNotFoundErrorandnetwork.get_adapter_containing_ip - method
handled_actionsof classSetService - property
actionsof classDPWSPortTypeBase - method
wait_metric_matchesof classConsumerMdibMethods
SafetyInformation.xsdas it is not used in the code
- option to configure the ttl of multicast out messages #429
- fixed an issue where the new pat mdib is not parseable because lxml QName is unpickleable
AttributeError: 'str' object has no attribute 'ContextAssociation'when running the provider from the tutorial #415- Context states list comprehension uses wrong type should be dict #426
- fixed a bug where
log_prefixcan only be a string #393
- support for python version 3.12
- new method ContextStateTransaction.disaccociate_all
- additional schemata for validation can be declared in SdcProviderComponents and SdcConsumerComponents
- new method Consumer.restart
- log a message with level INFO when a context state update is received
- allow to use full qualified name instead of IP in provider and consumer
- possible exception in ConsumerMdib._get_context_states #350
- reference tests and example provider
- node member of DescriptorContainer not updated on description modification report #357
- accessing a multikey may lead to IndexError #359
- wrong data type for ClinicalInfo.RelatedMeasurement#362
- fixed a bug where sending and receiving socket are used after they have been closed already #328
- reduced the amount of udp sockets to 2 #328
- fixed
address already in usebug #328 - fixed SetServiceClient.set_numeric_value not accepting float, int or string.
- fixed a bug where a message would be thrown away, if the udp binding of the discovery would be used by provider and consumer, as they would share the same ip and port #367
- Exception in wsdiscovery if no Scopes in message #356
- fixed error message not set in OperationInvokedReport#375.
- incorrect BindingMdibVersion and UnbindingMdibVersion #168
- ensure_location_context_descriptor and ensure_patient_context_descriptor also work for multiple system contexts in mdib.
- provider mdib observables are updated #365
- fixed possible error if _ThreadingHTTPServer fails to start and in server_close self.dispatcher member does not exist
- ContainerBase.diff uses math.isclose for comparison, test added
- removed the
MULTICAST_OUTlogger from commlog #328 - SetContextState operation sets ContextAssociation according to value in proposed context state. Before the proposed state was always associated. Check added in SetContextState that max. one proposed state per descriptor is associated.
- refactored ClientMdib.reload_all and processing of notifications
- inconsistent InstanceId attributes in GetMdibResponse
RuntimeError: dictionary changed size during iterationforremote_servicesin the discovery #335- DescriptorTransaction sometimes causes wrong DescriptorVersion in states #340
- fixed a bug where sending and receiving socket are used after they have been closed already #328
- fixed a bug where
getsockname()is called before the socket is binded - fixed cyclic import #333
- fixed a bug where comparing
ExtensionLocalValuewould fail when using the!=operator #305 - fixed wrong typing info in LocalizedText
- added a safety sleep in consumer when starting http server
- fixed possible caching errors in AlarmProvider and AudioPauseProvider
- new interface for transactions: split transaction into different kinds, e.g. descriptor_transaction, metric_state_transaction, etc.
SdcConsumerprovides a dictionary with the current connection status of each subscription it is subscribed to #271- added
force_ssl_connectparameter to constructor of consumer.
- added a way to process operations directly (directly send 'Fin' instead of Wait, Started,...)
- added handling of SystemErrorReports.
- basic_logging_setup only handles sdc logger, no more side effect due to calling logging.basicConfig.
- fix possible invalid prefix if QName is a node text.
- fixed wrong response for SetContextState message. #287
- fixed connection problem when provider closes socket after first request. #289
- change default in ContainerBase.mk_copy to not copy node due to performance problems. #294
- waveform provider too slow
- create MetricValue for DistributionSampleArrayMetricState
- dropping of Bye-messages when stopping wsdiscovery
- change python classes of
addressing_types.pyto match ws-addressing standard of 2006 instead of 2004 - The final OperationInvokedReport has OperationTargetRef parameter set. This required refactoring of Operations handling.
- moved waveform generator from mdib to roles.waveformprovider
- alert provider performs self check one second before SelfCheckInterval elapses
networkmodule to handle network adapter stuff of the host computermypystatic code analysis
- possible choosing wrong ipaddress/network interface #187
- added missing SerialNumber to ThisDeviceType
- no creation of operation target states, they should already exist or are not needed if multi state.
- transaction id is unique for provider instead only of sco.
- fixed problem that on operations without handler the transaction id always was 0.
- consumer: renew could be sent after unsubscribe
- possible deadlock when stopping provider
- fixed a bug where the
SdcConsumerfailed to determine the host network adapter if the ip contained in thedevice_locationis on a different subnet - comparison of extensions would fail #238
- ExtensionLocalValue.value must be a list instead of a dictionary in order to allow multiple elements with same name.
- fixed a bug where namespaces of xml are lost when coping lxml elements
- when creating a
SdcClientwith adevice_locationorWsDiscoverycontaining an ip where no suitable host network adapter could be determined from, anNetworkAdapterNotFoundErroris raised - removed
netconnmodule - renamed Device with Provider in order to be more compliant with sdc11073 names: sdc11073.sdcdevice.SdcDevice becomes sdc11073.provider.SdcProvider, sdc11073.mdib.devicemdib.DeviceMdibContainer becomes sdc11073.mdib.providermdib.ProviderMdib, etc.
- renamed Client with Consumer: sdc11073.sdcclient.SdcClient becomes sdc11073.consumer.SdcConsumer, sdc11073.mdib.clientmdib.ClientMdibContainer becomes sdc11073.mdib.consumermdib.ConsumerMdib, etc.
- reduced max_subscription_duration of provider to 15 seconds
- renew can be performed in fixed intervals (as before) or depending on Expires time of subscription.
- SdcLocation class reworked; use 'bldng' instead of 'bld', which better matches the standard.
- Some classes renamed in pmtypes.py
- soap client does not try implicit reconnects
- replaced some of the ssl_context parameters with an ssl_context_container parameter, that can hold two ssl context objects, to be able to get rid of the deprecation warning occurring when using the same ssl context for both client and server side
- replaced AbstractDescriptorContainer.retrievability property with methods get_retrievability() and set_retrievability()
- improved error handling when reading attribute values from xml element
- fixed possible exception in calculation of waveform age
- fixed some places where default_py_value should be implied_py_value
- fixed incomplete modeling of ClinicalInfo class
- added switch to allow disabling strict checking for AppSequence.
- reworked wsdiscovery. Wsdiscovery can now only bind to a single ip address. The only available classes are "WsDiscovery" and "WsDiscoverySingleAdapter".
- fixed bug that roundtrip statistics raises an exception when no data is available.
- fixed possible exception that "_short_filter_names" does not exist
- fixed missing namespace for IsReferenceParameter attribute
- SdcClient.start_all has optional parameter "check_get_service"
- moved port type name declaration from components.py to implementation classes #176
- fixed bug in handling of soap faults (faultcodeEnum must be QNames, not strings)
- fixed bug that mk_scopes only created a scope if a location was associated.
- fixed broken fault message generation in subscriptionsmanager_base. A previously removed method of namespace helper was still used.
- fixed bug in constructor of dpws_types.ThisDeviceType. This could cause an invalid xml:lang attribute.
- fixed bug that ContainerBase.node was not set in update_from_node
- Code follows PEP8 style (mostly)
- Using dependency injection, classes are defined in sdcdevice/components.py and sdcclients/components.py. This allows users to replace components withs own ones and modify the behavior of client and device.
- All QNames of BICEPS participant model, message model and extension are predefined in pm_qnames.py, msg_qnames.py and ext_qnames.py. Users no longer need helper functions like domTag, msgTag, etc that were needed in version 1.
- A lot of internal functionality was refactoring or rewritten.
- The API for role providers changed.
- The transactions API is simplified.
- code in repo is located under a src parent folder.
- A lot of small changes and fixes, too many to list them all.
- Multiple SdcClient instances can use a shared HTTP Server.
- strict type checking for participant model data. When assigning a value, the data is checked and an exception is thrown if type is not as expected.
- Having multiple MDS in a single mdib is supported.