elixir-pdf-generator
elixir-pdf-generator copied to clipboard
Use new Supervisor syntax for elixir version >= 1.5
Hello,
I came across an issue where, after upgrading to elixir 1.11, I saw that pdf_generator.ex was still using the deprecated syntax for Supervisor.spec.worker.
I made the change to use the new child specification syntax that is applicable for elixir versions 1.5 and above.
If anything is out of place or not the best practice, I would really appreciate it if you let me know, as I'm a newbie in the open source/elixir world.
Thank you very much!
Dongkeun
Hi @dlee-tt , thanks a bunch for your PR! I was very busy with private things and at work so sorry this module seemed like unmaintained :grimacing:
Right now, PdgGenerator only required Elixir 1.1 to work and thus relies on a quite a few very-style mechanics. I would assume there's not a lot of people out there still using such an old Elixir version but I am unsure if bumping the minimum required version to, let's say 1.5 is fine to everyone. Probably yes. What's your opinion on that?
Hi @gutschilla,
Thank you for responding during a busy time!
In my opinion, it would be fine; as you mentioned, 1.1 is quite old at this point and I believe most users should have upgraded to version 1.5 or higher at this point in time. And if it forces some users to upgrade their Elixir version, I think it might be preferable to do it now than later, since eventually this would be inevitable.
Elixir 1.15 was released in 2017. I think requiring ~> 1.15 should not be a problem for anyone at this point. Currently, even security fixes are only supported from 1.9.
https://hexdocs.pm/elixir/main/compatibility-and-deprecations.html
Hi @gutschilla, can you please review the merge request again and release the changes? I'm using Elixir version 1.14 and I have this deprecation message
@gutschilla I offer a suggestion: You can raise the minimum elixir version, merge this pr, bump the package to 2.0 and put the new elixir version as the breaking change in the release notes.