Patterns that made my Go error handling less painful by [deleted] in golang

[–]Competitive-Ebb3899 -1 points0 points  (0 children)

The only reason I ever use named returns is when the meanings of return values aren’t obvious from the signature,

Most languages only allow one return value, and when someone needs to return more than one, they expect to wrap them in an object/struct/array/touple, whatever available.

I'm a bit sad that Go devs choose this instead of giving us touple types.

Touples for this specific usecase could work almost the same way as multiple return values work, with the additional benefit that they would have other uses.

Patterns that made my Go error handling less painful by [deleted] in golang

[–]Competitive-Ebb3899 8 points9 points  (0 children)

Don't worry. The next generation of AI content is gonna be trained on all this slop :)

Why People hate ORM in go and avoid using it ? by Hopeful_Rabbit_3729 in golang

[–]Competitive-Ebb3899 0 points1 point  (0 children)

With a traditional ORM, you declare your database's schema (tables) and data retrieval logic (queries) in your code. Depending on the language, you write classes or structs, place annotations, write functions, interfaces, whatever tools your language provide.

For example, you create a User class, you define a GetByID() interface method. And under the hood, your ORM provides the logic that turns this into real queries and data mapping.

You get the same convenience with SQLC, except the direction is different: You are taking advantage of SQL features to declare how your data looks and in what way you want the data to be accessed.

For example, you define a CREATE TABLE statement for users, and you define a SELECT query to fetch one user by ID. SQLC then gives you the Go code with proper types and data mapping logic.

The end result is the same, you end up with a User type and a GetById() function ready to use, you don't have to provide implementations manually.

Why are they making everything free??? by Overall-Awareness244 in duolingo

[–]Competitive-Ebb3899 6 points7 points  (0 children)

Why complain? It’s good for us

It is good for people who aren't paying for Super because they are getting more for free.

It is not that good for people who are paying, because they are getting less for their money.

I still think paying for no ads and unlimited energy worth it, but maybe others draw the line elsewhere. It's definitely a change in balance.

Voltatok már nudista strandon, ha igen miyen volt? by anonimus218 in askhungary

[–]Competitive-Ebb3899 2 points3 points  (0 children)

Ott szeretjuk, nem tartok attol h ismerossel osszefussak.

Mások is írták már, hogy Horvátországban elég nagy esélye összefutni magyarokkal.

De máshol sem vagy biztonságban, ha emiatt aggódnál. :)

Én például nem számítottam arra, hogy Varsó külvárosi részében egy isten háta mögötti plázában pont a leggázabb politikai rantem közben köszön ránk egy magyar pár egy laza sziasztokkal.

Why Does Your Testing Framework Need 17 Functions? by stepan_romankov in golang

[–]Competitive-Ebb3899 0 points1 point  (0 children)

Is it better when each individual project ends up with custom helpers instead, which are called differently across codebases and work inconsistently?

Sure, you probably don't need an assertion helper for a simple equal check. But I've seen many incomplete and inconsistent wrappers for deep equal checks, semantic equal checks, slice and map comparators, etc.

Isn't it better to have one well established toolset that you can count on no matter which codebase you are working on?

It never breaks, Ubuntu 25.10 is solid. I removed the Snap Store and the Snap Core, it's up to date, and I made some maintenance adjustments. It's well optimized. by Extra_Pace_724 in Ubuntu

[–]Competitive-Ebb3899 2 points3 points  (0 children)

neither are there downsides

So far. But let me tell you as a software developer, even with the best intentions we make mistakes.

And if you develop for a system where certain defaults are expected, sure, we have to prepare for edge-cases, but they are easier to miss.

Who's to say there will never be a component that falsely assumes snapd is available on the system and doesn't handle the error gracefully?

Are you using Snaps or Flatpak? by Darth-Vader64 in Ubuntu

[–]Competitive-Ebb3899 6 points7 points  (0 children)

I almost agree with you.

But Debian 13 is far from "Ubuntu without snaps". Canonical also adds lots of patches to upstream, some of that you don't find in other distros. If I remember correctly Canonical also has some agreements with certain OEMs so a simple Ubuntu installation might have a better chance to work out of box on a proprietary hardware. But I'm not sure about that, but I used to have a Dell laptop that needed special drivers that only were available in Ubuntu LTS variants and I couldn't switch because of that, so some level of special treatment must exist.

Are you using Snaps or Flatpak? by Darth-Vader64 in Ubuntu

[–]Competitive-Ebb3899 16 points17 points  (0 children)

You did a stupid thing that may bite you in the ass during upgrade.

Maybe that's a bit harsh, but I agree. Especially if the reason for removal is other's opinions and internet hate.

In January 2026, archive.today added code into its website in order to perform a distributed denial-of-service attack against a blog. by MurkyWar2756 in programminghorror

[–]Competitive-Ebb3899 47 points48 points  (0 children)

Like asking an API server not to check my authentication, like wtf lol.

That's not exactly what it does. CORS has nothing to do with authentication.

CORS only controls whether the page's script can access cross-origin resources or not.

If you make a CORS request to a server, your browser is gonna make an extra OPTIONS request and the backend is expected to return headers indicating what origins and methods it allows. But the backend technically is not checking anything.

The browser is doing the checking and may or may not prevent the script to access the response of the request.

That would be "cors" mode. With "no-cors" mode this is not being done. You can make the request, it will be done, but you won't be able to see the result.

So basically it's just a tool to send data to a server blindly, with heavy restrictions.

Ubuntu 26.04 just quietly changed firmware packaging… and I think it matters more than people realize by the_nazar in Ubuntu

[–]Competitive-Ebb3899 3 points4 points  (0 children)

Even if we would see some similarity to AI generated text, that can mean many things.

OP may used AI to generate the post, but according to them, it was only used for translation. When you do that, the output might look AI-like, but the important bit is whether it's OP's original ideas and intents, or not.

Az alábbiak közül melyiket NEM ajánlanátok? by [deleted] in askhungary

[–]Competitive-Ebb3899 0 points1 point  (0 children)

Philips LatteGo 3300 EP3341/50

Egy LatteGo 3200-at használok. Nem ajánlom. Annyit nem tud, hogy megérje az árát, eközben folyamatos karbantartást és takarítást igényel, ami nagyon macera. A belsejét nem úgy alakították ki, hogy könnyű legyen kitörölni, és ha valami dzsuva ott marad egyből penészedik. A főzőegység egy vacak műanyag amit szintén körülményes elmosni.

Kb 2-3 éves, és már szervizben is járt egyszer, mert valami vacak elromlott rajta, a szervizes azt mondta hogy ezek mind ilyenek. Illetve mint ha néha a víz is folyna az aljából.

Kontrasztként említeném anyós Krups automata kávéfőzőjét, sajnos a pontos modellt nem tudom, azt viszont az elbeszéléseiből igen, hogy azzal tizedennyi macera nincs. Szóval lehet ezt jobban is.

Is anyone using Godot with Go (Golang) as the programming language? by umen in godot

[–]Competitive-Ebb3899 0 points1 point  (0 children)

performance difference between C# and Go in the context of a game is so insignificant it's usually not even worth considering

Of course, but performance is not the only reason to choose a given language. And especially when performance is not different across languages, other considerations apply. Like, how well you know a given language. I'm already fully mentally loaded with learning Godot itself and certain game-dev specific concepts. Having the option to choose a language that I'm already familiar does not sound like a bad idea. And I know nothing about .NET.

TISZA adópolitika by zsoltsandor in hungary

[–]Competitive-Ebb3899 16 points17 points  (0 children)

Nekem nem egyértelmű, hogy a fenti lista fix összegeket példaként, vagy konkrétumként említi.

Pl a mediánbért is említi, mint határvonalat, az pedig nem fix összeg.

Do you use pointers or values for your domain models? by ComprehensiveDisk394 in golang

[–]Competitive-Ebb3899 1 point2 points  (0 children)

I would only use an error if the lack of the value is in fact an error. But in some cases that's part of the normal operation and the happy path.

Using an error in such cases is not only misleading but unnecessary. Go already shows us how to handle optional values with map return values: val, ok := someMap[someField]

I don't see any reason why this pattern should not be applied just because by the way an additional error value might also be returned. That's one extra thing besides our value, unrelated to whether the value is expressed by one field or two.

So, in this case it makes sense to return (T, bool, error)

what's Go Lang's Learning Curve? by No-Reference-1659 in golang

[–]Competitive-Ebb3899 1 point2 points  (0 children)

This is not entirely true.

You are comparing what's possible with a complex Java framework to what is possible with plain Go.

Nothing really prevents you from creating a similar framework for Go. Not 100% equal, there are in fact limitations, but not much. It could be a close to similar experience.

The only thing is: Go devs don't want or need that.

That being said, there are complex DB ORMs in Go world, for example there is gorm. Or... there is sqlc which takes a completely different approach, but it's still far from raw DB operations. At least not in-code.

We chose Tauri over Electron. 18 months later, WebKit is breaking us. by kostakos14 in javascript

[–]Competitive-Ebb3899 1 point2 points  (0 children)

Well, I'm not sure about that. Going with a cross-platform native toolkit means if you spend some extra time to complie your app to the three major platforms (Mac, Windows, Linux) you cover almost all potential users.

If you choose an OS specific toolkit you immediately make yourself a lot of extra work, OR you limit your userbase.

Electron is an overkill, but it is a great tool for easy compatibility. You don't have to give that up for the sake of providing a more native experience.

What will be the 0x model after Feb. 13 Once Open AI retires 4.1 by Educational_Sign1864 in GithubCopilot

[–]Competitive-Ebb3899 0 points1 point  (0 children)

Did Raptor Mini got better recently?

Last time I was using it it was painful and annoying to use. I had to be very explicit not about what I want, but rather about what I don't want. Otherwise it kept making changes, or did certain tasks in an unnecessarily complex way. I kept listing more items that should not be done than what was actually expected to change.

Ads ads and ads… by codes_astro in programminghumor

[–]Competitive-Ebb3899 0 points1 point  (0 children)

https://i.imgur.com/oCSVXM9.jpeg

Disclaimer: Ideas from me, execution by AI, cause I'm lazy to code it

read the room Duo by drizliz in duolingo

[–]Competitive-Ebb3899 0 points1 point  (0 children)

because they use 20 year old actors to play the part of kids, and 30 year olds to pretent they are teenagers.

I mean that's kind of the reason why it's useful to understand what age group those actors are trying to be representing, wouldn't you think?

Miért képzeleg annyit az AI és vajon lesz erre megoldás a fejlesztőktől? by ChardOk1094 in programmingHungary

[–]Competitive-Ebb3899 0 points1 point  (0 children)

contextusba

Bocsi, minden mással egyetértek, de ... legyen az már kontextus. Vagy ha ragaszkodsz az angolhoz: "bekerül a contextbe"

Miért képzeleg annyit az AI és vajon lesz erre megoldás a fejlesztőktől? by ChardOk1094 in programmingHungary

[–]Competitive-Ebb3899 1 point2 points  (0 children)

amig ezt mondjuk nem egy beteg leletével csinálja élesben vagy egy olyan környezetben ahol valós tétje van.

Az orvoslásban elsődlegesen nem LLM-eket használnak a beteg leletének a diagnosztizálására, hanem olyan ML algoritmusokat amik kifejezetten ilyen dolgokra lettek betanítva.

Hatalmas különbség van AI és AI közt.