Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: update to elxir 1.15.2 #71

Closed

Conversation

juanazam
Copy link

Update to Elixir 1.15.2 and OTP 26.0.2
The main issue here is that Port.comand is erroring out because of a behavior change on OTP that's not going to be updated.

Related issue on Statix: #69
Related issue on top: erlang/otp#7130

In summary, Statix was using Port.command to avoid a performance issue with using :gen_udp.send.
This approach no longer works because of OTP updates happening at the networking layer.

In order to avoid this, this PR uses :gen_udp.send (which has been optimized), but with this change, a lot of the existing code is not longer useful.

Port.command expects a package containing the IP and port of the destination to which the packet will be sent.
This is no longer required with the new approach, but we need to keep the address and port on the Conn module to be able to do the :gen_udp.send calls to send Statds packages.

The tests pass on their own, but don't pass when running them all together. This happens because testing uses an artificial gen server that opens a socket to receive packets and assert them. With my late

@juanazam juanazam closed this Jul 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant