74,491 questions
-2
votes
0
answers
40
views
main.go code to start for for oapi-codegen generated gorilla mux code
Hi I am trying to generate go code by using the oapi-codegen toolkit. My openapi spec 3.0.3 is pretty extensive. The generation of the code (with strict http setting) is flawless but it results in a ...
Best practices
0
votes
4
replies
142
views
Programmer owns the architecture, AI implements crate-level modules in Rust — how does this compare to other languages?
After working on several Rust projects with AI assistance, I want to share a division of responsibility that has worked well in practice, and ask whether others have found the same — or a better ...
1
vote
0
answers
19
views
go/ast, insertion in file.Decls produces invalid code because of comment
I want to create a new struct embedding original struct. But if original struct has comment, it gets placed in the middle of embed struct declaration.
Example code:
https://go.dev/play/p/8xqxpmNy2Qj
...
-1
votes
0
answers
34
views
Prisma client not generated during Go build in deployment environment (Choreo)
I am building a Go backend using Prisma (prisma-client-go)
Locally, everything works fine because I run the following command manually:
PRISMA_CLIENT_GO_BINARIES_ALL=true go run
github.com/steebchen/...
1
vote
1
answer
70
views
How do I order documentation for package declarations in go
Given a package layout as follows:
.
└── pkg
└── pkg1
├── a.go
├── b.go
└── pkg1.go
It's possible to write documentation for the package declaration that appears in the ...
2
votes
1
answer
141
views
Why does adding fmt.Printf change the equality result of two interface variables holding empty structs in Go? [duplicate]
I'm observing a strange behavior in Go where the presence of a fmt.Printf statement affects the boolean result of an interface comparison.
Env:
go version go1.25.6 darwin/amd64
package main
import &...
0
votes
2
answers
113
views
Forcing Go to not use the gold linker
I'm trying to build a Go package in Flathub's CI for an aarch64 Linux architecture. The build is failing while compiling a C dependency:
# github.com/rclone/rclone
/usr/lib/sdk/golang/pkg/tool/...
0
votes
0
answers
127
views
Delve debug go app in docker container with network_mode host
I want to debug my go code which is mounted into a docker container. Delve is installed inside the container.
I am using goland by jetbrains.
Everything works fine as long as I don't use the container ...
Advice
2
votes
9
replies
283
views
Which programming language is best for learning System Design?
I’m planning to start learning System Design, but I’m a bit confused about which programming language I should focus on for it.
Most of my experience so far is with C++ and JS, but I often see people ...
0
votes
1
answer
78
views
Is Youtube V3 IfNoneMatch is a no-op?
Considering the following code, I expect the call to return an error when the Etag that is provided is the same as the remote one.
But when testing it does not really matter if it match or not.
func (...
0
votes
0
answers
101
views
BigQuery Storage Write API: "context deadline exceeded" only on low-frequency table
Problem
I'm using the BigQuery Storage Write API (Go managedwriter package) to upload data to three tables with very different ingestion rates:
Table
Frequency
Record Size
A
~10 records/sec
Several KB
...
1
vote
1
answer
82
views
Debug Golang dockerized project tests
I have a Golang project, a single page application in React, where golang works as static files server and API. The application can be run using docker compose up and npm run in the web folder.
Here ...
Advice
1
vote
3
replies
135
views
Project or features suggestion to add to my project to impress company or CEO
I see everyone is doing the same project ecom or some learning platform, streaming platform or social media. can anyone suggest me a unique one. I am a fresh go-lang developer (has done ecom as my ...
0
votes
1
answer
114
views
Accessing the individual words of the content a file
I am working on a project whereby I want to access the individual words in a file and not the individual character eg. "Welcome to my world" should be equal to "Welcome" "to&...
Advice
0
votes
5
replies
145
views
How can I safely implement a progress bar in a concurrent Go port scanner?
I wrote an open port scanner in Go. For local adresses scans are instant. However, when I scan an external address it takes a bit longer, and I want to see the progress. I tried to implement a ...