@djumaka@phpc.social
@djumaka@phpc.social avatar

djumaka

@djumaka@phpc.social

I like PHP, processes and automations. I help people work smarter and overcome their flows. I believe tech can finally be used to take out the boring stuff. I love blues, BEER and hard rock, outdoors, dogs. I'm fluent in my ADHD :) I am on tootfinder.

This profile is from a federated server and may be incomplete. Browse more on the original instance.

djumaka, to random
@djumaka@phpc.social avatar

I just figured out, that I can perfectly work on a standing desk with the baby in my sling, me wrapped like a mummy. Even though I bought the cheapest standing desk mechanism and made the top from an old plywood with a foil on it, it starts to be the best thing I've bought recently. Given the price of ~150EUR in total (if you have the top surface it is some 45 EUR less) I have no idea why companies don't buy these on mass scale.

djumaka,
@djumaka@phpc.social avatar

@oliver a friend of mine even shared that a smooth treadmill underneath can get you into walking without noticing. A bit too far for me. But as you mentioned not everyone can stand for long. But it is perfect to stick up for about an hour before and/or after lunch. The baby stuff was a bonus...

doefom, to php
@doefom@mastodon.social avatar

8.4 introducing "Property Hooks". This means you will be able to hook into the default read and write behavior of your class properties. The design also allows for more hooks in the future. Really looking forward to this one!

Read more about this feature in the RFC:
https://wiki.php.net/rfc/property-hooks

djumaka,
@djumaka@phpc.social avatar

@doefom looks interesting. It might be a solution of the long discussions about getters and setters and their role/usefulness/correctness.interesting one.

grmpyprogrammer, to random
@grmpyprogrammer@phpc.social avatar

Some light reading for this weekend from @cate — my pre-order via Amazon came in (I hope they don’t rip you off on royalties for it Cate!)

djumaka,
@djumaka@phpc.social avatar

@grmpyprogrammer definitely will look for your feedback. Looks interesting.

djumaka, to php
@djumaka@phpc.social avatar

Guys I need some helping hand. I need some good reading (book/article) on the proper way of writing OOP. I gave a project where we use classes, but they are more used as a package if functions then working like objects. Like a class of only statics, passing around IDs not the real objects of data (this sending SRP down the drain), arrays, generally functional programming with extra steps. I'd fancy even a discussion as I want to slowly explain all that to my teammates
TIA

Crell, to react
@Crell@phpc.social avatar

This article uses as it's main example, but it applies to , , even just a much. I say that as a recovering Drupal dev who used to use the standardization argument.

Greedy management is the reason we can't have nice things.

https://www.baldurbjarnason.com/2024/react-electron-llms-labour-arbitrage/

djumaka,
@djumaka@phpc.social avatar

@Crell @grmpyprogrammer that goes far too deep into the management wastelands of ignorance an brings in "politics" as a lot of costs are hidden and easy to neglect. article is nice from the deleploer craftsmanship POV, but is nothing new under the sun. I like it..

grmpyprogrammer, to random
@grmpyprogrammer@phpc.social avatar

My two current talk ideas:

  • A Grumpy Programmer’s Guide To PHP Design Patterns
  • Make your PHP UI’s dynamic with HTMX

Hopefully the folks at CascadiaPHP will like them

(I count as a US speaker because I can fly from Detroit)

djumaka,
@djumaka@phpc.social avatar

@grmpyprogrammer strangely enough I didn't hear of htmx before you mentioned it here...

djumaka, to php
@djumaka@phpc.social avatar

Dealing with legacy code is a good excuse for me to go "it's already broken". An old framework, crappy project development, made it a pile of "it works". This combined with the constant need to fight for any idea of innovation or even keeping common practices, makes it so very hard to keep my motivation and creativity up... thanks God my brain can keep a bit of motivation out of random stuff...

bobmagicii, to random
@bobmagicii@phpc.social avatar

two toasted finger tips later a network hostname has been selected.

djumaka,
@djumaka@phpc.social avatar

@bobmagicii the only thing I bothered naming was the mikrotik router in the basement, by the name "uglywhitebox" because at that time they only had that colour, and it is indeed ugly.

djumaka, to php
@djumaka@phpc.social avatar

We have a system that publishes small data to several DBs (separate schemas on same server) for usage by instances. Someone though he can user a single transaction for all that :) Well we now use X separate transactions after we saw that "strangely" some data is not right. I know this smells of a bigger architectural issue, but I guess I am not the only one that needs to push data to several DBs... (FYI it's all in Yii2, not that it matters)

djumaka,
@djumaka@phpc.social avatar

@alessandrolai data is not exactly the same. Some values are recalculated for each instance, to simplify. But in general you are correct - very similar data on many places smells a bit.

sebastian, to random
@sebastian@phpc.social avatar

We were so engrossed in our discussions and busy with mob programming that we forgot to take photos during the code sprint.

That means no photos for https://phpunit.de/code-sprints/march-2024.html 😞

djumaka, (edited )
@djumaka@phpc.social avatar

@derickr @sebastian can become a ads campaign motto - "unlike this fake photo, our work actually makes sense" :)

djumaka, to php
@djumaka@phpc.social avatar

I get a rash when I see trait used in a project. I guess it may be fine to setup similar fields structure among different models, for example, but seeing way to many misuse of traits to hide repeating code or to imitate OOP made me allergic to it. Do you have any good reason for using traits, actually?

djumaka,
@djumaka@phpc.social avatar

@ramsey @grmpyprogrammer basically it solves one other OOP issue of "horizontal" or "complex" inheritance... my struggle came as I read in several places as traits are actually a hidden repeating code and my poor brain literally scratched that rule with a key on the wall and claimed it as "evil".

djumaka,
@djumaka@phpc.social avatar

@ramsey isn't some "composition" stuff better for this? Or as always it comes to "is it worth the work" vs "gain"? And I gain DI/composition is not a panacea.

djumaka, to opensource
@djumaka@phpc.social avatar

I'm so used to legacy projects where structuring it properly and adding tools and best practices is a mission impossible without a revolution, that I'm looking around for a good project where I can see things done well. Do you know any? I recently saw "/kbin" repo and I liked it so far, not that I've dug deep. I may event try to contribute a bit (as scarce as my free time is anyways).

djumaka,
@djumaka@phpc.social avatar

@symfonystation yup, that caught my attention at start, TBH. I literally said to myself "Finally, someone that may be knows what he wants to do."

djumaka, to php
@djumaka@phpc.social avatar

I'm looking at different articles on "why we shouldn't use exceptions in business logic". I kind of can't fully grasp it. In my head, if a function meets data that it can't work with, then it's an exception to the call you made "doThis()". On the other hand exceptions should just inform the caller of a strange case...
But the thing that bugs me is that most people explain why it is not good, but not a single logical and good example of how to do it the other way round was given.

djumaka,
@djumaka@phpc.social avatar

@Crell Thanks for the links, very interesting ones. Indeed there is a very big gap in that area, ideally around having an agreed approach.

djumaka, to random
@djumaka@phpc.social avatar

Something that AI assistants are good at is... statistics. I just saw an abomination of array_reduce+array_merge of a field. I know there is a simpler, one-liner for that, but it was just my brain not collaborating, so a simple "plain text" question brought the "statistics" machine to get me the answer that was abusively simple.

djumaka, to random
@djumaka@phpc.social avatar

I must have something wrong with me, if I'm spending a fun evening a day before NY Eve coding and having fun with unit tests, instead of sleeping or something festive, IDK. Wife/kids are sound asleep, so I guess this is a bit of a me-time...

djumaka,
@djumaka@phpc.social avatar

@oliver oh that ship hassailed long ago :) I just got to bed 2AM as I was playing writing tests for classes I'll restructure anyways :)

djumaka, to random
@djumaka@phpc.social avatar

I've just joined the PHPc matrix chat server. Not much of an action in there...

djumaka, to php
@djumaka@phpc.social avatar

Reading the Jetbrains dev state report, I saw this quote "I find it very interesting that 31% of developers don't write tests for PHP. This has gone down from 33% last year, but it's still one-third of respondents who don't write PHP tests. I guess they like to live life on the edge!". In ecosystem testing is still a nonsense. This general cowboy mindset is may be one of the reason PHP is neglected all-over.

djumaka,
@djumaka@phpc.social avatar

@grmpyprogrammer do you mean they write tests but don't say it or they lie they do tests...?

djumaka,
@djumaka@phpc.social avatar

@grmpyprogrammer oh yes. Half of them lie that they do it, half think that they do it. A lot of people don't know neither how to test, nor how to write testable code. And combined with the lack of knowledge how to write any tests at all, and here we go.

  • All
  • Subscribed
  • Moderated
  • Favorites
  • JUstTest
  • GTA5RPClips
  • DreamBathrooms
  • khanakhh
  • ngwrru68w68
  • Youngstown
  • magazineikmin
  • mdbf
  • slotface
  • thenastyranch
  • rosin
  • kavyap
  • tacticalgear
  • tester
  • provamag3
  • osvaldo12
  • cubers
  • ethstaker
  • everett
  • Durango
  • InstantRegret
  • normalnudes
  • Leos
  • modclub
  • anitta
  • cisconetworking
  • megavids
  • lostlight
  • All magazines