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

Skip to content

Conversation

@Lauszus
Copy link
Owner

@Lauszus Lauszus commented Sep 21, 2025

There is no reason to convert it from a tuple to a list and then unpack it

There is no reason to convert it from a tuple to a list and then unpack it
@Lauszus Lauszus added this to the 1.7.0 milestone Sep 21, 2025
@Lauszus Lauszus requested a review from Copilot September 21, 2025 21:54
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR simplifies payload unpacking by removing unnecessary list conversions when unpacking struct.pack() results. The change eliminates redundant tuple-to-list conversions before unpacking with the * operator.

  • Removes unnecessary list() calls around struct.pack() results before unpacking
  • Directly unpacks tuples returned by struct.pack() using the * operator

@github-actions
Copy link

Coverage report

Click to see where and how coverage changed

FileStatementsMissingCoverageCoverage
(new stmts)
Lines missing
  src/pyblhost
  pyblhost.py 438, 441, 491, 494, 501
Project Total  

This report was generated by python-coverage-comment-action

@Lauszus Lauszus marked this pull request as ready for review September 21, 2025 21:55
@Lauszus Lauszus merged commit 49c0cd1 into main Sep 21, 2025
3 checks passed
@Lauszus Lauszus deleted the feature/simplify_unpacking branch September 21, 2025 21:55
@Lauszus Lauszus modified the milestones: 1.7.0, 1.7.1 Sep 21, 2025
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