« first day (3794 days earlier)      last day (1154 days later) » 
00:00 - 22:0022:00 - 00:00

10:00 PM
I also have a vague association in my head with @cmb and gd but that might be imaginary
 
@BenMorss The GD extension from my understanding is different depending if it works with the built in GD lib which comes with PHP or if it's the external lib @cmb shoud know more about those shenaningans
 
Thanks! Would love to get in touch with any or all of those who have the experience here.
 
yeh I do know that PHP runs on an unrecognisable fork of libgd
 
ah, interesting
 
but also I think PHP is pretty much the only thing left that uses libgd for anything so they may be one and the same thing :-P
that is the sum total of potentially useful things I have to say on the subject...
 
10:01 PM
That is useful to me though
 
cmb
yep, bundled libgd never managed to be really on par with external, and external libgd is missing a possibility to use Zend MemoryManager
 
When I've used PHP, I've only used GD, not Imagick, though I know Imagick is out there too
 
cmb
if you want to introduce HEIF/AVIF support, first step would be to port these additions from external GD to bundled GD
 
It's less "libgd." and more "libgd?"
 
@BenMorss have a look at various PHP extensions to see how they look as adding a function or support for AVIX shouldn't be too complicated I imagine. See also phpinternals book or Zend's tutorial to create a PHP extension for guidances about the macros
 
10:03 PM
@Sara usnure whether regex
 
the gd function implementations do look very simple
 
cmb
indeed, shouldn't be hard to add support for new formats
 
@BenMorss #FamousLastWords
 
heh heh
 
cmb
one pain point would be support for Windows, though, since the libs woud need to be added to github.com/winlibs
 
10:05 PM
but there's more, like, what is the build process that defines things like HAVE_GD_*
 
cmb
and support for getimagetype() and friends is completely unrelated
 
See ext/gd/config.m4
 
I saw that too - it doesn't use GD at all
 
cmb
oh, it does (either bundled or external)
 
ah, thanks, @Sara
@cmb, I thought getimagetype() just looked at the bytes without using an external library, but of course it's all new to me
 
cmb
10:06 PM
yes, getimagetype() just checks the signature
you may consider to check support for WebP (latest format that was added)
 
that was also my model when I added the support in libgd
(and then I ended up having do almost everything differently)
But it sounds like there are a number of steps to do here
 
cmb
indeed, but not everything needs to be done at once :)
 
@Tiffany If it makes any difference, I just went through my elephpants and not only do I have spare purple phpWomen elephpants, I even have one still wrapped in plastic (poor thing must really be struggling to hold her breath).
 
☺️
 
cmb
note though that AVIF/HEIF support should target master (i.e. PHP 8.1) only
 
10:09 PM
That was my next question... is the next release scheduled?
 
cmb
and I guess even then many couldn't use it, because they won't have a recent libgd
 
You can get it in PHP 8.0, but you'll have to beat me in a fight to the death.
 
It would be pretty awesome if it could get into 8.0 without said lethal combat :)
I'm talking to core contributors to the big PHP CMSs
 
cmb
well, on Windows there need to be the libs, and on Linux nobody uses bundled libgd
 
@BenMorss New branches (minor version releases, such as 8.1) go GA around November, but you need to have the feature approved by Feature Freeze (typically June...ish)
 
10:11 PM
It would be neat to get this into CMSs!
 
cmb
WP still supports PHP 5.6, though :)
 
@BenMorss It's not up to the CMSs, it's up to PHP core. And our process says new minor releases only.
 
So the procedure is, get a change approved by sometime around June - and then it can be part of a minor release that happens around November?
 
@BenMorss This may be of interest to you: wiki.php.net/rfc/howto
before June. Feature freeze is a deadline, not a target. :)
 
ok, thanks for all of this
 
10:13 PM
Getting approval for this should be pretty non-controversial.
 
I will try to be extremely polite, too
 
cmb
IMO don't need RFC; PR should be sufficient
 
Getting someone to do the implementation (assuming you aren't the one doing it) is mostly a matter of poking someone into interest in the topic. :)
@cmb Fair, this actually falls below the RFC threshold.
 
cmb
well, GIF actually is a recursive acrynom meaning GIF is fine ;)
 
But he will need the windows guy to sort out the library update. I hear that windows guy is SUPER unreasonable.
 
cmb
10:15 PM
as are all Windows guys :P
 
as is Windows itself
 
Tell me about it, I work with one.
I'd ask if you ever worked with him, but he was on SQL Server, so probably an unrelated vertical to yours.
 
Looking at the changelog, I see that 8.0.x releases involve bug fixes and the like, not adding new functions...
 
OMFG There's a PHP 8 elephpant! I NEED: elephpant.me/storage/elephpants/56-the-joker.jpg
@BenMorss Right. New features go in minor releases (the second number), so 8.1.0 could have it.
8.1.0's feature freeze being early this summer, and final release of 8.1.0 being around November.
 
got it!

Of course I'm all excited about finishing this libgd PR and getting AVIF support out into the world... but mostly now I'm pretty thrilled about the idea of getting to contribute something to PHP itself
 
10:22 PM
We (roughly) follow semver: semver.org
 
When I came back to programming after a sojourn doing music, PHP was the first new language I learned, and I just thought it was so cool
 
:D
 
Sorry to wear my heart on my sleeve like that
 
Not at all. Most of us have very fond memories of coming to PHP from various backgrounds (some deveng related, some not).
Myself, I'm a retired lamb gelder.
 
Reading num_rows property on unbuffered result should throw an error ・ MySQLi related ・ #80842
 
10:28 PM
lol
I also used to be a town crier
 
@Girgias I've just written the v0.1 of wiki.php.net/rfc/internal_method_return_types :)
 
@MateKocsis Yay :D
 
So, @Sara, @cmb, what's the best way for me to proceed here? I can start looking at this myself - or is there a nice way to try to inspire someone else to work on it? Or to collaborate?
 
cmb
10:48 PM
a good start might be to provide a PR to incorporate the AVIF/HEIF support into the bundled GD (without even adding some PHP functions); that stuff would be unused, but keeping bundled GD in sync with external is a Good Thing anyway
 
Sounds good!

Is there a guide to how to build the bundled GD?

At first glance it looks like a subset of the main library.

Or, can I ask you for a bit of guidance here in a few days?
 
@PeeHaa Started streaming this new game, Valheim this morning. About to do part 2 now. You might like it. And... it's multiplayer!!
 
cmb
@BenMorss I think configure --enable-gdshould use the bundled GD (unless you pass with-external-gd)
bundled and external libgd have diverged a long time ago
keeping up with changes to external libgd is somewhat hard (and has been neglected for a few years, I'm afraid)
 
@MateKocsis one can use the attribute for purely userland classes, right?
 
11:03 PM
ok, I'll copy the relevant files over and will give this a try this week!
if (when) I get stuck, is this a good place to reach you?
 
cmb
11:20 PM
@BenMorss yes; you can also ping me on the PR (cmb69)
 
@MateKocsis not worth a mailing list post, but I don't think E_STRICT is actually used for anything any more, so you might want to pick a different severity
 
I think that's the point because it's not used anymore
 
it was explicitly removed though: wiki.php.net/rfc/reclassify_e_strict
re-adding it for this seems odd
 
@cmb cool, thanks
 
There we still some E_STRICT in PHP 7.3, (or was it 7.4) because I removed the last usages of them
I think the problem with the previous usage of it, was that many things were shoved into that severity when they didn't even deserve a diagnositc, or were outright bugs that should have been warnings all along
 
11:24 PM
but why is this any different?
in fact, given that the proposal is to make it an error in 9.0, isn't it precisely what E_DEPRECATED is for?
 
Personally I would prefer an E_WARNING, but I can see this being way too noisy because prior to PHP 7.4 you couldn't even add the return types
E_DEPRECATED is inapproriate here IMHO, because you're not deprecating the methods, or whatever, you're asking people to add type information which couldn't be added more than a year ago
 
well, you're deprecating the functionality
 
And even then could have been wrong due to adjustments made in PHP 8.0
What "functionality" it is outright a "bug" IMHO to have incorrect return signatures, even worse than having none tbh
It's not a feature
 
then E_NOTICE, or E_WARNING, or whatever
E_SPECIAL_SNOWFLAKE_THAT_DOESNT_WANT_TO_PLAY_WITH_THE_OTHER_CONSTANTS :P
 
So it should be IMHO either E_WARNING or E_STRICT just for the sake of not flooding and possibly breaking every current library
 
11:29 PM
if anyone runs an error handler that makes E_WARNING break their production builds, that's their problem
 
eeeesh like I said I agree but then practicality so shrug
 
I do think those constants could be smarter - E_DEPRECATED isn't really a severity anyway, more a category, so should probably be raised as either E_NOTICE & E_DEPRECATED or E_WARNING & E_DEPRECATED
 
Btw @IMSoP I've changed the RFC and implementation to not suppress diagnostics anymore when using @<class>, also @ only suppresses Exceptions now and not Throwable (as I think Error type exceptions shouldn't be that easy to suppress)
 
ah, cool
 
@Girgias Yes! And I only mentioned the TentativeReturnType attribute as future-scope, but actually I've implemented it (albeit calling it as OptionalReturnType). So the exact same mechanism could be used for userland methods as what the RFC proposes for internal ones.
 
11:33 PM
I've been pondering error migrations more, but not come up with anything super clever yet...
 
@MateKocsis Might want to specify that, and/or give an example with a userland class
 
anyway, apologies for not seeing the note about E_STRICT on first reading and jumping in all guns blazing; I should get to bed and stop telling people they're Wrong on the Internet
 
@IMSoP NGL, I thought about this for basically 6months, when I impelmented the throw_on_error declare thing which TCM paid me for and was like... that doesn't seem like a viable long term solution
 
@IMSoP So as George wrote, I explicitly chose E_STRICT because its unused - so that people can treat them separately from everything else. But if the general sentiment is that E_DEPRECATED is preferred, I'm also ok with that.
@IMSoP These attributes are inspired by Symfony's approach that was mentioned by Nicolas. :) I'm not super convinced that we really need TentativeReturnType, but if people consider it useful, then I'm ok to also include it in this or a new RFC.
 
00:00 - 22:0022:00 - 00:00

« first day (3794 days earlier)      last day (1154 days later) »