cblavier

cblavier

AI-based Pull Request reviews

We tried Sourcery, a GitHub integration that posts instant AI-based code reviews on our pull requests.

I was pleasantly surprised by how relevant the code reviews were :exploding_head:

Some excerpts:



Please let me know if you

  • have ever tried such tools?
  • have any recommendations for a specific tool?

Marked As Solved

shiroyasha

shiroyasha

Reporting back after a couple of weeks of using Sourcery that @cblavier shared. Initially the tool was a nuisance, it generated too much content and interfered with human-to-human communication. We had to silence most of its options, and to add a couple of extra handcrafted prompts to make it behave in a reasonable way.

With those additions, the generated comments started to be actually useful. It is not able to detect larger problems, wrong architecture decisions, but it is good at spotting typos, missing validations, edge cases, etc… It reduces the burden of manual reviews and gives feedback faster to the team.

Overall, the tool is in the nice-to-have category, but not yet in the must-have category.

Also Liked

dimitarvp

dimitarvp

For typo checks you should use GitHub - crate-ci/typos: Source code spell checker. I’m using it almost every day and it simply works every time.

It even has a GitHub action if you don’t want to only use it as an offline CLI tool (which is how I use it exclusively but a GitHub action is super useful for CI/CD).

rbino

rbino

Ash Core Team

This could be another alternative:

I’ve never personally tried it but the maintainer is a friend of mine and he told me it’s generic so it should work on any type of repo.

D4no0

D4no0

I think this should be highlighted, as this is the silver lining. Such tools are just linters on steroids, even though I doubt they are that consistent, it would be a mistake to assume that they can replace the human factor in code reviews.

I also think it’s also important to point out that this might be a shortcut for companies that never understood how to setup and use already existing static analysis tools like credo (especially with custom made check rules).

earonesty

earonesty

i wrote my own (corerev.q32.com), here’s why:

i want it to:

  • inline comment
  • draft only
  • in my name (for me to look at and approve/change/edit)

this:

  • gives me focus
  • saves me time

i use it every day.

shiroyasha

shiroyasha

Never tried out anything similar , but it looks like it could be useful. Just installed it on our repo. My first impression is that is is quite noisy e.g. chore: Convert login page to react by shiroyasha · Pull Request #1638 · operately/operately · GitHub, but maybe I have to get used to it.

Did your team leave all the config options enabled or you made some modifications?

Where Next?

Popular in Questions Top

LegitStack
I’m hoping you guys can give me some general advice and perhaps code examples if you’re feeling up to it. I’m very interested 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
openscript
Hello! Sorry for this astonishing simple question, but I’m really stuck. I try to set up the intellij-elixir plugin, but I don’t know ho...
New
jerry
Good day to you all. I have been struggling to get a query involving like and ilike to work. Can anyone assist me on this, please? pro...
New
Harrisonl
We have an ECS cluster with 4 services, where each task joins a single cluster, via discovery ECS discovery service. Currently when I de...
New
ashish173
I am using Ecto timestamps with postgres, I can see the timestamps() use the :naive_dateime but for my use case I wanted to store the ti...
New
qwerescape
Is there a way to get the call stack or stack trace at any point in the code? Not from exceptions, but an expression that returns how the...
New
fayddelight
I tried installing elixir 1.11.2 erlang 23.3.4 via asdf in my zsh shell. Enabled the versions locally and globally. When I list them ...
New
kostonstyle
Hi all I want to have a unix time, from the current time plus 1 hour. DateTime.now + 1 hour How to get it in elixir? Thanks
New
jay1
Why is it that the mnesia database isn’t the most preferred database for use in Elixir/Phoenix?
New

Other popular topics Top

lessless
I believe there are people here who are dealing with CSV files import on the daily basis, and since Excel is a really popular tool there ...
New
_russellb
I want to try my hand at web scraping. What tools/libraries do I need to use. I’m hoping to turn this into something professional so don’...
New
Harrisonl
We have an ECS cluster with 4 services, where each task joins a single cluster, via discovery ECS discovery service. Currently when I de...
New
chrismccord
This release brings a number of exciting features, including integration with the new Phoenix LiveDashboard and Phoenix LiveView. There h...
New
stefanchrobot
What’s the safe way to decode a JSON string into a struct? I want to avoid calling String.to_atom. Jason.decode can give me a map with st...
New
chrismccord
As promised, the first release candidate of Phoenix 1.3.0 is out! This release focuses on code generators with improved project structure...
New
shahryarjb
Hello, I have map which I want to convert it to string like this: the map: %{last_name: "tavakkoli", name: "shahryar"} the string I ne...
New
Fl4m3Ph03n1x
About me? ( if you have nothing better to do than reading about some random guy in the internet :stuck_out_tongue: ) Hello all, this is ...
New
josevalim
Hi everyone, One of the features added to Elixir early on to help integration with Erlang code was the idea of overridable function defi...
New
lucidguppy
I have a super simple question about elixir - how would I take a file like this foo bar baz and output a new file that enumerates th...
New

We're in Beta

About us Mission Statement