DD-DeCaF / simulations

Model service which takes care of adjusting model according to incoming messages and returns information such as fluxes, theoretical maximum yields, etc
Apache License 2.0
0 stars 1 forks source link

Consistent ws message format #90

Closed matyasfodor closed 6 years ago

matyasfodor commented 6 years ago

In case of the ws message I'd rather have a consistent JSON structure, or even better I'd handle it a forgiving way. Here I think the best would be to go like this:

objectiveReactionId = message.get(constants.OBJECTIVE)
if objectiveReactionId is not None:
    self.model.objective = self.model.reactions.get_by_id(objectiveReactionId)

It keeps the ws hanging at the moment.

kvikshaug commented 6 years ago

Closing as this is resolved in the caffeine branch