Curved Glossy Dragonfly
Medium
Custom modules not supposed to used error code of value one, as it is reserved for internal errors in cosmos
The Epoching
module utilize the error code 1, which is the reserved code value for the internal errors in cosmos sdk,
https://docs.cosmos.network/main/build/building-modules/errors#registration
Allowing custom modules to define errors with code 1 could lead to vagueness, If two different parts of the system (the core SDK and a module) were both allowed to use code 1, then it wouldn’t be clear whether an error with that code came from a fundamental problem in the SDK or from a module’s custom logic. Keeping code 1 off-limits for modules prevents such conflicts.
Avoid using error code 1