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

fix(editor): remove error messages when deleting a file #6309

Merged
merged 2 commits into from
Sep 4, 2024

Conversation

liady
Copy link
Contributor

@liady liady commented Sep 4, 2024

Problem:
We currently clear errors only when a descriptor file is deleted. This can cause syntax errors to remain even after the file that they're in was deleted.

Fix:
Clear errors on every file delete

Manual Tests:
I hereby swear that:

  • I opened a hydrogen project and it loaded
  • I could navigate to various routes in Preview mode

Fixes #6300

Copy link
Contributor

github-actions bot commented Sep 4, 2024

Try me

Copy link

relativeci bot commented Sep 4, 2024

#14080 Bundle Size — 62.53MiB (-0.07%).

58be8cb(current) vs 916e8b9 master#14078(baseline)

Warning

Bundle contains 70 duplicate packages – View duplicate packages

Bundle metrics  Change 3 changes Improvement 1 improvement
                 Current
#14080
     Baseline
#14078
Improvement  Initial JS 45.66MiB(-0.09%) 45.7MiB
No change  Initial CSS 0B 0B
Change  Cache Invalidation 22.72% 21.6%
No change  Chunks 30 30
No change  Assets 33 33
Change  Modules 4380(+0.02%) 4379
No change  Duplicate Modules 519 519
No change  Duplicate Code 31.61% 31.61%
No change  Packages 472 472
No change  Duplicate Packages 70 70
Bundle size by type  Change 2 changes Improvement 2 improvements
                 Current
#14080
     Baseline
#14078
Improvement  JS 62.52MiB (-0.07%) 62.56MiB
Improvement  HTML 11.06KiB (-0.33%) 11.09KiB

Bundle analysis reportBranch fix/remove-errors-on-deleteProject dashboard


Generated by RelativeCIDocumentationReport issue

...nextEditor,
propertyControlsInfo: updatePropertyControlsOnDescriptorFileDelete(
editor.propertyControlsInfo,
action.filename,
),
}
return removeErrorMessagesForFile(withUpdatedPropertyControls, action.filename)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We must have been assuming that any other change would trigger a canvas render

@liady liady merged commit e7cc599 into master Sep 4, 2024
18 checks passed
@liady liady deleted the fix/remove-errors-on-delete branch September 4, 2024 11:39
liady added a commit that referenced this pull request Dec 13, 2024
**Problem:**
We currently clear errors only when a descriptor file is deleted. This
can cause syntax errors to remain even after the file that they're in
was deleted.

**Fix:**
Clear errors on every file delete

**Manual Tests:**
I hereby swear that:

- [X] I opened a hydrogen project and it loaded
- [X] I could navigate to various routes in Preview mode

Fixes #6300
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.

Deleting a file with a syntax error leaves the canvas permanently broken
4 participants