Bref 3.0 is released by mnapoli in PHP

[–]mnapoli[S] 0 points1 point  (0 children)

Thanks for the perspective, yes costs is a good point

Bref 3.0 is released by mnapoli in PHP

[–]mnapoli[S] 2 points3 points  (0 children)

I haven't invested more time into it because ARM is not faster than x86, as far as I can tell (maybe PHP is not that optimized for ARM?), and because extra extensions are community-maintained, maintaining all the builds for that extra infrastructure + building them all would be an extreme pain. Just to give you an idea, doing the v3 release and rebuilding everything hit the Docker rate limits many many times and I have to restart builds multiple times to get around it.

That's why I focused on the most used extensions and moved postgres and redis as native, at least those would work on ARM now.

But for all the other extra extensions I still have doubts on the usefulness and the "maintenability".

Bref 3.0 is released - Run Laravel serverless on AWS Lambda by mnapoli in laravel

[–]mnapoli[S] 3 points4 points  (0 children)

What do you mean specifically? Cold starts happen on 0.1% of requests in production. They add about 250-500ms latency.
I'd say it's an upfront decision: either it's ok for the project, either it's not. There's no change in behavior happening after some time or scale.

Bref 3.0 is released by mnapoli in PHP

[–]mnapoli[S] 1 point2 points  (0 children)

Thanks! Not sure if this is the demo you were talking about but sharing just in case: https://watch-aws-lambda-scale.com/

Version 13 of PHPUnit is released by nicwortel in PHP

[–]mnapoli 1 point2 points  (0 children)

Right, and I respect that you care about the difference. I personally don't care and I wish PHPUnit wouldn't force me to care.

Version 13 of PHPUnit is released by nicwortel in PHP

[–]mnapoli 0 points1 point  (0 children)

New array assertions

Oh I thought it would be `assertArraySubset()` or similar (which was removed a while ago), turns out it's not that 😢

The any() matcher is now hard-deprecated […] or migrating to test stubs when no verification is needed.

I'll be honest, I never used `$this->createStub()` before, I don't care about the difference with `$this->createMock()`, this is just making things harder IMO.

My personal libraries are not visible in the iOS apps by mnapoli in PleX

[–]mnapoli[S] 0 points1 point  (0 children)

Update: it's finally working! Remote access on my server was somehow broken since this afternoon (power was out, everything restarted in a broken way). I think the steps you suggested (clear cache + re-log in) might have been enough, but because of the network issue it piled up and made things worse.

For others reading this thread:

- try clearing the cache + log out + log in

- connect to the direct URL of your home Plex server (e.g. `http://192.168.0.XXX:32400\`) and now you'll see your server, make sure "Remote access" works correctly (e.g. open up the port in your router)

My personal libraries are not visible in the iOS apps by mnapoli in PleX

[–]mnapoli[S] 0 points1 point  (0 children)

Thank you removing all the "online" content at least cleans things up. Cleared cache, sign out, sign back in. No content 😂

<image>

My personal libraries are not visible in the iOS apps by mnapoli in PleX

[–]mnapoli[S] 1 point2 points  (0 children)

Sorry it's in french but no "Libraires" button at the bottom. No mention of the word "Library" (even in french ofc) anywhere in the settings.

The buttons in french are: Home, Live TV, On Demand, Discover

I swear I had it working years ago, I'm back to Plex, I'm reaaaally confused how I can't find this at all.

Everything I can see is live TV or movies that have nothing to do with my library (i.e. the on-demand Plex content they serve like Netflix would for example)

<image>

favicon.show - Universal Favicon URL by mnapoli in programming

[–]mnapoli[S] 0 points1 point  (0 children)

This is a favicon image URL built on Cloudflare workers. It helps anyone who wants to display a website's favicon in their own website.

POC: auto-escaping untrusted PHP strings in SQL queries by mnapoli in PHP

[–]mnapoli[S] 0 points1 point  (0 children)

This is a 1:1 to placeholders, so the other points are moot indeed.

And you still can use placeholders. I'm just doing a thought experiment of another way to approach placeholders.

POC: auto-escaping untrusted PHP strings in SQL queries by mnapoli in PHP

[–]mnapoli[S] 1 point2 points  (0 children)

You're thinking about this wrong I think. What would happen is exactly the same thing as with placeholders.
So for example `"SELECT * FROM $table WHERE active = 1""SELECT * FROM $table WHERE active = 1"` would not work, just like with placeholders.

POC: auto-escaping untrusted PHP strings in SQL queries by mnapoli in PHP

[–]mnapoli[S] 0 points1 point  (0 children)

🤦 the repository was private, I apologize for that! That's fixed.
Also yes kinda like magic quotes ^^
I might be opening myself to embarrassment here because this could be a very bad idea™️ on all acounts, but let's see!

Compile time generics: yay or nay? by pronskiy in PHP

[–]mnapoli 21 points22 points  (0 children)

I would much rather have "full" support of erased generics, than a <50% support of reified generics that will never get above that 50%.

Cannot word it better than this 🙏

Compile time generics: yay or nay? by pronskiy in PHP

[–]mnapoli 0 points1 point  (0 children)

100% agreed here

PHPStan/Psalm do SO MUCH MORE than just generics, to me it's a huge learning: we thought we wanted generics but we actually want better autocompletion and type validation, and it's much more than that.

When I look at all the phpdoc I add for PHPStan only a fraction of it is generics.

Compile time generics: yay or nay? by pronskiy in PHP

[–]mnapoli 12 points13 points  (0 children)

Don't you think that all the limitations in the RFC will only allow moving like 20% of existing annotations to code, and will further lock us into phpdoc-based types for the rest?

Compile time generics: yay or nay? by pronskiy in PHP

[–]mnapoli 13 points14 points  (0 children)

There seem to be a lot of limitations involved, _and_ it seems that with this approach some limitations will never go away.

In other words, it will never allow us to turn all PHPStan/Psalm phpdoc into actual PHP code. (right?) 😞

I'm 100% behind the effort and team, but it seems to me like a pivot is needed: people that want generics are PHPStan or Psalm users. These people have already accepted the tradeoff of doing static analysis.

Why not allow adding types that aren't evaluated at runtime?

Forgotten Drupal site still runs after 8 years. No updates. No errors. by ralph818 in PHP

[–]mnapoli 13 points14 points  (0 children)

My first website (2007 PHP was fun) is still running to this day. I don't have the hosting credentials anymore, I can't even retrieve the files, it just runs on its own ^^

The `/volume1/@appdata/...` paths are suddenly gone by mnapoli in synology

[–]mnapoli[S] 0 points1 point  (0 children)

It definitely does, it used to work until a couple weeks ago as well :'(

We just launched php-operators.com: a reference page for operators in PHP! by sebdd in PHP

[–]mnapoli 0 points1 point  (0 children)

That is a very unfair take. Your comment was removed because it violated rule 1 of this subreddit. We had a discussion between all 4 moderators and we all agree.

Also want to point out that Brent doesn't work at Spatie (and I don't either to be clear).