Skip to content

Switch to get for Dict lookup to prevent KeyError (backport #3043)#3193

Merged
sea-bass merged 1 commit intohumblefrom
mergify/bp/humble/pr-3043
Jan 4, 2025
Merged

Switch to get for Dict lookup to prevent KeyError (backport #3043)#3193
sea-bass merged 1 commit intohumblefrom
mergify/bp/humble/pr-3043

Conversation

@mergify
Copy link

@mergify mergify bot commented Jan 4, 2025

Description

If you run the default generated configs for MoveIt on a headless system where DISPLAY isn't defined in the environment, this code crashes with a KeyError. Switch to use dict.get(DISPLAY, "") which returns "" instead of
throwing.

Checklist


This is an automatic backport of pull request #3043 done by [Mergify](https://mergify.com).

@codecov-commenter
Copy link

codecov-commenter commented Jan 4, 2025

⚠️ Please install the 'codecov app svg image' to ensure uploads and comments are reliably processed by Codecov.

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 51.37%. Comparing base (01c66b3) to head (ced4a8d).
Report is 1 commits behind head on humble.

❗ Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files
@@            Coverage Diff             @@
##           humble    #3193      +/-   ##
==========================================
- Coverage   51.38%   51.37%   -0.01%     
==========================================
  Files         382      382              
  Lines       31890    31890              
==========================================
- Hits        16383    16379       -4     
- Misses      15507    15511       +4     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@sea-bass sea-bass merged commit 4965677 into humble Jan 4, 2025
@sea-bass sea-bass deleted the mergify/bp/humble/pr-3043 branch January 4, 2025 01:52
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.

3 participants