firebase / firebase/firebase-tools-ui

When firebase.rules have errors then the "Clear all data" button shows a blank page

Open
#1,105 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
291
Forks
74
PR merge metrics
No merged PRs in 30d

Description

### [REQUIRED] Environment info

**firebase-tools:** (version to be filled)

**Platform:** macOS (Safari browser)

### [REQUIRED] Test case

When `firestore.rules` contains syntax errors, clicking the "Clear all data" button in the Firestore Emulator UI (`http://127.0.0.1:4000/firestore/default/data`) results in a blank page instead of showing an error message or handling the error gracefully.

### [REQUIRED] Steps to reproduce

1. Start Firebase Emulator Suite with valid `firestore.rules`
2. Navigate to `http://127.0.0.1:4000/firestore/default/data` in Safari browser
3. Verify the "Clear all data" button works correctly
4. Edit `firestore.rules` to introduce a syntax error (e.g., missing closing brace, invalid syntax)
5. The emulator should detect the error (rules validation fails)
6. While the rules have errors, click the "Clear all data" button
7. Observe that a blank page is displayed instead of an error message or the expected behavior

### [REQUIRED] Expected behavior

When `firestore.rules` has errors, clicking "Clear all data" should either:
- Display an appropriate error message indicating that the rules need to be fixed first
- Or gracefully handle the error and still allow clearing data (if rules validation is not required for this operation)
- Or show a helpful error page instead of a blank page

### [REQUIRED] Actual behavior

When `firestore.rules` contains errors, clicking the "Clear all data" button shows a blank page. After correcting the rules and refreshing the page, the button works fine again.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.