credo icon indicating copy to clipboard operation
credo copied to clipboard

Credo.Check.Consistency.ExceptionNames complains for two exceptions

Open LostKobrakai opened this issue 3 years ago • 3 comments

Precheck

  • Proposals for new features should be submitted via: https://github.com/rrrene/credo-proposals
  • For bugs, please do a quick search and make sure the bug has not yet been reported here

Environment

  • Credo version (mix credo -v): 1.6.4
  • Erlang/Elixir version (elixir -v): 24.0.4/1.12.2
  • Operating system: Mac OS

What were you trying to do?

We have two exception modules in our codebase.

Expected outcome

mix credo --strict to be fine

Actual outcome

Got a complaint from Credo.Check.Consistency.ExceptionNames about inconsistent naming. I'm not sure where it's drawing consistency from for a sample size of two.

LostKobrakai avatar May 02 '22 15:05 LostKobrakai

This sounds like a bug. Thx for reporting! :+1:

rrrene avatar May 15 '22 09:05 rrrene

Thanks for reporting this 😀 It is now fixed on master.

You can try this by setting the Credo dep to

{:credo, github: "rrrene/credo"}

Please report back if your issue is solved! 👍

rrrene avatar Jul 22 '22 14:07 rrrene

I'm still seeing the issue. I still get a consistancy error on the second exception, because it doesn't match the one other exception in the codebase.

LostKobrakai avatar Jul 25 '22 17:07 LostKobrakai