Live data from Hacker News

Amazon CodeGuru – Preview

aws.amazon.com

61–70 of 209 posts

Re: Amazon CodeGuru – Preview

#62
post #3

The code review feature seems too expensive to run on every PR automatically (to me): $0.75 per 100 lines of code. From their example pricing: "if you have a typical pull request with 500 lines of code, it would only cost $3.75 to run CodeGuru Reviewer on it." I wonder if it's actually good enough to justify that price.

Or when a junior dev switches from tabs to spaces

Re: Amazon CodeGuru – Preview

#63
post #3

The code review feature seems too expensive to run on every PR automatically (to me): $0.75 per 100 lines of code. From their example pricing: "if you have a typical pull request with 500 lines of code, it would only cost $3.75 to run CodeGuru Reviewer on it." I wonder if it's actually good enough to justify that price.

If it’s trained on software written by Amazon it’s probably worth the $3.75 just so you can do the exact opposite of what they recommend.

Re: Amazon CodeGuru – Preview

#64
post #3

The code review feature seems too expensive to run on every PR automatically (to me): $0.75 per 100 lines of code. From their example pricing: "if you have a typical pull request with 500 lines of code, it would only cost $3.75 to run CodeGuru Reviewer on it." I wonder if it's actually good enough to justify that price.

That’s incredibly cheap, assuming it provides good suggestions. How much time does it take you to review 500 lines of code change, and what’s your time worth? If it takes 10 minutes and your time is worth about $20/hour or more, this service will part for itself immediately.

Only if CodeGuru gets a lot of the value of a code review. But I think finding actual bugs is a pretty small of it.

A good code base is a team-created intellectual work. For that to happen, you need a ton of collaboration, shared learning, evolution of norms, interpersonal bonding, and practice of key social behaviors (e.g., principled negotiation, giving good feedback, recognizing and rewarding good actions). Automated code review gets at none of that.

Re: Amazon CodeGuru – Preview

#65
post #35

Earlier quoted context omitted.

That’s incredibly cheap, assuming it provides good suggestions. How much time does it take you to review 500 lines of code change, and what’s your time worth? If it takes 10 minutes and your time is worth about $20/hour or more, this service will part for itself immediately.

Our code reviews are far more "is this the right way to solve the problem?" than "hey, you never use that variable you declared." The latter would be picked up by our linter; I'm having a hard time seeing the value proposition here. >It’s like having a distinguished engineer on call, 24x7 I don't believe that, regardless of how many times they sprinkle in the words "machine" and "learning".

I'd be very surprised if the service they've announced is a linter.

The announcement says it can even analyze parts your code that are more computationally expensive than they need to be. I'm not sure I understand the skepticism--surely they have among the largest code repositories in the world. Why couldn't they train models on it to look at best practices and even compare code practices to different metrics.

Re: Amazon CodeGuru – Preview

#66

I got to preview this service (the code review service) a few weeks ago. The best thing about it was the recommendations on how to use the AWS SDK better as that's probably got the most potential to drift or make mistakes on

considering how it can be a driver for AWS sales, they should give the service for free though

Re: Amazon CodeGuru – Preview

#68
post #21

I found what it generates. https://github.com/pediredla/Algorithms/pull/3/files It looks like a linter, but maybe there is more.

I've never seen a linter tell me problems with code in this detail before: > You are using a `ConcurrentHashMap`, but your usage of `get()` and `put()` may not be thread-safe at lines: 110, 113, 135, and 137 . Two threads can perform this same check at the same time and one thread can overwrite the value written by the other thread.

Many linters are state-aware, for example to catch use-before-init bugs in various languages.

This one could be a fairly simple rule ConcurrentHashMap.get() followed by some code that branches on the result, followed by put() is unsafe. These warnings can be very helpful, but no fairy ML magic needed.

Re: Amazon CodeGuru – Preview

#69

Code review is not linter. Code review is a chance to discuss design, scaling, trade-offs and mentor others. I don't think this solution will offer it.

I think this does what you mention and not the former. I would imagine this works best when you have a codebase that heavily utilizes the AWS SDK so it can internally 'paint a picture' of what's going on and provide better architectural decisions and other best practices.

How well it works is beyond me though

Re: Amazon CodeGuru – Preview

#70
post #39

Earlier quoted context omitted.

Don't accidentally commit `node_modules` - that'd be a costly mistake!

Or a 35,000 line XML configuration file.

Now that I think of it, if it's paid by lines of code, it perversely incentives people to minimize the lines of code, no? Does it count white space and comments? Can I minify my code before passing it to this, then unminify it?
Post reply on HN