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

Check for nil Dependency#previous_requirements before passing to T.must #9428

Merged
merged 1 commit into from Apr 4, 2024

Conversation

bdragon
Copy link
Member

@bdragon bdragon commented Apr 3, 2024

Dependency#previous_requirements may be nil, so handle nil case before passing to T.must, which may cause a runtime exception.

Closes #9325

@bdragon bdragon added T: bug 🐞 Something isn't working F: grouped-updates 🎳 Relates to bumping more than one dependency in a single PR sorbet 🍦 Relates to Sorbet types labels Apr 3, 2024
@bdragon bdragon requested a review from a team as a code owner April 3, 2024 21:02
@bdragon bdragon changed the title sorbet: avoid T.must on nilable value Check for nil Dependency#previous_requirements before passing to T.must Apr 3, 2024
@bdragon bdragon merged commit 36e67c6 into main Apr 4, 2024
123 checks passed
@bdragon bdragon deleted the bdragon/iss-9325 branch April 4, 2024 00:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
F: grouped-updates 🎳 Relates to bumping more than one dependency in a single PR sorbet 🍦 Relates to Sorbet types T: bug 🐞 Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

TypeError: Passed nil into T.must
2 participants