dmesg --follow
[ 67100100.000 ] posts.x: Am I in the minority using Sol as my daily driver in Codex?  |   [ 67097280.000 ] posts.x: Full talk on why MCP's context problems are a harness issue, not a protocol issue, and what MCPC does about it:  |   [ 67097280.000 ] posts.x: A lot of the AI world spent the past year calling MCP dead, Anthropic included, with Theo, Gary Tan, and Peter Levels all piling on, even as MCP…  |   [ 67037100.000 ] posts.x: @TheZachMueller Nice one! That’s a warm room, just in time for winter.  |   [ 67035060.000 ] posts.x: Full talk on turning scattered engineering judgment, feature-flag agent included, into something a coding agent can actually use:  |   [ 67035060.000 ] posts.x: A team held a recurring meeting every two weeks for one purpose: deleting feature flags nobody needed anymore. @aorobator, a Senior Software Engineer…  |   [ 67034100.000 ] posts.x: Full talk on Greptile's AI-generated PR data, agent revert rates, and the three-question framework behind merging without human review:  |   [ 67034100.000 ] posts.x: A quarter of the pull requests Greptile reviews every month are now completely or largely AI generated, up from under 1% early last year. @greptile…  |   [ 67018080.000 ] posts.x: Full talk on rumors hardening into facts inside a multi-agent village, and the auto-research loop built to catch it:  |   [ 67018080.000 ] posts.x: A rumor that one agent "might leave" can harden into "is leaving" as it spreads through a multi-agent village, with nobody noticing the shift from…  |   [ 67010820.000 ] posts.x: Full talk on building the harness, from reward hacking to bare metal tuning, behind a 3x kernel speedup:  |   [ 67010820.000 ] posts.x: GPU kernels turn out to be an unusually good match for an agent loop: there's a clear benchmark, and a result that's either faster and correct or it…  |   [ 66968520.000 ] posts.x: Full talk on pitting Claude Code, Codex, and Kimi against a human speedrun record, and why none of them found a novel optimizer to win it:  |   [ 66968520.000 ] posts.x: Two coding agents went up against a community speedrun that human researchers spent two years grinding down, and neither one found a genuinely novel…  |  
corey@gallon.me:~/til$

Debugging Python CLI Arguments in VSCode

FIGURE 1 ⋅ Debugging Python CLI Arguments in VSCode

Command Palette (CTRL+SHIFT+P): Debug: Add Configuration

Command Palette Debug Config.png
FIGURE 2 ⋅ Command Palette Debug Config.png

Then, select “Python Debugger”

Command Palette Python Debugger.png
FIGURE 3 ⋅ Command Palette Python Debugger.png

Then, select “Python File with Arguments”

Command Palette Python File with Arguments.png
FIGURE 4 ⋅ Command Palette Python File with Arguments.png

VSCode then creates the .vscode directory in your project, if it doesn’t exist already, and adds launch.json as follows:

{
    // Use IntelliSense to learn about possible attributes.
    // Hover to view descriptions of existing attributes.
    // For more information, visit: https://code.visualstudio.com/docs/debugtest/debugging
    "version": "0.2.0",
    "configurations": [
        {
            "name": "Python Debugger: Current File with Arguments",
            "type": "debugpy",
            "request": "launch",
            "program": "${file}",
            "console": "integratedTerminal",
            "args": "${command:pickArgs}"
        }
    ]
}

If you don’t change anything, when you debug a file VSCode will prompt you for arguments to pass the file every time you run the debugger.

VSCode Prompt for Arguments.png
FIGURE 5 ⋅ VSCode Prompt for Arguments.png

Can also click, bottom right, “Add Configuration” which will stub out adding more configs in the JSON so that you can tailor it to your specific application. For example:

{
    // Use IntelliSense to learn about possible attributes.
    // Hover to view descriptions of existing attributes.
    // For more information, visit: https://code.visualstudio.com/docs/debugtest/debugging
    "version": "0.2.0",
    "configurations": [
        {
            "name": "Blue Horseshoe Debugger",
            "type": "debugpy",
            "request": "launch",
            "program": "${file}",
            "console": "integratedTerminal",
            "args": ["run", 
            "--players", "5", 
            "--duration", "2", 
            "--round-end", "fixed", 
            "--config", "strategy_config.yaml", 
            "--simulation", "true", 
            "--strategies", "conservative,conservative,conservative,momentum,arbitrage"]
        },
        {
            "name": "Python Debugger: Current File with Arguments",
            "type": "debugpy",
            "request": "launch",
            "program": "${file}",
            "console": "integratedTerminal",
            "args": "${command:pickArgs}"
        }
    ]
}
corey@gallon.me:~$ tail -f /writing Attach to the stream. An email when I have something worth sending. Replies encouraged!
corey@gallon.me:~$ ls -lt /til ↑2024-09-15 Debugging Python Tests in VSCode
▸2024-09-15 Debugging Python CLI Arguments in VSCode ⋅ you are here
↓2024-09-11 Suppressing Rich Tracebacks in Typer Apps