eclipse-ecal / ecal

📦 eCAL - enhanced Communication Abstraction Layer. A high performance publish-subscribe, client-server cross-plattform middleware.
https://ecal.io
Apache License 2.0
847 stars 178 forks source link

UserWarning: MessageFactory class is deprecated #1583

Open salsabeel-imagry opened 6 months ago

salsabeel-imagry commented 6 months ago

Problem Description

Hi,

Seems that the "MessageFactory" class is deprecated, and I got the following warning when reading channel data

/usr/local/lib/python3.8/dist-packages/ecal/proto/helper.py:72: UserWarning: MessageFactory class is deprecated. Please use GetMessageClass() instead of MessageFactory.GetPrototype. MessageFactory class will be removed after 2024. return google.protobuf.message_factory.MessageFactory(desc_pool).GetPrototype(desc)

How to reproduce

Here is a sample code for reproduction:

import ecal
from ecal.measurement.measurement import Measurement

measurement = Measurement("/path/to/measurement/file.hdf5")
channel =  measurement[measurement.channel_names[0]]
# or
channel = measurement['myChannelName'] 

reproduction

How did you get eCAL?

Ubuntu PPA (apt-get)

Environment

eCAL System Information

------------------------- SYSTEM ---------------------------------
Version                  : v5.13.0 (2024-04-24 14:44:35 +0200)
Platform                 : linux

------------------------- CONFIGURATION --------------------------
Default INI              : /etc/ecal/ecal.ini

------------------------- NETWORK --------------------------------
Host name                : _
Host group name          : _
Network mode             : local
Network ttl              : 1
Network sndbuf           : 5 MByte
Network rcvbuf           : 5 MByte
Multicast cfg version    : v1
Multicast group          : 239.0.0.1
Multicast mask           : 0.0.0.15
Multicast ports          : 14000 - 14010
Multicast join all IFs   : off
Bandwidth limit (udp)    : not limited

------------------------- TIME -----------------------------------
Synchronization realtime : "ecaltime-localtime"
Synchronization replay   : 
State                    :  synchronized 
Master / Slave           :  Master 
Status (Code)            : "everything is fine." (0)

------------------------- PUBLISHER LAYER DEFAULTS ---------------
Layer Mode INPROC        : off
Layer Mode SHM           : auto
Layer Mode TCP           : off
Layer Mode UDP MC        : auto

------------------------- SUBSCRIPTION LAYER DEFAULTS ------------
Layer Mode INPROC        : on
Layer Mode SHM           : on
Layer Mode TCP           : on
Layer Mode UDP MC        : on
Npcap UDP Reciever       : off

------------------------- EXPERIMENTAL ---------------------------
SHM Monitoring           : off
SHM Monitoring (Domain)  : ecal_mon
SHM Monitoring (Queue)   : 1024
Network Monitoring       : on
Drop out-of-order msgs   : off
KerstinKeller commented 6 months ago

Thanks for reporting. We are currently working on our Python bindings, and we will take a look at this issue.