Best of GolangMarch 2026

  1. 1
    Video
    Avatar of youtubeYouTube·9w

    Go FINALLY Fixed Its Dumbest Syntax Problem

    Go 1.26 enhances the built-in `new` function to accept expressions in addition to types, allowing developers to take the address of a value directly without needing a temporary variable or a generic helper function. Previously, passing a literal value as a pointer required either storing it in a throwaway variable or writing a utility function (a pattern common in codebases like the AWS SDK). With this change, `new(0.15)` works directly, eliminating boilerplate for structs with optional pointer fields.

  2. 2
    Article
    Avatar of lnLaravel News·12w

    Ward: A Security Scanner for Laravel

    Ward is a Go-based command-line security scanner built specifically for Laravel projects. It parses Laravel's structure (routes, models, controllers, Blade templates, config files, env vars, dependencies) and runs four targeted scan engines: env-scanner, config-scanner, dependency-scanner (using live OSV.dev data), and a rules-scanner with 42 built-in rules covering secrets, injection, XSS, weak crypto, and more. It features a terminal UI, multiple output formats (JSON, SARIF, HTML, Markdown), CI/CD integration with exit-code gating, baseline management to track acknowledged findings, custom rule support, and scan history diffing.

  3. 3
    Article
    Avatar of redpandaRedpanda·10w

    Introducing Redpanda AI SDK for Go

    Redpanda has open-sourced an AI SDK for Go designed for production use. The SDK addresses gaps in existing Go AI tooling by providing provider portability across OpenAI, Anthropic, Google Gemini, and AWS Bedrock, idiomatic streaming, composable middleware with layered interceptors, an Agent-to-Agent (A2A) adapter, a flexible tool system with MCP support, and a simulated LLM framework for deterministic testing. It powers Redpanda's own Agentic Data Plane and is available at github.com/redpanda-data/ai-sdk-go.

  4. 4
    Article
    Avatar of antonzAnton Zhiyanov·9w

    Porting Go's io package to C

    A deep dive into porting Go's io package to C, covering the key design challenges: representing Go slices as C structs, handling multiple return values via result structs and unions, modeling sentinel errors as pointer-comparable structs, and implementing Go interfaces using fat structs with function pointers. The post also covers type assertion via function pointer comparison and uses alloca for stack-allocated buffers in the Copy function. The result is verbose but structurally faithful C code that mirrors Go's io.Reader, io.Writer, LimitedReader, and Copy semantics.

  5. 5
    Article
    Avatar of hnHacker News·10w

    pgit: What If Your Git History Was a SQL Database?

    pgit is a Git-like CLI that stores repository history in PostgreSQL using delta compression via a custom Table Access Method (pg-xpatch). It lets you query your entire commit history with SQL and provides built-in analyses for churn, coupling, hotspots, bus factor, and activity. Benchmarked against 20 real repositories (273k commits), pgit outcompresses `git gc --aggressive` on 12 out of 20 repos. The tool also works well as an interface for AI agents: a Claude agent produced a full codebase health report on Neon's repo in under 10 minutes using a 4-sentence prompt. pgit is not meant to replace git for daily workflows but excels at programmatic codebase history analysis.

  6. 6
    Video
    Avatar of youtubeYouTube·12w

    Go 1.26's Small But Clever New Function Change!

    Go 1.26 enhances the built-in `new` function to accept an initializer expression, allowing memory allocation and value assignment in a single step. Previously, developers had to allocate with `new(T)` and then dereference the pointer to assign a value, often requiring temporary variables. With Go 1.26, `new(42)` allocates an integer pointer initialized to 42 directly. This is particularly useful when working with pointer fields in structs for optional JSON/protobuf fields, partial API updates (PATCH semantics), and table-driven tests, where temporary helper variables were previously needed just to obtain a pointer to a literal value.

  7. 7
    Video
    Avatar of youtubeYouTube·12w

    Should you learn Go in 2026?

    A Go developer and former Twitch senior engineer makes the case for learning Go in 2026 despite AI disruption and tech layoffs. Key arguments include Go's dominance in cloud-native tooling (Kubernetes, Docker), its suitability for microservices, its simplicity making it AI-friendly for code generation, its robust standard library, and strong job market demand with competitive salaries. The GitHub 2025 developer survey is cited showing Go among the most admired and desired languages.

  8. 8
    Article
    Avatar of antonzAnton Zhiyanov·9w

    Solod: Go can be a better C

    Solod (So) is a new programming language that is a strict subset of Go and transpiles to readable C11 code. It features zero runtime overhead, no garbage collection, stack-allocated memory by default with opt-in heap allocation, and native C interop without CGO. So supports structs, methods, interfaces, slices, multiple returns, defer, and enums, while omitting goroutines, channels, closures, and generics. Since So is valid Go code, existing Go tooling (LSP, linting, go test) works out of the box. The post provides a comprehensive language tour showing side-by-side Go and generated C code for all supported features, along with design decisions emphasizing simplicity, readability of generated C, and seamless C interoperability.

  9. 9
    Article
    Avatar of Marmelabmarmelab·11w

    Taskfile: The Modern Alternative to Makefile That Will Change Your Workflow

    Taskfile is a Go-based task runner that addresses common Makefile frustrations with a YAML-based syntax. It offers built-in self-documentation via a `desc` field and `task --list`, native cross-platform support using a `platforms` field instead of fragile OS detection, built-in file watching with a `--watch` flag, interactive prompts and preconditions without shell-specific code, and explicit parallel dependency control. Additional features include task namespacing, Taskfile includes with namespacing, output control flags, and experimental remote Taskfiles. The post compares Makefile and Taskfile implementations for a React/Node.js project, arguing that while Make can technically do most of the same things, Taskfile avoids the need to maintain shell scripts and compatibility layers.

  10. 10
    Video
    Avatar of davidbombalDavid Bombal·9w

    Vibe coding is scary real!

    A Cisco executive shares how vibe coding transformed a 15-year-old, 500,000-line proprietary 5G network function into a modern Golang microservices architecture using gRPC in just one week — a project that would have taken over a year traditionally. The code was reduced to 106,000 lines and passed initial smoke tests. The exec went from skeptic to believer, predicting AI-assisted coding will become the default way software is developed within 6–12 months, while acknowledging extensive validation is still required before production release.

  11. 11
    Article
    Avatar of theregisterThe Register·12w

    Generic methods approved for Go, devs miss other features

    The Go team has approved a proposal for generic methods, reversing a longstanding position that deemed them unnecessary since they cannot implement interfaces. The proposal, from Go co-designer Robert Griesemer, is fully backward-compatible and moves to implementation, though the limitation that generic methods cannot satisfy interfaces remains. Developer reaction is cautiously positive but notes the feature is incomplete. Meanwhile, Go's 2025 developer survey reveals that missing language features are a top-three frustration, with enums, exception handling, and nil pointer safety ranking as bigger community demands than generic methods.

  12. 12
    Video
    Avatar of oxylabsOxylabs·10w

    Golang Web Scraper Tutorial 2026

    A beginner-friendly tutorial on building a web scraper in Go using the Colly framework. Covers setting up a project, scraping Wikipedia links, extracting structured e-commerce product data into structs, running async parallel requests with rate limiting, paginating through multiple pages automatically, handling errors with OnError callbacks, setting timeouts, integrating rotating proxies, and exporting scraped data to CSV. Also touches on ethical scraping practices like respecting robots.txt and adding request delays.

  13. 13
    Article
    Avatar of hnHacker News·8w

    We Rewrote JSONata with AI in a Day, Saved $500K/Year | Reco

    Reco's principal data engineer used AI to rewrite JSONata (a JavaScript-based JSON query language) as a pure-Go library called gnata in about 7 hours, spending $400 in AI tokens. The original setup ran jsonata-js pods on Kubernetes, costing ~$300K/year and adding ~150 microsecond RPC overhead per evaluation across billions of events. gnata uses a two-tier evaluation architecture: a fast path for simple expressions that operates directly on raw JSON bytes with zero heap allocations, and a full path with complete JSONata 2.x semantics. A streaming layer batches N expressions against each event, reading raw bytes only once. After a week of shadow-mode validation with 1,778 test cases and 2,107 integration tests, gnata replaced the RPC fleet entirely, delivering 25-1000x speedups. Combined with a rule engine refactor enabled by gnata's batch evaluation capabilities, the total savings reached $500K/year in under two weeks of work.

  14. 14
    Article
    Avatar of glwGolang Weekly·11w

    Golang Weekly Issue 592: March 6, 2026

    Golang Weekly issue 592 covers Go 1.26.1 and 1.25.8 security releases fixing five vulnerabilities in crypto/x509, html/template, net/url, and os packages. Featured articles include a deep dive into stack allocation improvements in Go 1.25+ that reduce GC overhead, a guide on preventing silent mutex bugs using generic closures, and best practices for secure error handling. Also linked: opinions on why Go lacks a try keyword, Go for AI agents, and X.509 certificate verification vulnerabilities. Library releases include govips 2.17, eBPF 0.21, Gin 1.12, go-github 84.0, and several others.

  15. 15
    Article
    Avatar of kgtashohakjtdfa49s0ruAugustus Nguyen·12w

    I built a demo showing how singleflight reduced our database load by 97% during a cache stampede

    A Redis connection blip caused 200 concurrent requests to bypass cache and hit PostgreSQL directly. The solution was the singleflight pattern from golang.org/x/sync/singleflight, which deduplicates concurrent identical requests so only one hits the database. A runnable demo is provided with a full Docker Compose stack including PostgreSQL, Redis, Prometheus, and Grafana, plus a load test script. Results show ~97% cache hit rate with only ~220 DB queries out of ~7,500 total requests.

  16. 16
    Article
    Avatar of golangGo·11w

    //go:fix inline and the source-level inliner

    Go 1.26 introduces a source-level inliner as part of the redesigned `go fix` command, enabling self-service API migrations. By annotating deprecated functions with `//go:fix inline`, package authors can instruct the tool to automatically replace calls to old functions with their new equivalents. The post explains how the inliner works and covers six key technical challenges it must handle correctly: parameter elimination, side effects and evaluation order, fallible constant expressions, variable shadowing, unused variables, and defer statements. The inliner is already integrated into gopls for interactive use and has been used to prepare over 18,000 changelists in Google's monorepo.

  17. 17
    Article
    Avatar of freecodecampfreeCodeCamp·10w

    How to Get Started Coding in Golang

    A beginner's guide to Go (Golang) covering installation on WSL/Ubuntu and core language fundamentals. Topics include variable declaration and type inference, string formatting with the fmt package, arrays vs slices, for loops and the range keyword, functions with single and multiple return values, maps and their reference-type behavior, structs as an alternative to maps for mixed-type data, and package scope for organizing multi-file Go projects.