---
title: 'CHR0077: Batch method matches an event type it does not observe'
editUrl: https://github.com/Cratis/Chronicle/edit/main/Documentation/code-analysis/CHR0077.mdx
description: CHR0077 warns when a Cratis Chronicle batch method pattern-matches on an event type missing from its [Observes<T>] list.
lastUpdated: 2026-11-08T00:00:00.000Z
---


## Rule description

A batch method receives only the events of the types its `[Observes<TEvent>]` attributes name. A `switch` case, an `is` check or another type pattern on any other event type can never match, which usually means an `[Observes<TEvent>]` is missing. CHR0077 reports declaration, type and recursive patterns and `is` checks on an event type that no `[Observes<TEvent>]` of the method covers. A pattern on an event type that implements or derives from an observed type is covered.

## Severity

Warning

## How to fix

Add `[Observes<TEvent>]` for the event type, or remove the case.

## Related rules

- [CHR0071](/chronicle/code-analysis/chr0071/): Batch method observes no event types.

## Related topics

- [Reactor batch methods](/chronicle/reactors/batches/)
- [Reducer batch methods](/chronicle/reducers/batches/)
