Skip to content

fix wrong string compare on python device repr - #14417

Merged
Nir-Az merged 1 commit into
realsenseai:developmentfrom
Nir-Az:fix-usb-desc
Nov 9, 2025
Merged

Nir-Az merged 1 commit into
realsenseai:developmentfrom
Nir-Az:fix-usb-desc

Conversation

@Nir-Az

@Nir-Az Nir-Az commented Nov 6, 2025 •

Copy link
Copy Markdown
Collaborator

Wrong string comparation cause the condition to fail.
We compared char * to "USB" and not used proper string comparation

Before:

>>> dev
<pyrealsense2.device: D455 (S/N: 114222251272  FW: 5.17.0.10  UNLOCKED  on USB)>

After:

>>> dev
<pyrealsense2.device: D455 (S/N: 114222251272  FW: 5.17.0.10  UNLOCKED  on USB3.2)>

@Nir-Az
Nir-Az requested a review from AviaAv November 6, 2025 10:16

@AviaAv AviaAv left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Looks great!

@Nir-Az
Nir-Az force-pushed the fix-usb-desc branch 7 times, most recently from c2b358f to 2c0cedb Compare November 6, 2025 12:44
Comment thread .github/workflows/clang-tidy.yml Outdated
run: |
echo "Running clang-tidy..."
cp build/compile_commands.json .
clang-tidy -p . $(find src -name '*.cpp') 2>&1 | tee clang-tidy.log

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Is this expected to catch char* to char* comparisons instead of strings?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

WIP, will update when done
If not it will be excluded from this PR

@Nir-Az
Nir-Az force-pushed the fix-usb-desc branch 9 times, most recently from d68ee31 to fcdbe1f Compare November 9, 2025 10:04
@Nir-Az
Nir-Az merged commit 93c0b38 into realsenseai:development Nov 9, 2025
51 checks passed
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