Deal with elixir 1.19 warnings and test failures #1029

Merged
Oneric merged 11 commits from Oneric/akkoma:elixir-1.19-warnings into develop 2025-12-29 00:09:38 +00:00
Owner

Currently only deal with stuff in lib/, but there’s still more to be updated in tests/. Also haven’t checked mix formatyet after the adjustments (or whether 1.18 and 1.19 agree on formatting)

Most of it is just changes to the struct-update syntax (which now can only be used if the updated variable points at a guaranteed matching module), but some more notable changes:

  • to comply with the parallel compile stuff, the min elixir version is raised to 1.15; given 1.14 is EOL and debian-oldstable builds already require asdf anyway that should be fine. However, we’ll need new CI containers for the current lowest and newest versions, cc @floatingghost
  • the hashtag thing was actually a leftover 1.18 warning.
    I think I now understand what it was meant to do (strip the leading # if any) but as it was written it just didn’t do anything except producing a confusing compiler warning. This now makes the normalisation actually work, but we’ll need to keep code to deal with both formats at all places around due to existing db entries not being normalised. At first glance it seems like such code is already in place
Currently only deal with stuff in `lib/`, but there’s still more to be updated in `tests/`. Also haven’t checked `mix format`yet after the adjustments (or whether 1.18 and 1.19 agree on formatting) Most of it is just changes to the struct-update syntax *(which now can only be used if the updated variable points at a guaranteed matching module)*, but some more notable changes: - to comply with the parallel compile stuff, the min elixir version is raised to 1.15; given 1.14 is EOL and debian-oldstable builds already require asdf anyway that should be fine. However, we’ll need new CI containers for the current lowest and newest versions, cc @floatingghost - the hashtag thing was actually a leftover 1.18 warning. I think I now understand what it was _meant_ to do (strip the leading `#` if any) but as it was written it just didn’t do anything except producing a confusing compiler warning. This now makes the normalisation actually work, but we’ll need to keep code to deal with both formats at all places around due to existing db entries not being normalised. At first glance it seems like such code is already in place
It can include a terminal-colour sequence before the final newline
Defining inside project() is deprecated
When feasible actually enforce the to-be-updated data being the desired struct type.
For ActivityDraft this would add too much clutter and isn't necessary
since all affected functions are private functions we can ensure only
get correct data, thus just use simple map-update syntax here.
utils: comply with elixir 1.19 soft-requirement for parallel compiles
Some checks failed
ci/woodpecker/pr/test/1 Pipeline failed
ci/woodpecker/pr/test/2 Pipeline failed
cd780179f6
Elixir 1.19 now requires (with a deprecation warning) return_diagnostics
to be set to true for parallel compiles. However, this parameter was only
added in Elixir 1.15, so this raises our base requirement.
Since Elixir 1.14 is EOL anyway now this shoulöd be fine though.
Oneric force-pushed elixir-1.19-warnings from cd780179f6
Some checks failed
ci/woodpecker/pr/test/1 Pipeline failed
ci/woodpecker/pr/test/2 Pipeline failed
to d8427df3c2
Some checks failed
ci/woodpecker/pr/test/1 Pipeline failed
ci/woodpecker/pr/test/2 Pipeline failed
2025-12-07 18:00:54 +00:00
Compare
Oneric force-pushed elixir-1.19-warnings from d8427df3c2
Some checks failed
ci/woodpecker/pr/test/1 Pipeline failed
ci/woodpecker/pr/test/2 Pipeline failed
to 23085e61a2
Some checks failed
ci/woodpecker/pr/test/1 Pipeline failed
ci/woodpecker/pr/test/2 Pipeline was successful
2025-12-21 23:39:13 +00:00
Compare
Author
Owner

Now passes (1.19’s) mix format and tests are warning-clean too (as far as out own code is concerned at least; from our dependencies Pleroma’s BBCode parser continues producing a bunch of warnings)

This did actually reveal a couple bugs

@floatingghost can you update the CI images to 1.19 (ideally OPT28) and 1.15 respectively, so this can actually run as intended?

Now passes (1.19’s) `mix format` and tests are warning-clean too *(as far as out own code is concerned at least; from our dependencies Pleroma’s BBCode parser continues producing a bunch of warnings)* This did actually reveal a couple bugs @floatingghost can you update the CI images to 1.19 (ideally OPT28) and 1.15 respectively, so this can actually run as intended?
Oneric force-pushed elixir-1.19-warnings from 23085e61a2
Some checks failed
ci/woodpecker/pr/test/1 Pipeline failed
ci/woodpecker/pr/test/2 Pipeline was successful
to 6b37f24949
Some checks failed
ci/woodpecker/pr/test/1 Pipeline failed
ci/woodpecker/pr/test/2 Pipeline was successful
2025-12-22 02:17:17 +00:00
Compare
Oneric force-pushed elixir-1.19-warnings from 6b37f24949
Some checks failed
ci/woodpecker/pr/test/1 Pipeline failed
ci/woodpecker/pr/test/2 Pipeline was successful
to baad95eaa5
Some checks failed
ci/woodpecker/pr/test/2 Pipeline was successful
ci/woodpecker/pr/test/1 Pipeline failed
2025-12-24 02:45:05 +00:00
Compare
Oneric force-pushed elixir-1.19-warnings from baad95eaa5
Some checks failed
ci/woodpecker/pr/test/2 Pipeline was successful
ci/woodpecker/pr/test/1 Pipeline failed
to 1fed47d0e0
Some checks failed
ci/woodpecker/pr/test/1 Pipeline failed
ci/woodpecker/pr/test/2 Pipeline was successful
2025-12-25 12:20:02 +00:00
Compare

ci images 1.15-otp25 and 1.19-otp28 available on both arches, sorry for the delay

ci images 1.15-otp25 and 1.19-otp28 available on both arches, sorry for the delay
ci: adjust elixir and OTP versions
Some checks failed
ci/woodpecker/pr/test/2 Pipeline failed
ci/woodpecker/pr/test/1 Pipeline was successful
cbae0760d0
test: fix regex compare for OTP28
All checks were successful
ci/woodpecker/pr/test/2 Pipeline was successful
ci/woodpecker/pr/test/1 Pipeline was successful
86d62173ff
This was technically already incorrect before and pointed out as such in
documentation, but in practice worked well until OTP28’s regex changes.
Oneric merged commit c971f297a5 into develop 2025-12-29 00:09:38 +00:00
Oneric deleted branch elixir-1.19-warnings 2025-12-29 00:09:39 +00:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
AkkomaGang/akkoma!1029
No description provided.