xpg
What are people’s experiences in parsing compiler and dialyzer errors and warnings within their build systems?
I’m using Jenkins myself, and used to use the (now deprecated) Warnings Plugin. I had a small Groovy script setup to collect errors and warnings, but I never got it working perfectly.
Now I’m replacing the deprecated Jenkins plugin with a new one. So now I’m trying to figure out what the best way is to get both errors and warnings from both the Elixir compiler and Dialyzer into Jenkins.
There are many ways to attack this problem, and I guess it’s not unique to Jenkins either. Unfortunately, my Google Search skills have failed me, so I haven’t been able to find anything usable.
What do you guys do?
Trending in Questions
I’m working on a project that simulates the bumbl example in the programming phoenix book. It acts almost like an email client. We have a...
New
I’m seeing that a list inside a Kino.DataTable will be interpreted as a charlist, even if the Kino.configure() is set to charlists: :as_l...
New
Hello,
I know there is an approach for handling lists that allows for optimized traversal, but I can’t recall the specific method (somet...
New
So my question is quite simple and i have found no conclusive answer on forum, google or AI.
Should we use :erlang.float for Integer to ...
New
Hi, I’ve just set up an application with ash_authentication. There is only magic link strategy for now, so there is no confirmation add o...
New
If a change or preparation module uses Ash.Changeset.get_argument/2 or Ash.Query.get_argument/2 (or any of the other get_argument functio...
New
apply_graft/2 doesn’t rewrite an add_many sub-workflow’s deps on an add step. Grafted jobs cancel with “upstream job was deleted”
Version...
New
Other Trending Topics
I am happy to introduce the very α version of the new programming language compiled to BEAM.
Welcome Cure.
It has literally three kille...
New
Hi there! We created Gust: A task orchestrator inspired by Airflow.
For those who have never heard about Aiflow, it’s a Python-based wor...
New
Beam Bots (or just BB for short) is a framework for building fault-tolerant robotics applications in Elixir using familiar OTP patterns. ...
New
Xamal is a deployment tool for Elixir apps that deploys native releases to bare metal servers over SSH. It’s a port of GitHub - basecamp/...
New
Hello everyone. After busy few months I am happy to announce v0.1.0 of Emerge & Solve.
They are GUI (Emerge) and State management (S...
New
Corex is an accessible, unstyled UI component library for Phoenix that integrates Zag.js state machines using Vanilla JavaScript and Live...
New
Categories:
Sub Categories:
Forums
Popular Tags
- #ecto
- #liveview
- #troubleshooting
- #learning-elixir
- #library
- #deployment
- #erlang
- #testing
- #genserver
- #mix
- #absinthe
- #remote-other
- #otp
- #plug
- #how-to-question
- #macros
- #postgres
- #elixirconf
- #channels
- #exunit
- #discussion
- #code-sync
- #podcasts
- #javascript
- #onsite
- #dialyzer
- #docker
- #authentication
- #umbrella
- #full-time-contract
- #podcasts-by-brainlid
- #ecto-query
- #ai
- #elixirconf-us
- #blog-post
- #elixir-ls
- #phoenix_html
- #iex
- #graphql
- #genstage
- #websockets
- #supervisor
- #advent-of-code
- #distillery
- #processes
- #api
- #forms
- #hex
- #security
- #metaprogramming











Showing Posts 1 to 8- Show Best Posts
- Show All (oldest first)
- Show All (newest first)
hauleth
You can always call Dialyzer directly and then format it to whatever format you like instead of parsing text output.
xpg
That’s an interesting idea. Seems like a much more stable approach, than parsing the text output.
I wonder if something similar could be done for the Elixir compiler.
hauleth
In theory - yes. In practice it would be much harder, especially as it will not be able to catch all messages anyway due to fact that Elixir compile time is in fact runtime, so you can always use
IO.puts/1to output additional messages.xpg
Yeah, that makes sense. I probably won’t get around parsing the output from the compiler.
It seems that the Jenkins warning plugin has “native” JSON and XML formats. I wonder if there is a more universal format. If that was the case, I could write a script that parses Elixir Compiler output and generates a file that is usable by more systems than just Jenkins.
hauleth
Microsoft and GitHub are pushing for SARIF, GitLab uses CodeClimate format. I am in the process of publishing my GitLab CI pipeline that does all the magic needed with all different reporting components, so far I have:
Parsing compiler output which is produced only in “human friendly” way is PITA even for stuff like Vim quick fix and I was trying to suggest flag for machine readable output for some time now, but never succeeded in any meaningful way.
xpg
I kinda of expected to run into multiple standards for this (but hoped that it would not be the case). Thank you for pointing me in some directions.
I’ll have to look into the details and figure out what makes most sense. We also use TypeScript, so I will see which reporting formats works well with that.
I have previously written parser for “human friendly” compiler outputs. Yeah, it’s a pain
, but it looks like there is no easy way around it.
hauleth
There is to get some messages out of the compiler. This is how ElixirLS is providing diagnostics. Obviously it will not work 100% of the cases (especially with dependencies), but it will provide something. With Dialyzer it will be a little bit harder, but still should be possible to do by “manually” calling Dialyzer instead of relying on the Dialyxir/Dialyzex tasks.
xpg
Thank you for all your comments.
.
You’ve given me quite a bit to think about