@theseer@phpc.social avatar

theseer

@theseer@phpc.social

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

Skoop, to random
@Skoop@phpc.social avatar

Phun with PHAR: I try to get PHPStan up and running with extensions, but it seems impossible to make PHPStan PHAR work with extensions.

I don't really understand why extensions don't work with the PHAR. It should not really be an issue, right?

theseer,
@theseer@phpc.social avatar

@Skoop The problem is that PHStan for no apparent reason prefixes (using phpscoper) all the classes in the phar thus having no means to have an extension find the relevant classes.

theseer, to random
@theseer@phpc.social avatar

Ach Accor, wie schwer kann es sein?

theseer,
@theseer@phpc.social avatar

Scheinbar sind Sonderzeichen nicht gleich Sonderzeichen: Ein Komma oder auch ein backtick sind scheinbar sehr böse..

theseer, to random
@theseer@phpc.social avatar

Is it just me or is getting worse by the day?

I'm runnig 2024.1 (Build -241.14494.237, built on March 27, 2024) but have to constantly restart the IDE to fix bizarre errors like PHPStorm claiming a property or parameter isn't used while highlighting the very use a line later, inconsistently resolving asserts with instanceof checks - e.g. claiming a method doesn't exist in the class referenced in a different assert and not seeing a parameter that is clearly there...

PHPStorm claiming a parameter is missing that is clearly there..

theseer,
@theseer@phpc.social avatar

@michael Yeah, noticed that just deleting the line and repasting the very same code sometimes fixes it.

It's beyond me, why that even works ;)

Schrank, to random German
@Schrank@phpc.social avatar

TIL that https://github.com/phar-io/phive is part of @ddev 😳 How AWESOME is that!? <3

cc @theseer

theseer,
@theseer@phpc.social avatar

@Schrank @ddev I didn't know either.

Very nice 😄

Glad it's still helping a lot of people even though it's suffering under neglect currently 💔

theseer, to random
@theseer@phpc.social avatar

I just got pointed to this awesome blog post: https://blog.glyph.im/2024/05/grand-unified-ai-hype.html

Thanks @sebastian, couldn't agree more... Not sure if the post gives hope or increases the desperation.

theseer, to random
@theseer@phpc.social avatar

Is it just me or is anyone else running their own mailserver experiencing a lot servers being blocked by zen.spamhaus.org currently that one would assume not to be considered offensive?

Like github.com, outlook.com or google/gmail?

theseer,
@theseer@phpc.social avatar

@bobmagicii thanks for the pointers, i didn't have any issues sending mails. My trouble was receiving them.

As it turnwd out and what I already feared, entirely my fault. I tried using spamhaus' RBL via public resolver which is explicitly not supported.

heiglandreas, to random
@heiglandreas@phpc.social avatar

I hate VPN!

It never worked out of the box for me. There are soooooo many moving parts.

Debugging is difficult.

And it's always the clients fault...

theseer,
@theseer@phpc.social avatar

@heiglandreas Interestingly, the VPN in question works on mac, windows and linux all over the world ;)

Skoop, to random
@Skoop@phpc.social avatar

Is my search-fu leaving me, or is there no PHAR for Rector?

theseer,
@theseer@phpc.social avatar

@Skoop @heiglandreas @sven Why not talk to Thomas about it? :)

If we need to enhance phive to support this, I can do that..

theseer,
@theseer@phpc.social avatar

@Skoop @heiglandreas @sven Okay, that's a lame excuse he wrote there, tbh.

There is no need to "manually update files".

We could also consider creating a phar-io update wrapper component that allows for an easy "--self-update" process to be included.

afilina, to random
@afilina@phpc.social avatar

This looks suspiciously similar to azjezz/psl, just with a different API. It even has the same name: PHP Standard Library.

The PHP community would be better if devs worked together instead of copying and re-branding someone else's work. Credit to azjezz for the original PSL.

theseer,
@theseer@phpc.social avatar

@afilina At least the screenshot shows a perfect example of adding pointless complexity rather than addressing the design flaw of using implicit APIs with magic strings.

Crell, to random
@Crell@phpc.social avatar
theseer,
@theseer@phpc.social avatar

@Crell The thing that I see happening a lot is that things are made configurable that aren't actually configurable - for instance because there's only one implementation to choose from - or should be represented by code rather then being generalized into something requiring more configuration than actual code would have...

theseer, to random
@theseer@phpc.social avatar

So, @phpukconference, is it long enough after the 2024's edition to start begging for an Eddie? ;-)

What does one have to do?

asgrim, to random
@asgrim@phpc.social avatar

I'm gonna be on a live stream on Friday!!! Will be chatting about the new PECL replacement tool, PIE 🥧 that I'm working on...

https://www.youtube.com/watch?v=uWsGDUCxbT0

theseer,
@theseer@phpc.social avatar

@afilina you do? Feel like helping with documentation on docs.templado.io ?

heiglandreas, to random
@heiglandreas@phpc.social avatar

Question for the @phpstan pros:

What am I missing here?

final class stdClassList
{
/** @var array<int, stdClass> */
public readonly array $classes;

public function __construct(stdClass ...$classes)
{
$this->classes = $classes;
}
}

https://phpstan.org/r/5b86ba21-7486-4eb5-bccf-1ebd4327829e

PHPStan reports "Property stdClassList::$classes (array<int, stdClass>) does not accept array<int|string, stdClass>." but I would expect that $classes will always be array<int, stdClass> without any string-keys

theseer,
@theseer@phpc.social avatar

@shochdoerfer @heiglandreas @phpstan The problem is the variadic.

If you destruct an associative array when passing the key is not an int.

theseer,
@theseer@phpc.social avatar

@shochdoerfer @heiglandreas @phpstan The variadic doesn't care. All phpstan is telling you that if you do new StdClassList( ...['a' =&gt; new StdClass]); the key "a" is kept in the params array. And does not magically turn into an int. If you'd do $this-&gt;classes = array_values($classes); the problem is gone.

theseer,
@theseer@phpc.social avatar

@heiglandreas @shochdoerfer @phpstan You didn't ask whether or not the behavior of PHP makes sense though ;-p

heiglandreas, to random
@heiglandreas@phpc.social avatar

So I seem to be in a lonely path now.

I finally started the project to write a small purpose-driven FTP server that accepts a file and sends it to an email address.

I decided to use ReactPHP for that.

FTP is.... challenging. On the server side at least.

Why? I have a scanner that can scan to FTP. But I need to send the files via email. And the FTP server I so far used can't send emails from new files. So what's the natural approach as developer?

How hard can it be....

🤪😱

theseer,
@theseer@phpc.social avatar

@heiglandreas systemd path service?

derickr, to php
@derickr@phpc.social avatar

Today we welcomed Sir Humphrey to our herd!

theseer,
@theseer@phpc.social avatar

@derickr can you get me one aswell? ;-)

theseer,
@theseer@phpc.social avatar

@derickr Ask someone? :-D I'm willing to pay haha

theseer,
@theseer@phpc.social avatar

@Exakat why don't you just bring some to confoo? ;-)

theseer, to random
@theseer@phpc.social avatar

Sooo, anyone already around for Confoo? 🙂

b_viguier, to php French
@b_viguier@phpc.social avatar

TIL: in , you can create a new instance (not a clone) of an object from an existing instance with the following syntax:

$a1 = new A();
$a2 = new $a1();

Very convenient with anonymous classes! Just a bit confusing if you expect $a1() to call the A::__invoke magic method (because it won’t)

theseer,
@theseer@phpc.social avatar

@sarah me neither :-)

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