Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Remove workaround for MiniMQTT (Issue #25) #14

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

Merged
merged 4 commits into from
May 22, 2020

Conversation

brentru
Copy link
Member

@brentru brentru commented May 19, 2020

Removes library workaround patched in adafruit/Adafruit_CircuitPython_MiniMQTT#33 in favor of using hostname without https: appended to the broker string

@brentru brentru requested a review from a team May 19, 2020 19:30
@brentru
Copy link
Member Author

brentru commented May 19, 2020

@jimbobbennett I can't tag you as a reviewer. However, could you please review this? Thanks!

@tannewt
Copy link
Member

tannewt commented May 20, 2020

I invited @jimbobbennett to collaborate on the repo so they can review officially and merge.

@brentru
Copy link
Member Author

brentru commented May 20, 2020

Thanks, Scott!

@@ -91,7 +91,7 @@ def device_twin_desired_updated(self, desired_property_name: str, desired_proper
:param int desired_version: The version of the desired property that was updated
"""

def device_twin_reported_updated(self, reported_property_name: str, reported_property_value, reported_version: int) -> None:
def device_twin_reported_updated(self, reported_property_name: str, reported_property_value, reported_version: int,) -> None:
Copy link
Collaborator

Choose a reason for hiding this comment

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

Does this extra comma do anything?

Copy link
Member Author

Choose a reason for hiding this comment

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

@jimbobbennett Hrm, I didn't add them. These may have been added by black'ing the file.

@jimbobbennett
Copy link
Collaborator

Noticed a few extra commas - not sure if they are needed. I'll do a full check and test later this week, sorry tied up the Microsoft Build at the moment.

@brentru
Copy link
Member Author

brentru commented May 21, 2020

@jimbobbennett No rush, enjoy BUILD

@askpatrickw
Copy link
Contributor

Black will add trailing commas to expressions that are split by comma where each element is on its own line. This includes function signatures.

https://black.readthedocs.io/en/stable/the_black_code_style.html#trailing-commas

@jimbobbennett
Copy link
Collaborator

@brentru - I've updated the PR with a couple of changes:

  • Removed the rogue commas to make it easier to see the changes
  • Removed the _try_create_mqtt_client method and moved the code into the _create_mqtt_client method to avoid having a method that does nothing except call another method
  • Removed a comment referencing the bug in miniMQTT

I've tested it on a PyPortal using a number of the examples. Can you review please?

Copy link
Member Author

@brentru brentru left a comment

Choose a reason for hiding this comment

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

@jimbobbennett This looks good to merge. I agree with relying on the generated hostname rather than passing the client creation method the hostname.

@brentru brentru merged commit 18b7c50 into adafruit:master May 22, 2020
@brentru brentru deleted the patch-mmqtt branch May 22, 2020 13:18
adafruit-adabot added a commit to adafruit/Adafruit_CircuitPython_Bundle that referenced this pull request May 23, 2020
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.

4 participants