Deprecate levelpad of Logger.Formatter by nallwhy ยท Pull Request #11633 ยท elixir-lang/elixir
Navigation Menu
{{ message }}
elixir-lang / elixir Public
- Notifications You must be signed in to change notification settings
- Fork 3.5k
Merged
josevalim merged 4 commits intoelixir-lang:mainfrom
Feb 17, 2022Merged
Deprecate levelpad of Logger.Formatter#11633
josevalim merged 4 commits intoelixir-lang:mainfrom
Deprecate levelpad of Logger.Formatter#11633
josevalim merged 4 commits intoelixir-lang:mainfrom
Conversation
Copy link Copy Markdown
Contributor
nallwhy
commented
Feb 16, 2022
nallwhy
commented
This PR fixes #11629.
$levelpadis removed from@default_patternofLogger.Formatter- Functions related to levelpad are annotated with
@deprecated
Copy link Copy Markdown
Member
josevalim
commented
Feb 16, 2022
josevalim commented
Feb 16, 2022Thank you for the PR @nallwhy!
Unfortunately the @deprecated attributes you added won't work as expected. You need to remove them. Instead, you need to add something here:
elixir/lib/logger/lib/logger/formatter.ex
Line 102 in 2c3e902
| defp compile_code(key) when key in @valid_patterns, do: key |
Something like:
defp compile_code(:levelpad) do IO.warn "$levelpad in Logger message format is deprecated, please remove it" :levelpad end
nallwhy
force-pushed
the
deprecate_levelpad
branch
2 times, most recently
from
eac33c3 to
b1d5a60
Compare
nallwhy
force-pushed
the
deprecate_levelpad
branch
from
b1d5a60 to
a6c3d93
Compare
josevalim added 2 commits
February 17, 2022 08:02
josevalim
merged commit
f20c017
into
elixir-lang:main
Copy link Copy Markdown
Member
josevalim
commented
Feb 17, 2022
josevalim commented
Feb 17, 2022๐ ๐ ๐ ๐ โค๏ธ
PaulJKim
mentioned this pull request
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment