Skip to content
This repository has been archived by the owner on Jul 6, 2020. It is now read-only.

Commit

Permalink
[RUNTIME] Fix State Manager data race related to RFID (#590)
Browse files Browse the repository at this point in the history
For some reason, State Manager sends data directly to student code by
default, which can cause data races depending on the state of the
student code process. This PR unsets that flag when sending RFID codes
to State Manager.
  • Loading branch information
baby-bell authored Apr 29, 2018
1 parent e8e0429 commit 33974c0
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions runtime/Ansible.py
Original file line number Diff line number Diff line change
Expand Up @@ -489,11 +489,11 @@ def unpackage(data):
if unpackaged_data.header == notification_pb2.Notification.GAMECODE_TRANSMISSION:
state_queue.put([SM_COMMANDS.SET_VAL,
[list(unpackaged_data.gamecode_solutions),
["gamecodes_check"]]])
["gamecodes_check"], False]])
state_queue.put([SM_COMMANDS.SET_VAL,
[list(unpackaged_data.gamecodes), ["gamecodes"]]])
[list(unpackaged_data.gamecodes), ["gamecodes"], False]])
state_queue.put([SM_COMMANDS.SET_VAL,
[list(unpackaged_data.rfids), ["rfids"]]])
[list(unpackaged_data.rfids), ["rfids"], False]])

except ConnectionResetError:
bad_things_queue.put(
Expand Down
2 changes: 1 addition & 1 deletion runtime/runtimeUtil.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ class RUNTIME_CONFIG(Enum):
TEST_OUTPUT_DIR = "test_outputs/"
VERSION_MAJOR = 18
VERSION_MINOR = 2
VERSION_PATCH = 7
VERSION_PATCH = 8

@unique
class BAD_EVENTS(Enum):
Expand Down

0 comments on commit 33974c0

Please sign in to comment.