ChainSafe / lodestar

🌟 TypeScript Implementation of Ethereum Consensus
https://lodestar.chainsafe.io
Apache License 2.0
1.16k stars 283 forks source link

Review electra type safety #6799

Open wemeetagain opened 4 months ago

wemeetagain commented 4 months ago

There are some patterns that lead to degraded type-safety. We should review our codebase, especially things added in electra, for these types of patterns and refactor if possible.

Ideally we can more clearly articulate our findings here into something that can be added to the contributing doc or elsewhere.

is there a way to make this more typesafe?

I'll make an issue for later, but there are some patterns in our code that lead to this kind of bug (that we should clean up later).

_Originally posted by @wemeetagain in https://github.com/ChainSafe/lodestar/pull/6788#discussion_r1603812066_

philknows commented 4 months ago

Is this in any way related to #6775 ?