IBM / spacetech-kubesat

IBM Space Tech - Cognitive Autonomous Framework
Apache License 2.0
83 stars 16 forks source link

fix duplicate of IP_ADDRESS_MESSAGE schema definitions #17

Closed Jordy24 closed 3 years ago

Jordy24 commented 3 years ago

This PR addresses issue #8 Removed duplication of IP_ADDRESS_MESSAGE in validation.py

Signed-off-by: Jordan Karaze jordan.karaze@ibm.com

minsikl commented 3 years ago

The two IP_ADDRESS_MESSAGE schemas have different data structures. How did you find the unused one? Do we need only one of them? Which services are using the IP_ADDRESS_MESSAGE? How did you test it?

Jordy24 commented 3 years ago

For that I basically followed the convention of the schemas, which basically have these attributes ["sender_ID", "time_sent", "data", "origin_ID", "message_type"] whenever creating a new message. You can view that in the "create_message()" function in /util/kubesat/nats_handler.py

minsikl commented 3 years ago
  1. Did you check which code use that IP_ADDRESS_MESSAGE? It's not nats_handler.py.
  2. Did you test if the simulation works with your code?
Jordy24 commented 3 years ago

And in the nats_handler.py if you take a look at the "create_message" function it has a very specific way of build messages.

The simulation works fine after that is removed ..I did test it out

minsikl commented 3 years ago

Cancel this PR and open a new PR with IP_ADDRESS_MESSAGE code only