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 missing EError doc in AllEventTypes #1111

Merged
merged 1 commit into from
Jan 29, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ All notable changes to this project will be documented in this file.
### Removed
### Fixed

- [janitor] `update-idents` unables to process when some Error docs are in the index.

## [1.11.0] - 2024-01-12

### Added
Expand Down
3 changes: 2 additions & 1 deletion src/Monocle/Backend/Documents.hs
Original file line number Diff line number Diff line change
Expand Up @@ -319,6 +319,7 @@ instance FromJSON EChangeState where
)

-- | When adding new document type, update the `instance FromJSON EDocType` too.
-- | and please make sure to update `allEventTypes` accordingly
data EDocType
= EChangeCreatedEvent
| EChangeMergedEvent
Expand All @@ -339,7 +340,7 @@ data EDocType

allEventTypes :: [EDocType]
allEventTypes =
filter (`notElem` [EChangeDoc, EOrphanTaskData, ECachedAuthor]) [minBound .. maxBound]
filter (`notElem` [EChangeDoc, EOrphanTaskData, ECachedAuthor, EErrorDoc]) [minBound .. maxBound]
Copy link
Contributor

Choose a reason for hiding this comment

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

Should we do an inclustion test instead? Or maybe add a note in the EDocType definition?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Sure I've added a note.


instance From EDocType Text where
from = \case
Expand Down
Loading