Open Shaulbm opened 1 month ago
unclear instructions details - "... method that get's data dictionary ..." which data? from where?
plan breakdown:
unclear instructions details - "... method that get's data dictionary ..." which data? from where?
I have an even better idea - dropping the dictionay to baseObj. you are writing an infra that will be used - the idea behind this was to write this kind of method: def sendData(channelId: str, dataObj : BaseObj) - we will use the serialize method to send a dictionary
integrate ably integration for self initiated events
There are two stages to this:
for #2:
Create a utility - a channel for data transfer to a specific ably channel. Implement a method that gets two parameters, the channel id and the data. in order to simplify the internal usage, the data will be a child class of BaseObj
As all pydantic classes support a native conversion to JSON, it should be easy to convert the given data to JSON and send it to the channel. edit: as BaseObj supports toJSON just use it - even simpler.
for the actual method expected def sendData(channelId: str, data:BaseObj)