chore: format files in API server#8292
Conversation
WalkthroughThis pull request applies code formatting changes across the API, authentication, background tasks, utilities, tests, and license modules. Changes include consolidating multi-line expressions to single lines, adjusting end-of-file newlines, and removing extraneous whitespace. No functional logic modifications, control flow changes, or behavioral impact. Changes
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~8 minutes Notes:
Poem
Pre-merge checks and finishing touches❌ Failed checks (2 warnings)
✅ Passed checks (1 passed)
✨ Finishing touches
🧪 Generate unit tests (beta)
📜 Recent review detailsConfiguration used: CodeRabbit UI Review profile: CHILL Plan: Pro 📒 Files selected for processing (20)
💤 Files with no reviewable changes (1)
🧰 Additional context used🧠 Learnings (5)📚 Learning: 2025-07-23T18:18:06.875ZApplied to files:
📚 Learning: 2025-09-12T07:29:36.083ZApplied to files:
📚 Learning: 2025-10-17T08:23:54.961ZApplied to files:
📚 Learning: 2025-10-17T08:21:37.517ZApplied to files:
📚 Learning: 2025-10-17T10:46:13.825ZApplied to files:
🧬 Code graph analysis (10)apps/api/plane/bgtasks/workspace_seed_task.py (2)
apps/api/plane/bgtasks/page_transaction_task.py (1)
apps/api/plane/app/views/page/base.py (1)
apps/api/plane/api/serializers/project.py (1)
apps/api/plane/authentication/views/app/gitea.py (1)
apps/api/plane/api/serializers/__init__.py (1)
apps/api/plane/app/views/asset/v2.py (1)
apps/api/plane/utils/cycle_transfer_issues.py (1)
apps/api/plane/app/views/issue/label.py (1)
apps/api/plane/app/views/cycle/base.py (2)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (3)
🔇 Additional comments (39)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Pull request overview
This PR applies consistent code formatting across multiple Python files in the API server. The changes are purely cosmetic, improving code readability without modifying any logic or behavior.
Key changes:
- Reformatted long lines by breaking them into multiple lines with proper indentation
- Removed unnecessary blank lines and trailing whitespace for consistency
- Fixed minor spacing issues (e.g., extra space in class declaration)
Reviewed changes
Copilot reviewed 16 out of 20 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| apps/api/plane/utils/openapi/decorators.py | Added blank line for separation, fixed trailing whitespace |
| apps/api/plane/utils/cycle_transfer_issues.py | Reformatted long filter/annotate chains and conditional expressions |
| apps/api/plane/utils/content_validator.py | Simplified multi-line conditional expression |
| apps/api/plane/tests/unit/serializers/test_label.py | Reformatted long constructor calls |
| apps/api/plane/license/api/views/admin.py | Improved function call line wrapping |
| apps/api/plane/bgtasks/workspace_seed_task.py | Reformatted bulk_create calls with list comprehensions |
| apps/api/plane/bgtasks/page_transaction_task.py | Removed unnecessary blank lines, reformatted bulk_create call |
| apps/api/plane/authentication/views/app/gitea.py | Simplified urljoin and provider initialization calls |
| apps/api/plane/authentication/provider/oauth/gitea.py | Reformatted datetime.fromtimestamp call, fixed trailing whitespace |
| apps/api/plane/authentication/adapter/base.py | Reformatted get_configuration_value call |
| apps/api/plane/app/views/page/base.py | Reformatted Page.objects.get calls |
| apps/api/plane/app/views/issue/label.py | Reformatted LabelSerializer initialization |
| apps/api/plane/app/views/cycle/base.py | Extensive reformatting of queryset operations, annotations, and conditionals |
| apps/api/plane/app/views/asset/v2.py | Reformatted invalidate_cache_directly and other method calls, removed blank lines |
| apps/api/plane/app/urls/exporter.py | Fixed trailing whitespace |
| apps/api/plane/api/views/member.py | Removed unnecessary blank line |
| apps/api/plane/api/views/cycle.py | Comprehensive reformatting of cycle-related view methods |
| apps/api/plane/api/urls/invite.py | Fixed trailing whitespace |
| apps/api/plane/api/serializers/project.py | Fixed extra whitespace in class declaration |
| apps/api/plane/api/serializers/init.py | Fixed trailing whitespace |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| request_data = { | ||
| "sort_order": request_data.get("sort_order", cycle.sort_order) | ||
| } | ||
| request_data = {"sort_order": request_data.get("sort_order", cycle.sort_order)} |
There was a problem hiding this comment.
Variable request_data is not used.
| request_data = { | ||
| "sort_order": request_data.get("sort_order", cycle.sort_order) | ||
| } | ||
| request_data = {"sort_order": request_data.get("sort_order", cycle.sort_order)} |
There was a problem hiding this comment.
Variable request_data is not used.
| cycle_issues = CycleIssue.objects.bulk_update( | ||
| updated_cycles, ["cycle_id"], batch_size=100 | ||
| ) | ||
| cycle_issues = CycleIssue.objects.bulk_update(updated_cycles, ["cycle_id"], batch_size=100) |
There was a problem hiding this comment.
Variable cycle_issues is not used.
| cycle_issues = CycleIssue.objects.bulk_update(updated_cycles, ["cycle_id"], batch_size=100) | |
| CycleIssue.objects.bulk_update(updated_cycles, ["cycle_id"], batch_size=100) |
Type of Change
Summary by CodeRabbit
✏️ Tip: You can customize this high-level summary in your review settings.