Skip to content

Test for stale observations due to observation_handshake #28

Description

@rallen10

I am concerned that the current logic for ksp_interface_loop.observation_handshake used between ksp_interface_loop and AgentEnvRunner.policy_loop may cause old/stale observations to be processed by AgentEnvRunner.policy_loop.

In particular, see how AgentEnvRunner.policy_loop receives messages from the observation_handshake (in v0.11.1): https://github.com/mit-ll/spacegym-kspdg/blob/v0.11.1/src/kspdg/agent_api/runner.py#L125

If there are multiple messages in this pipe, wouldn't this if statement get the oldest one? Shouldn't it use something like a while statement to make sure it's clearing the pipe and processing the newest observation?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions