Live data from Hacker News

Claude Code 2.0

npmjs.com

321–330 of 431 posts

Re: Claude Code 2.0

#321
post #302
post #276

Earlier quoted context omitted.

From the docs it looks like this feature only reverts the edit tool calls, and not e.g. bash commands that have been executed: > Checkpoints apply to Claude’s edits and not user edits or bash commands, and we recommend using them in combination with version control

How could they possibly hope to undo bash commands, whose side effects could be anything, anywhere? Hey Claude... uh... unlaunch those

By tracking changes made by a command, like you might with git.

Re: Claude Code 2.0

#322
post #123

Earlier quoted context omitted.

> IMPORTANT: DO NOT ADD * ANY** COMMENTS unless asked* Interesting. This was in the old 1.x prompt, removed for 2.0. But CC would pretty much always add comments in 1.x, something I would never request, and would often have to tell it to stop doing (and it would still do it sometimes even after being told to stop).

Meanwhile they deleted the "do not add emojis" part. Look forward to all sorts of logging messages with emojis in them.

I don’t understand where the AI love of emojis comes from. I’ve never seen them in a professional codebase outside of basic logging.

I assume it comes from the myriad tutorial content on medium or something.

gpt-oss is the most egregious emoji user: it uses emoji for numbers in section headings in code, which was clearly a stylistic choice finetuned into the model and it fights you on removing them.

I’ve noticed Claude likes to add them to log messages and prints and with 4.5 seems to have ramped up their use in chat.

Re: Claude Code 2.0

#323

Earlier quoted context omitted.

Avoiding comments is an exercise in thinking how to rename or refactor a function, or a variable in such a way that a junior developer will be able to read it like prose, and immediately understand what's going on. It's cognitively stressing, but is beneficial for juniors, and developers new to the codebase, just as it is for senior developers to reduce the mental overhead for the reader. It's always good to spend an…

This is awfully purist. I think a happy medium of "comment brevity, and try thinking of a clearer way to do something instead of documenting the potentially unnecessary complexity with a comment" would be good. I don't know where this "comments are instant technical debt" meme came from, because it's frankly fucking stupid, especially in the age of being able to ask the LLM "please find any out-of-date comments in th…

> "comment brevity, and try thinking of a clearer way to do something instead of documenting the potentially unnecessary complexity with a comment"

That's exactly what I wrote, phrased slightly differently.

We both agree at the core.

Re: Claude Code 2.0

#324

Earlier quoted context omitted.

This is awfully purist. I think a happy medium of "comment brevity, and try thinking of a clearer way to do something instead of documenting the potentially unnecessary complexity with a comment" would be good. I don't know where this "comments are instant technical debt" meme came from, because it's frankly fucking stupid, especially in the age of being able to ask the LLM "please find any out-of-date comments in th…

Not commenting code seems like the most unhinged thing I can think of. We don't need blueprints to build this building gestures broadly isn't it obvious to the construction workers where to put everything?

The blueprint is the code.

Re: Claude Code 2.0

#325

Earlier quoted context omitted.

The original opus/sonnet 4 safety card mentioned that it would hand write emails to the fbi turning in a user if it thought they were doing something really bad. It has examples of the “snitch” emails. I too use it extensively. But they’re very, very capable models, and the command line contains a bunch of ways to exfiltrate data off your system if it wants to.

That’s a pretty wild misrepresentation. The actual statement was from red team testing in a very contrived and intentional setup designed to test refusal in extreme circumstances. Yes, it was a legit safety issue and worth being aware of, but it’s not it was a general case. Red teamers worked hard to produce that result.

>The actual statement was from red team testing in a very contrived and intentional setup

Was it a paper or something? Would you happen to remember the reference?

Re: Claude Code 2.0

#326
post #271

Earlier quoted context omitted.

I don't know, I tend to agree. I feel like the number of times I've been thrown off by an out of date comment for code that could have probably been refactored to be clearer, outweigh the times a comment has helped. Docstring comments are even worse, because it's so easy for someone to update the function and not the docstring, and it's very easy to miss in PR review

As always the problem isn't the actual thing being discussed - the problem is shitty developers who wrote shitty comments and/or don't update comments when they update code. Good and up to date comments are good and up to date. Bad and outdated comments are bad and outdated. If you let your codebase rot then it rots. If you don't then it doesn't. It's not the comment's fault you didnt update it. It's yours.

It's always a skill issue.

Guard rails should be there to prevent inexperienced developers (or overworked, tired ones) from committing bad code.

"Try to think how to refactor functions into smaller ones and give them meaningful names so that everyone knows immediately what's going on" is a good enough guard rail.

Re: Claude Code 2.0

#327
post #73

Earlier quoted context omitted.

No. Plan mode still works fine. They just changed it so you can't set it to use Opus in planning mode... it uses Sonnet 4.5 for both. Which makes sense Iif it really is a stronger and cheaper model.

It isn’t stronger for these sorts of reasoning tasks.

It is, according to the benchmarks. I'm just taking the materials they provided at face value.

If you have run your own benchmarks or have convincing anecdotes to the contrary, that would be an interesting contribution to the discussion.

Re: Claude Code 2.0

#328
post #49

Something I realized about this category of tool (I call them "terminal agents" but that already doesn't work now there's an official VS Code extension for this - maybe just "coding agents" instead) is that they're actually an interesting form of general agent . Claude Code, Codex CLI etc can effectively do anything that a human could do by typing commands into a computer. They're incredibly dangerous to use if you d…

Obligatory mention: https://xkcd.com/2044/

Re: Claude Code 2.0

#329

Earlier quoted context omitted.

Incredibly dangerous to use? Seems like a wild exaggeration. I’ve been using Claude code since launch, must have used it for 1000 hours or more by now, and it’s never done anything I didn’t want it to do. Why would I run it in a sandbox? It writes code for me and occasionally runs a build and tests. I’m not sure why you’re so fixated on the “danger”, when you use these things all the time you end up realizing that th…

It is dangerous. Just yesterday my cursor agent made some changes to a live kubernetes cluster even over my specific instruction not to. I gave it kubectl to analyze and find the issues with a large Prometheud + AlertManager configuration, then switched windows to work on something else. When I was back the MF was patching live resources to try and diagnose the issue.

May I gently suggest isolating production write credentials from the development environment?

Re: Claude Code 2.0

#330
post #49

Something I realized about this category of tool (I call them "terminal agents" but that already doesn't work now there's an official VS Code extension for this - maybe just "coding agents" instead) is that they're actually an interesting form of general agent . Claude Code, Codex CLI etc can effectively do anything that a human could do by typing commands into a computer. They're incredibly dangerous to use if you d…

Incredibly dangerous to use? Seems like a wild exaggeration. I’ve been using Claude code since launch, must have used it for 1000 hours or more by now, and it’s never done anything I didn’t want it to do. Why would I run it in a sandbox? It writes code for me and occasionally runs a build and tests. I’m not sure why you’re so fixated on the “danger”, when you use these things all the time you end up realizing that th…

have you not seen the screenshots of claude asking permission to delete ~/, because some geniuses decided to make {repo}/~ a folder in cloudflare worker/cursor folders?
Post reply on HN