-
-
Notifications
You must be signed in to change notification settings - Fork 543
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
Fix missing markers and opening rule violation #3725
Fix missing markers and opening rule violation #3725
Conversation
Reviewer's Guide by SourceryThis PR addresses two issues: a Windows CI permission error in pyinstrument tests by modifying temporary file handling, and missing Django database markers in channel layer tests. The implementation involves adding the django_db marker to multiple test functions and modifying the NamedTemporaryFile usage to prevent file deletion on Windows. No diagrams generated as the changes look simple and do not need a visual representation. File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @DoctorJohn - I've reviewed your changes and they look great!
Here's what I looked at during the review
- 🟢 General issues: all looks good
- 🟢 Security: all looks good
- 🟢 Testing: all looks good
- 🟢 Complexity: all looks good
- 🟢 Documentation: all looks good
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.
CodSpeed Performance ReportMerging #3725 will not alter performanceComparing Summary
|
a75b007
to
7508237
Compare
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #3725 +/- ##
===========================================
- Coverage 97.02% 65.46% -31.56%
===========================================
Files 503 498 -5
Lines 33658 32507 -1151
Branches 5608 1670 -3938
===========================================
- Hits 32658 21282 -11376
- Misses 793 10906 +10113
- Partials 207 319 +112 |
Description
This PR (hopefully) fixes the following errors currently thrown by our Windows CI:
The
PermissionError
is caused by our incorrect usage oftempfile.NamedRemporaryFile
on Windows. The corresponding docs outline some rules that must be followed on Windows when a named file is opened. Not deleting the temporary file appears to be the easiest solution (CI is cleaning up afterward anyway).The other errors are all related to missing markers. I'm not sure why these tests only fail under Windows. We also set these markers for other Channels tests, so let's try the same here.
Types of Changes
Summary by Sourcery
Fix test failures on Windows by addressing PermissionError in test_pyinstrument and adding missing django_db markers to channel layer tests.
Bug Fixes: