belaustegui

belaustegui

ErrorTracker - an Elixir-based built-in error tracking solution

Announcing ErrorTracker, an Elixir-based built-in error tracking solution.

Features

  • Basic, free, built-in error tracking solution. Tracking errors in your application should be a requirement for almost any project and it helps to improve quality and maintenance.
  • Easy to set up. Includes plug-and-play integrations that work automatically such as:
    • Plug integration
    • Phoenix integration
    • Oban integration
  • Minimalistic. You just need a relational database to store errors. It can be your application’s database or a separate one.
  • Web UI. Includes a LiveView dashboard that allows you to search, manage and resolve recorded errors.
  • Extra context. Recorded errors include additional context such as the request path or the LiveView event for the Phoenix integration and the job ID and parameters for the Oban integration. You can also add your additional context.

What makes ErrorTracker different?

ErrorTracker does not require you to rely on third party services to track your errors. Your errors, just like your data, are yours. You decide where to store them, when to prune them and how to manage them.

This is invaluable for a whole set of applications that handle PII data and must maintain a high level of care when sharing that data with third parties. No need to worry whether the third party complies with HIPAA, GDPR, etc. as your data won’t leave your systems.

This is also highly beneficial for small projects that can’t afford to pay a third party service for tracking errors. Without this observability, errors are hard to debug and fix. The ErrorTracker allows you to track errors for free in your current system and may provide this observability capabilities that will help you reproduce and fix errors easily.

Useful links

Screenshots

Most Liked

odarriba

odarriba

Version 0.2.0 is out!

This update includes several improvements to the library:

  • SQLite 3 compatibility (including a better way to track database schema versions)
  • Telemetry events - can be used to integrate your own notifications
  • UI improvements - more refined styles and UX
  • A better test suite, including testing in both RDBMS and different Elixir/Erlang versions in the CI

GitHub release
Hex.pm release

If you are already using the library: there is a new version of the DB schema, so you need to create a new migration to migrate to version 2.

We hope this version fixes some of the issues reported :slight_smile: any feedback is welcome!

jaimeiniesta

jaimeiniesta

Hey ErrorTracker team, thanks a lot for your effort in putting this together! I already fixed an error thanks to your library :slight_smile:

Please consider adding a way to sponsor the project, it will surely be well-received by the community.

odarriba

odarriba

We’ve been working on this for the last month and a half :smiley: There are a lot of things to polish yet, but we believe it is a good starting point to release it.

As for now it only tracks exceptions and not performance, but the base is there to add more features in the future :rocket:

ivanhercaz

ivanhercaz

I am already working on the suggestion I did some days ago:

If everything goes well, I think I could release a first release of the package this weekend. I will notice you!

odarriba

odarriba

That makes sense, because V02 in PostgreSQL systems creates a new table to store meta information and moves the information about which migration version is the latest to that table.

Tables and structures used by ErrorTracker are not changed - we may use the new error_tracker_meta table in the future, but not now - so the system will work without that migration but it is really recommended to stay up to date.

As we migrated how the schema version number is stored - and it is an important information to take into account on the migration process - that migration is different to others, but we have tested it and should work as expected.

That’s the issue! We should have included that in the release message, but the idea is to have it like:

defmodule MyApp.Repo.Migrations.UpdateErrorTrackerToV02 do
  use Ecto.Migration

  def up, do: ErrorTracker.Migration.up(version: 2)
  def down, do: ErrorTracker.Migration.down(version: 2)
end

which produces this output when migrating:

15:42:49.730 [info] == Running 20240814134232 MyApp.Repo.Migrations.UpdateErrorTrackerToV02.up/0 forward

15:42:49.764 [info] create table if not exists public.error_tracker_meta

15:42:49.800 [info] execute "COMMENT ON TABLE \"public\".error_tracker_errors IS ''"

15:42:49.801 [info] execute "INSERT INTO public.error_tracker_meta (key, value)\nVALUES ('migration_version', '2'), ('migration_timestamp', '1723642969')\nON CONFLICT (key) DO UPDATE SET value = EXCLUDED.value\n"

15:42:49.807 [info] == Migrated 20240814134232 in 0.0s

in the way you created it works fine if you go up, but on the down it will remove all migrations, so reverting the other one will result in errors because tables don’t exist anymore.

Yes!

Hope it helps!! If you have more issues please feel free to open an issue and we can find a solution there.

Where Next?

Popular in Announcing Top

isaias-dias-machado
IEx’s h macro is great but it lacks a pager, so I built a small tool that caches documentation and lets you fuzzy search through it in yo...
New
shahryarjb
The Chelekom project is a library of Phoenix and LiveView components generated via Mix tasks to fit developer needs seamlessly. One of i...
New
jarlah
Testcontainers Testcontainers is an Elixir library that supports ExUnit tests, providing lightweight, throwaway instances of common datab...
New
Antrater
Hi there! At Moon Design System, we have been working hard for the past six months on the next generation of our LiveView component libra...
New
LostKobrakai
I’ve recently created a small library phoenix_vite integrating the vite build tooling with phoenix. It provides an igniter.installer t...
New
jsm
Once is an Ecto type for locally unique 64-bits IDs generated by multiple Elixir nodes. Locally unique IDs make it easier to keep things ...
New
sevensidedmarble
Announcing Live Toast: a replacement toast/flash component for Phoenix LiveView, heavily inspired by the look of Sonner (the amazing toas...
New
taro
I took lessons from the last discussion and cobbled together an example as a proof-of-concept. Mar demonstrates a Flask-like web dev int...
New
germsvel
PhoenixTest provides a unified way of writing feature tests – regardless of whether you’re testing LiveView pages or static pages. It al...
New
trisolaran
Hi! :waving_hand: I would like to present LiveSelect, a little library that I wrote to easily add a dynamic selection input to your LV f...
194 10054 106
New

Other popular topics Top

yurko
Here are few pieces of (common) Linux knowledge that we use for reasonably small one server apps. We use Ubuntu but this should work for ...
New
sergio
In Ruby, I can go: User.find_by(email: "foobar@email.com").update(email: "hello@email.com") How can I do something similar in Elixir? ...
New
albydarned
Hello all! I am typing this post from my new MacBook Pro with the M1 chip. I’m loving it so far, and will probably use it as my daily dr...
New
hariharasudhan94
I would like to know what is the best IDE for elixir development?
New
vertexbuffer
Hello, can anybody help here..? I have a list of players and I what to delete an element, but every for loop the list is reverting to ori...
New
minhajuddin
I have seen a lot of code which picks the first element from a list using Enum.at(0) instead of List.first. Is there a reason why people ...
New
chensan
I have a User schema with a :from_id field set to type :string: defmodule TweetBot.Repo.Migrations.CreateUsers do use Ecto.Migration ...
New
vonH
When I run the Plug and I recompile I wind up having to use Ctrl C to quit iex and start again. Witht the help of rlwrap I can use the cu...
New
skosch
To my knowledge, put_in, Map.update etc. all have the one limitation of not automatically creating intermediate keys when needed (for exa...
New
AstonJ
We’ve put together this wiki for Phoenix LiveView - please feel free to add any info you feel is worth including. What is Phoenix LiveV...
New

We're in Beta

About us Mission Statement