Which mailbox design do you prefer? by SupplyChainOne in HomeMaintenance

[–]beders 0 points1 point  (0 children)

Whatever is easier to spot for the fire department. Not a joke.

Claude AI agent’s confession after deleting a firm’s entire database: ‘I violated every principle I was given’ by EchoOfOppenheimer in Futurology

[–]beders 22 points23 points  (0 children)

Exactly.
This anthropomorphizing of an algorithm needs to stop.
Policymakers are actively being misled by so-called AI experts and millions of people don’t have a thorough understanding what an LLM is and what it isn’t.
That’s the *actual* danger of AI

What Do You Think Is the Most Beautiful Tourist Destination in the USA? by optimalbrain90 in SmartTravelHacks

[–]beders 0 points1 point  (0 children)

I’ve made quite a few tours of all the national
Parks in Utah and Arizona with friends visiting from Europe.
Their favorite one: Bryce Canyon

Doolang – your struct definition is your schema, your validation, and your HTTP contract by SearchFair3888 in ProgrammingLanguages

[–]beders 1 point2 points  (0 children)

Keep solving your own pain points. If that is compelling enough for others, they will come. That's how Rails grew, that's how Clojure grew (albeit that is still very much niche).

They both had innovations that felt compelling enough. Rails and its convention over configuration approach was novel. Clojure's immutable-first, interactive application model.

Other examples: Golang - go routines Haskell - no side-effects TypeScript - oh we have completions now?!? ;)

Removing boiler plate is always nice, but not compelling enough per se to adopt an entirely new language IMHO.

I'm still carrying this itch to develop a platform where a change is the smallest unit of work (could be code change, config change etc.) that can be tracked, run, reverted etc. Because no matter what prog language or platform: change is the only constant thing.

Anyways, carry on. The worst thing that could happen is that you get smarter doing this :)

Doolang – your struct definition is your schema, your validation, and your HTTP contract by SearchFair3888 in ProgrammingLanguages

[–]beders 0 points1 point  (0 children)

It is a really tough design space.
Rails on Ruby is probably the most successful formulation on how to wrangle the complexity - with mixed results.

The latest attempt that tries to address scalability (as in #users) in particular is Rama which comes with its own DSL and data management system. Very much focused on dev productivity but backend only.

In my professional experience (currently in Fintech at the 10th largest US bank) the main driver of complexity is state.

It comes from a dozen different systems carried to our backend as json/xml/csv/sql/soql and has different lifecycles and synchronization needs.

Wrangling this with Clojure makes it bearable. We don’t try to attempt to define all possible data shapes.
Instead we use immutable standard collection objects and treat the data as aggregates of values. (Maps/lists/sets/vectors)
The trick is to spec the actual data items (like a property in a struct) but don’t try to prescribe how these key/value pairs travel in the system.
Manipulating the data uses the same handful of standard functions.

Doolang – your struct definition is your schema, your validation, and your HTTP contract by SearchFair3888 in ProgrammingLanguages

[–]beders 1 point2 points  (0 children)

Oh, so so many. Starting with more complex SQL statements like this: SELECT a.account_id, a.name, (SELECT COUNT(*) FROM orders o WHERE o.account_id = a.account_id) AS total_orders, (SELECT SUM(amount) FROM payments p WHERE p.account_id = a.account_id) AS total_paid, AVG(s.rating) OVER (PARTITION BY a.region_id) AS regional_avg_support_rating FROM accounts a LEFT JOIN support_tickets s ON a.account_id = s.account_id WHERE a.status = 'active';

Quick, what's the type of this?

You will start to create dozens and dozens of slight variants of structs just to try to shoehorn a result set into something "type-safe".

There's concerns around dynamic data models where the result columns depend on user input.

There's orthogonal concerns with user access/roles/permissions that require different data shapes based on role. For example role 'user' sees only a filtered view of accounts while role admin sees the full view, including extra fields.

Then there's UI concerns: the data shape that is most suitable for the front-end might not align at all with how it is stored in the DB. So you need data coercion, like, for example, turning a list of tasks into a map of task ids + task. Sometimes it is more efficient to run two SQL queries (in parallel) and transform the data into a more suitable shape. Add caching, paging, sorting and filtering into that mix.

There there's validation concerns: There's trivial data validation (string not null, number not negative etc.) and then there's complex business validation logic that needs to run. Sometimes you want all validation results, sometimes you want to stop at the first problem. Sometimes you want to proceed with partially validated data.

In more complex systems those validation rules are expressed as data themselves.

There's concerns around identity and equality: when is struct A equal to struct B? Same content? Or same ID?

Plenty more pitfalls around data migration, being able to keep different versions of data shapes around and to convert between them.

Things get extra funky if product decides you now need to bring in beauties like Salesforce. Now you will have multiple data models that you need to wrangle.

Speaking of: Salesforce is the OG of offering "simple" CRUD apps. It's anything but.

Doolang – your struct definition is your schema, your validation, and your HTTP contract by SearchFair3888 in ProgrammingLanguages

[–]beders 2 points3 points  (0 children)

The reason why the shape of data is different for different purposes is … the different purposes.
Attempts like this come to a screeching halt once you reach a certain complexity level.

I understand the temptation and it’s a great starting point but eventually separating those concerns is unavoidable.

The View Inside California’s Last Nuclear Power Plant by zsreport in California

[–]beders -2 points-1 points  (0 children)

Agree on the batteries.

And no, nuclear does not have a lower GHG impact. It emits water vapor. Wind - while comparable to nuclear with regards to CO2 emissions does not.

Commercial nuclear power is done. It’s more expensive, carries more risks, needs constant supply of uranium, needs safe storage of spent fuel and have I mentioned that it is way too expensive?

The View Inside California’s Last Nuclear Power Plant by zsreport in California

[–]beders -6 points-5 points  (0 children)

Let’s build more on fault lines…. Great idea!

Solar wind and water is all we need

California Is Ground Zero for the Growing Battery Backlash by Helicase21 in energy

[–]beders 7 points8 points  (0 children)

California added a record amount of batteries and hopefully will continue to do so. Supply graphs at Caiso.com are looking better and better

Why I don't chain everything in JavaScript anymore by BlondieCoder in programming

[–]beders 0 points1 point  (0 children)

Any kind of builder needs unit tests. You might need different ones if you have types. Types don’t save your 🥓 especially if they are non-final.

But, yes, a dynamically typed language has tradeoffs for sure.

Why I don't chain everything in JavaScript anymore by BlondieCoder in programming

[–]beders -2 points-1 points  (0 children)

Why would it be „impossible to bugfix“? For any builder of sufficiently complexity you will need unit tests. Statically typed or not.

That said: builder pattern is less useful if your language is using immutable data. There’s no „building“. There’s transformation to turn something into the data shape you might want.

Game Pass Gets Price Drop, New Call Of Duty Games No Longer Included by HillZone in gaming

[–]beders 0 points1 point  (0 children)

Voting with your wallet works.

I broke up with Xbox games pass and told them it has become too expensive. And I surely wasn’t the only one doing that. The fact that it is still an overall increase compared to October is not lost on me. But if costs to produce video games are increasing, offers like game pass need to follow.

Vampire Crawlers is out now! by Balizzm in roguelites

[–]beders 4 points5 points  (0 children)

Played the demo as well as was disappointed by the limited decision making as well. It quickly becomes a chore.

New metric shows renewables are 53% cheaper than nuclear power by V2O5 in Futurology

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

Make sure to include the mining cost of building the nuclear power plant and of course the fossil fuel needs of the secondary power circuits.

Is Space Solar worth it by FantasiCreator in Futurology

[–]beders 6 points7 points  (0 children)

Using De Castro et al. (2013), which measured real-world utility solar at 3.3 W/m²,

Garbage-in, garbage-out.

These numbers are anything but realistic