smpallen99 / coherence

Coherence is a full featured, configurable authentication system for Phoenix
MIT License
1.27k stars 224 forks source link

Elixir.1.14 #422

Closed Sinc63 closed 1 year ago

Sinc63 commented 1 year ago

There are two updates here.

The first resolves a number of issues related to Elixir 1.14 and an upgrade of ex_doc. It changes the use of "use Bitwise" and eliminates the use of get_env at compile time. It eliminates the use of "use Mix.Config", anticipates the deprecation of Logger.warn in 1.15, and fixes some problems running test and mix docs. (I still can't run tests because it doesn't like me running "MIX_ENV=test mix ecto.create", but at least the compile warnings are resolved.)

The second update resolves dialyxir warnings from two sources. I ran it against the project itself and tried to resolve those errors including resolving some suppressed errors, but I also ran it against InfinityOne where I know it generates a lot of warnings of a repetitive type. The latter effort triggered the mass of changes in the responders, where the arity 1 functions inserting an empty map generally didn't help, because the arity two functions almost all require some specific keys in the map, so will fail with a FunctionClauseError, where now if you call the arity 1 it should fail on compile.

I suggest reviewing the two commits independently.

Sinc63 commented 1 year ago

This PR includes most of the content of https://github.com/smpallen99/coherence/pull/420 https://github.com/smpallen99/coherence/pull/416 and https://github.com/smpallen99/coherence/pull/393, which I will mark appropriately once this is merged.

smpallen99 commented 1 year ago

Appoved