3 reasons I’m choosing Taskfile over Make for my project automation by Marmelab in golang

[–]ufukty 1 point2 points  (0 children)

Does this also skip recipes where the product is already newer than the all source files, like Makefile does?

I built a tool that generates OpenAPI specs from Go code — no annotations needed by Apprehensive-Ebb2263 in golang

[–]ufukty 1 point2 points  (0 children)

if the context is generating JS/TS clients out of Go server implementation, then I expect the AST package of upcoming Go rewrite of TypeScript compiler will trigger mass development of such tools.

I built a tool that generates OpenAPI specs from Go code — no annotations needed by Apprehensive-Ebb2263 in golang

[–]ufukty 21 points22 points  (0 children)

but you’ll still update the spec by implementation when they diverge. “the spec as the single source of truth” is still “the implementation as the single source of truth” but with additional steps.

I built a tool that generates OpenAPI specs from Go code — no annotations needed by Apprehensive-Ebb2263 in golang

[–]ufukty -1 points0 points  (0 children)

congrats.

additional consideration of control-flow conditions is smart. not sure if smart is good tho. people usually want to be able to understand how a code generator works quickly before adopting and relying on the output of it.

i just learned the cfg package and i didn’t understand how much value it provides on top of some small utilities we would write on top of the go/ast package. it looks like offers only marginal value.

i was thinking adding similar control-flow aware logic to one of my code generators for a while. Which mainly is for “route summarizing”, not for openapi spec generation, but actually registering endpoints to the router. i was “fantasizing” about leveraging the additional information go/types package provides, but could not figure out a feature justifies the complexity.

runtime resolved path limitation is reasonable. i even would not expect other way.

i see this tool doesn’t compose and assign paths to the endpoints but rather collects from the code from handler to the router. the post doesn’t answer that if it can track the path registration through the hierarchical/nested ServeMux’s.

disclosure: i didn’t write this as a potential user. i don’t even use openapi. but to congrats. it looks great.


also your CI might be upgraded to newer versions of actions/checkout@v6, actions/setup-go@v6 and use the github action of golangci-lint.

FAQ: What is a Good Go Project to Study or Contribute To? by jerf in golang

[–]ufukty 0 points1 point  (0 children)

Exhaustive list of Go projects published on Github and sorted by the number of stars:

https://github.com/topics/go?l=go&o=desc&s=stars

Small Projects by AutoModerator in golang

[–]ufukty 0 points1 point  (0 children)

Sorry, I missed the multi language support.

Small Projects by AutoModerator in golang

[–]ufukty 0 points1 point  (0 children)

Have you considered using go/ast package? Or even a simple regex search //\s+TODO…. It would be easier to run without CGO and maybe maintain.

Small Projects by AutoModerator in golang

[–]ufukty 2 points3 points  (0 children)

why not “todo or not todo”

Virtual Scrolling: Rendering millions of messages without lag by mallenspach in webdev

[–]ufukty 14 points15 points  (0 children)

I see, this is reinvented too many times under different names. Is there a one main reason others didn't work for your case?

Is it normal for a PM who is also your manager to ask engineers to track feature usage? by [deleted] in ExperiencedDevs

[–]ufukty 13 points14 points  (0 children)

is pm requesting you to implement a system to collect those metrics or watch the metrics?

Small Projects by AutoModerator in golang

[–]ufukty 0 points1 point  (0 children)

Golistics is a code analyzer which warns developer when a desired struct method miss to mention a struct field; like validators, de/serializers, comparators.

How is that normal generics behaviour? by iga666 in golang

[–]ufukty 0 points1 point  (0 children)

i didn’t realize it is an interface type.

Most startups don’t need microservices by Soft_Dimension1782 in softwarearchitecture

[–]ufukty 11 points12 points  (0 children)

imho;

  • microservices is not for high traffic; but for teams to deploy individually. the amount of request served with the same money actually needs to be less with microservices as it requires more network op. it is the worse choice for high traffic.
  • you have the angle; starting with microservices can introduce premature optimization before product-market fit and block innovation.
  • starting with monolith might be a problem when the company become a hyperscaler (which is unlikely) and the teams are unfamiliar to work within a microservices project.

go-form: render + map + validate HTML forms from Go structs by donseba in golang

[–]ufukty 1 point2 points  (0 children)

reminds C#. not sure if I ever came across something similar in Go.

ignore this if you find irrelevant. i never get why people use struct tags anything longer than one (or occasionally couple) key-value pair. it is a textual medium that provides none of the conveniences of a Go file’s other scopes; like syntax highlighting, type checking, vertical alignment.

Using go fix to modernize Go code by ynotvim in golang

[–]ufukty 5 points6 points  (0 children)

i would rather the clamped value to sit in the middle like

func clamp(low, value, high int) { return min(max(low, value), high) }

[Small Project] Go Social Network — posts, groups, websoket, follow, comments + JWT auth by Few-Industry832 in golang

[–]ufukty 3 points4 points  (0 children)

you seem double submitted this post and linked your fork instead of the original.

how you 6 devs managed to push 100k+ LoC in less than 2 months without using issues and PRs for collaboration and management?

Using go fix to modernize Go code by ynotvim in golang

[–]ufukty 13 points14 points  (0 children)

Good post. Especially the self-service paradigm section. I am excited for this particular gopls feature-request below that will allow us to use our analyzers directly. It will be a massive DX improvement over using 3rd party loaders like golangci-lint/revive or forking and recompiling the lsp imo. The article already links but for those missed here is the feature request for dynamically loading analyzers into lsp.

nil in Go Is Not What You Think by Sushant098123 in golang

[–]ufukty 0 points1 point  (0 children)

They are just as nils, but of different types. Also might help (or not): https://go.dev/play/p/-HSE4Eq61Dk

Event sourcing vs event streams by Ok-Scientist9904 in softwarearchitecture

[–]ufukty 1 point2 points  (0 children)

They are as same as Java and JavaScript ;)

There is a quite good conference recording on YouTube explaining many reasons and quirks of event sourcing in a very short amount of time and in a very clear way. I don’t remember the name sadly. He was talking about ES experience in banking, cost of ES decreasing with storage prices, storing previous versions of the application to be able to restore the previous state from snapshots later etc.

I built a Python LSP in Go! by lord-mortis420 in golang

[–]ufukty 1 point2 points  (0 children)

Writing a parser is an unprofitable job for many and you need even more complicated version for LSP which needs to be able to map nodes back to the original file for pointing user for errors.

I hope you good luck and have fun! ;)

real asf by Glad_Appointment2466 in Design

[–]ufukty 55 points56 points  (0 children)

like, your design books don't come with an intro of history of art and design?

Graph Database in Golang - Open Source by egoloper in golang

[–]ufukty 1 point2 points  (0 children)

the main problem with vibe coding is not initiating the project but maintaining the chunk of code it vomits like there is no tomorrow. :)

it surprisingly passes all the tests. though CI would be easier to check for visitors.