mau013
Hi everyone,
I have just added Credo to my project and I really liked it. I would like to take it a step further and implement further checks via plugins but I’m struggling to find a list of them… so my questions for you all are:
- Which Credo plugins are you using (if any)?
- Is the community gravitating towards a common set of checks other than those included in Credo itself?
Thanks a ton for any help.
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
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
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
Documentation
While reading the Scoped Routes section, I noticed that the documentation currently refers to a problem without explainin...
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
Other Trending Topics
Hey, I’m Jesse and I’m the main contributor behind Dexter, a full-featured, lightning-fast Elixir LSP optimized for large codebases. It s...
New
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
Hi everyone!
The first release candidate for the Expert language server project is now available!
We’ve published a press release detai...
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
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
- #elixirconf-us
- #ai
- #blog-post
- #elixir-ls
- #phoenix_html
- #iex
- #graphql
- #genstage
- #websockets
- #supervisor
- #advent-of-code
- #distillery
- #processes
- #api
- #forms
- #metaprogramming
- #hex
- #security










Showing Posts 1 to 10- Show Best Posts
- Show All (oldest first)
- Show All (newest first)
sodapopcan
Adobe has some. I know there are others but none off the top of my head.
There are definitely a lot of style plugins that are up to personal taste and I think should stay that way, so I’d suggest looking through the disabled ones that come with Credo as there are some good ones! I particularly like the one that forces you to always pass the
:asyncoption touse ExUnit.Case. This way you can be relatively sure that whoever set it did so for a reason and didn’t absent-mindedly choose the default.pdgonzalez872
Default, not even having a credo file.
Just having something in place gets you 80% there, if not more. You get diminishing returns as you add more, the value it provides starts decreasing after a while, especially in big teams. Checks that are disabled/added because someone that left 3 years ago didn’t quite like it/or thought it was amazing at the time will haunt you later on.
IMO, your miles may vary.
mau013
Thanks! I’ll check this out.
Will do. I’ll take a close look at the disabled list and make sure I’m not missing some I find useful
Yeah, I guess I’m at the point where defining a style for the project is still quite easy, so I’m trying to see where to strike the balance… if there were some clear preferences across the community I would probably swing that way - if only for the sake of making the code more readable / standard… but to your point perhaps the default credo checks already gets us there
pdgonzalez872
This is precisely it, and I believe the default checks are the answer here. Since Credo is open source and there are TONS more eyes on those default checks, I favor that decision over any in house discussion/decision.
D4no0
This results in the same conclusion as the elixir formater arrived to:
The consistency over every random project you can open on the internet makes them more readable and easier to understand, simply because everyone formats/writes code in a similar style.
cmo
Disable the cyclomatic complexity one so you can write big boy/girl functions
sodapopcan
Consistency, even within private projects, is the number one reason I care to use Credo, though the code suggestions are nice too since I don’t use any AI tools.
Big teams, period, is where the deminishing returns are
If people are spending long periods of time arguing over what should go in Credo, or people are adding stuff without telling anyone, there are bigger problems at play. All that to say is that I generally agree the default is ideal, but for me the defaults are a little much and are just there to guard against juniors. Like:
Also stuff like “alias all the things” and “no single pipes” are things that are context-dependent AFAIC. Useful if you’re just letting anyone loose on your codebase, not for my own things.
katafrakt
I remember we have one custom to check if the migration version is a correct timestamp and if it’s not far in the future. The story behind it is that we had some people that liked to touch migration files by hand, without the generator, and at some point we have a migration with timestamp from the future, so every time you wanted to rollback your newly created migration, it rolled back that one instead.
Apart from that I sometimes advocate to have a check forbidding “full imports”. I used it as an example in this article. The check is not perfect IIRC, but bypassing it takes some dedication.
We also use checks from excellent_migrations, but lately I see many people disable them immediately in their migrations, so I guess we have to reevaluate.
dimitarvp
I dislike the raw SQL check myself but the rest I actually like. IMO just discuss with the team. I always recommend the maximum amount of checks and then we just disable whatever ends up being annoying or giving too many false positives.
warmwaffles
So for our code base we have a few situations where
asyncis not possible (modification of application config) and we have thesetupblock raise. In other cases I have been debating just emitting a warning to annoy devs to make them async. In some cases, it just is not possible to make async. But overall, most can be.