Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[MIR] Connection check for InOrbit MQTT #22

Merged
merged 1 commit into from
Jun 2, 2024
Merged

Conversation

russell-inorbit
Copy link
Contributor

☑️ Your checklist for this pull request

🚨 Please review the guidelines for contributing to this repository.

  • Make sure you are requesting to pull a topic/feature/bugfix branch (right side). Don't request your main!
  • Make sure you are making a pull request against the main branch (left side). Also you should start your branch off our main.
  • Check if your code additions will fail code linting checks.

🗒️ Description

This MR adds a connection check to the MQTT session within InOrbit.

cc: @anvitaupadhyay8

@russell-inorbit russell-inorbit requested a review from b-Tomas May 28, 2024 22:19
@russell-inorbit russell-inorbit self-assigned this May 28, 2024
Copy link
Member

@b-Tomas b-Tomas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!
Would you rebase the changes in order to lose the extra commit?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like you might've branched from the changed for the previous MR

@@ -279,6 +279,10 @@ def start(self):
except Exception:
self.logger.exception("Error reporting mission")

def inorbit_connected(self):
"""Check if the InOrbit MQTT session is connected."""
return self.inorbit_sess.client.is_connected()
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not a fan of accessing RobotSession.client externally but can't think of another way. To keep in mind for future development of InOrbit Edge.

@russell-inorbit russell-inorbit merged commit 4e794d8 into main Jun 2, 2024
10 checks passed
@russell-inorbit russell-inorbit deleted the connection-check branch June 2, 2024 21:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants