-
Notifications
You must be signed in to change notification settings - Fork 152
fix: rooms not working on video #1339
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: rooms not working on video #1339
Conversation
Reviewer's guide (collapsed on small PRs)Reviewer's GuideAdjusts default room visibility and sidebar behavior so rooms stay visible in the schedule editor while only appearing in the sidebar once configured. Flow diagram for room visibility and sidebar behavior during creationflowchart TD
A["Start room creation with data"] --> B["Check 'module_config' in data"]
B --> C["Set 'has_modules' = boolean of data['module_config']"]
C --> D["If 'setup_complete' not in data, set data['setup_complete'] = has_modules"]
D --> E["If 'hidden' not in data, set data['hidden'] = False"]
E --> F["If 'sidebar_hidden' not in data, set data['sidebar_hidden'] = data['hidden'] OR NOT data['setup_complete']"]
F --> G["Room created with final 'hidden' and 'sidebar_hidden' values"]
subgraph "Resulting behavior"
H["Schedule editor visibility"]
I["Sidebar visibility"]
end
G --> H
G --> I
H --- H1["Rooms are visible by default because 'hidden' defaults to False"]
I --- I1["Rooms only appear in sidebar when 'setup_complete' is True and 'hidden' is False"]
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 there - I've reviewed your changes - here's some feedback:
- When computing
sidebar_hidden, consider usingdata.get("hidden", False)and the existinghas_modulesflag instead of relying ondata["hidden"]anddata["setup_complete"]so the logic is more robust to missing keys and less dependent on the ordering of the precedingsetdefaultcalls.
Prompt for AI Agents
Please address the comments from this code review:
## Overall Comments
- When computing `sidebar_hidden`, consider using `data.get("hidden", False)` and the existing `has_modules` flag instead of relying on `data["hidden"]` and `data["setup_complete"]` so the logic is more robust to missing keys and less dependent on the ordering of the preceding `setdefault` calls.Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.
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.
Pull request overview
This PR fixes an issue where newly created rooms would disappear from the schedule editor by explicitly setting default values for the hidden and sidebar_hidden fields during room creation.
- Sets
hiddentoFalseby default to keep rooms visible in the schedule editor - Sets
sidebar_hiddenbased on both thehiddenstate andsetup_completestatus to prevent unconfigured rooms from appearing in the sidebar - Adds clear inline comments explaining the purpose of each field
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Srivatsav Auswin <75414859+Sak1012@users.noreply.github.com> Co-authored-by: Mario Behling <mb@mariobehling.de>
Fixes #1343
Summary by Sourcery
Adjust room visibility and sidebar behavior for newly created rooms to ensure they remain visible in the schedule editor while staying hidden from the sidebar until configured.
Bug Fixes: