« first day (3832 days earlier)      last day (1098 days later) » 
00:00 - 20:0020:00 - 00:00

12:01 AM
I just threw a new IDontKnowWhoMostTheseRMCandidatesAreException
Is there some kind of centralised location to view their prior experience / involvement with PHP to help decide?
 
@MarkR My 1st and 2nd preferences aligned with majority so.. I expect those two to win.
 
12:39 AM
@MarkR I'm one of them :p ( S E Gmati ), you can ask me questions here if you like
 
@SaifEddinGmati What is your favorite ice cream?
 
oh, didn't expect hard questions
i would say chocolate and/or strawberry
 
I will allow it
 
@SaifEddinGmati What's your experience like with git?
 
pretty decent i would say ( 7.5/10 )?
github.com/azjezz ( for things i work on ), twitter.com/azjezz ( for things i talk about - mostly non sense )
 
12:53 AM
@cmb OK, I'm missing something in the docs on weakmap. I don't grok how the entity names line up. I had ` &language.predefined.entities.weakmap;` in the weakmap.xml file, which I believe was copied from previous files. It says that's undefined. I change it to remove the entities part, and I'm pretty sure I just got an infinite loop. :-) But everything in interfaces.xml has no entities in it. What piece am I missing here?
 
1:08 AM
@Sara So:
> Please use all your votes
I don't have to, right?
I can just vote my top 3?
If they get eliminated, it's like not voting. I'm okay with this.
 
 
2 hours later…
3:38 AM
How can we set Cookie in WordPress plugin ? anybody got any idea please
 
 
1 hour later…
4:46 AM
Can anyone help me with this issue?

https://stackoverflow.com/questions/67068861/set-user-submitted-data-in-cookie-in-wordpress-plugin
 
you are sending the cookie too late i suppose, headers should always be sent out before sending any content.

and since cookies are set via the `Set-Cookie` header, they should also be set before outputting anything.
 
@SaifEddinGmati Thank you for response. How do I set the input data to cookie. `init` hook is loaded in the beginning where as user submitted data are executed later.

Am I missing something?
 
not sure honestly, I'm not familiar with WordPress :/
 
Working with Cookies in WordPress especially WordPress Plugin seems awful :(
 
5:55 AM
posted on April 13, 2021

 
 
1 hour later…
7:23 AM
@LeviMorrison Had exactly the same reaction/question.
 
7:49 AM
@Crell got some reflection going ... probably broken still ... the only failing tests now are related to the handling of extra/variadic/named params... which I need a good few hours to figure out ... then additionally, what reflection features do we want, and what methods on the partial object itself ...
 
8:22 AM
@SaifEddinGmati fyi you need to use a different email provider for internals
 
why so?
 
Because all your mail are belong to spam
 
Basically the mailing list forwards mails under your name and ends up violating strict DMARC policy
 
is there a specific reason for this ( maybe something i can tweak? ) , or is it just because i am using protonmail?
 
8:28 AM
I doubt it's anything you can tweak on your end
It's a problem with the mailing list
 
The only way the mailing list system can solve this is if it sends the emails from itself, and ideally signs the emails (SPF/DKIM/DMARC)... but that causes other issues... on a more personal level, for emails to be sent from the PHP mailing list, you will need to configure your email server (domain) to allow the "lists.php.net" server to send emails on your behalf.
 
@NikiC which email provider classifies it as spam? It's not spam for me
 
@bwoebi Gmail classifies it as spam -- which means it's spam for everyone :)
 
well :-D
 
Huh, for me, Gmail marks emails from azjezz@protonmail.com as "important according to Google magic"
 
8:40 AM
Not for me! I don't use gmail ;-)
 
@Derick But does your email server check SPF/DKIM/DMARC... while not a fan of Google, it's fairly neutral tech that anyone could implement to (in theory) reduce spam.
 
No, it doesn't. What it does do is greylist, which is almost as good.
 
!rfc-voting
 
Doesn't work if you edit it.
!rfc-voting
 
Fair enough... suppose it depends on numbers :-)
 
8:43 AM
doesn't work either...
 
!voting
@GabrielCaruso So what are we doing with releases this week?
 
@Derick I've just sent a message to the RMs, I'll continue with PHP 8.0.4 on top of what was built during the RC week before the attack
 
I don't think we should throw out weeks of fixes
 
In that case, we'd tag 7.4.15RC1 and 8.0.5RC1 today?
 
8:51 AM
yes
Once I figure out how to run the docker container now GIT is in a different place...
 
I'll have that fun during my lunchtime. Are you talking about github.com/sgolemon/php-release?
 
a precursor, but it looks like it's alreayd using github.com, so no changes needed I think
 
okidoki. I think we should make a release with the fixes that are sitting for some weeks, and if that means to "skip" a version, let's do it :)
 
9:10 AM
Hi guys
 
@Derick @GabrielCaruso if you want a new RC can have be 7.4.17RC2 and 8.0.4RC2 (avoid skipping versions), but 7.4.18RC1 and 8.0.5RC1 is probably also fine
 
@RemiCollet was about to reply to email on RM@, we will move with new RCs to make sure the fixes that we merged in the last weeks get published
Have we ever skipped versions? {include the PHP 6 joke here}
 
going for lunch, will start the QA build this afternoon
 
9:53 AM
I'm already doing 7.4.18RC1
yeah, I skipped 7.4.0beta3 beacuse I can't count
(or spell, apparently)
@GabrielCaruso Are you done yet, or running things now?
don't want to clash
 
10:06 AM
Morning, room.
 
mornin
 
@LeviMorrison I think the reason "implode($separator, $array)" was considered better is that it matches "explode($separator, $string)"
explode can't have reversible args because they're the same type, so it was a common cause of confusion
 
10:22 AM
@Derick I'll start in a bit, I can create a 8.0.5RC1, np
 
Let me do things first then.
because I'm waiting for CI :D
 
apparently implode() could always take args in either order, but the one-arg version was added some time in PHP 4: github.com/php/php-src/commit/abc99919
 
@IM
@IMSoP glue must always be first because of type checking (Argument #2 ($array) must be of type ?array...)
 
@RemiCollet only as of PHP 8.0: 3v4l.org/hkLLn
 
yes, but keeping old depreceated order is a bad idea
as the code will be broken in the future
 
10:36 AM
I think you missed the discussion I was responding to
 
Levi was surprised it was that order that got deprecated, not the other
I was just explaining the reasoning, as I understand it
 
cmb
then he shouldn't have voted in favor ;)
 
@Derick Cool, let me know when I can push my stuff
 
I'm done - just sent the email
 
10:39 AM
Detick, have you see the comment on github.com/php/php-src/commit/… ?
 
the conversation actually started with someone trying to understand the current signature, which technically has an optional first parameter, which is a bit magic
 
I fucked up a merge it seems, because I had originally pulled from git.php.net still
we should stop allowing pulls from there
 
maybe rename the repo, so old git remote URLs are invalid?
 
@RemiCollet In general, I will not see GitHub emails, as there are just too many
@IMSoP The old remote URLs being valid is what caused that :-þ
 
the reason of my ping ;)
@Derick paste.centos.org/view/beee5992 seems fine to me...
 
10:44 AM
@Derick yes, that's what I'm saying, rename it on the server, so the URL you have in your checkout becomes a 404
or of course just delete it, if everything is happily using github now
 
@RemiCollet Where did FTP go?
 
@RemiCollet Oh, that's true, we need to merge the NEWS. Let me do that for PHP 8.0 as well
 
indeed... terribly strange
Also opcache
 
yup
 
openssl
 
10:50 AM
no, there was no openssl one
 
only test changed, to no new entry
 
11:02 AM
@Derick are you going to regenerate the tarball ?
 
cmb
11:15 AM
^ good question; I'll wait with the Windows build until this is resolved :)
 
@NikiC would it make sense to add zval_try_get_long (and other variants) so that extensions can get "strict" casts? Or just make it an RFC to deprecate non-sensical casts in userland too
 
11:35 AM
@Sara Only issue I had: github.com/sgolemon/php-release/pull/11, everything else is working as expected :)
 
11:46 AM
Looks like I'm forgetting something in the process and not signing my tags :(

https://github.com/php/php-src/tags
 
@RemiCollet No, I wasn't. It's an RC.
 
@Derick ok, make sense, thanks
 
@GabrielCaruso It tells me to do it in the instructions that the docker build thing puts out
 
@cmb see above
 
cmb
ta (already noticed :)
Windows builds for 8.0.5RC1 will take some time, since I need to update a bunch of stuff
 
12:04 PM
@Derick I sign the tarballs, never did for the tags. I'll pay attention to it next time
 
Spiffy! I think in the ideal case, we want the partialed function to be type indistingushable from a manually-written short lambda that has all the types defined correctly. That way if/when we get typed callables, they'll "just work." What that looks like implementation wise, I have no idea.

Also, tagging @LeviMorrison as he wrote the original RFC.
 
12:32 PM
@cmb So what step am I missing in my ignorance on weakmap?
 
12:53 PM
Is there any reason for using zend_string_(e)free() ?
 
@Girgias Only if your name is Dmitry
 
@NikiC Right, I was looking at converting them to zend_string_release() should I bother or not?
 
@Girgias no
I just wouldn't add calls to those myself
 
Okay okay :-)
Will look at pgsql PR one again and try to get rid of some of the useless conversions again
 
1:21 PM
you can't iterator_to_array on a generator ? 3v4l.org/bnhga
 
@ln-s yield from instead of return
Return is the coroutine return value
You never use return with value in a generator if you're not using it as a coroutine
 
yield return ...; @NikiC ?
Ah no xD I misread
@NikiC 3v4l.org/LAkWI ????
👀
well it's the same on that last example, it's still a generator
not an array
 
1:46 PM
The moment you have the yield keyword in a function (anywhere) it is a generator
 
Ah that clarifies it better
 
lol
Helo.
 
Thanks @PeeHaa
 
Oh wow
 
1:48 PM
@PeeHaa Thanks.
 
@NikiC you didn't close the PR github.com/php/php-src/pull/6863
 
@Girgias Liar :P
 
Glad I am now :P
 
@MateKocsis github.com/php/php-src/commit/… may be of interest ... I think this is what we should be doing for dynamic properties where we can't declare types right now
 
@IMSoP yes ?
 
sorry, bad paste; edited
 
hahaha
Good one Rowan
 
maybe instead of just "function", we should have "method", "classmethod", and "coroutine" keywords
$this would be illegal outside "method", and yield illegal outside "coroutine"
#AlternativeRealityPHP
 
3:09 PM
 
No, not fully. I haven't sorted out the type2 vs type3 ones yet (these tests are still XFAIL)
but mainly because I haven't figured out what the right result(s) there should be
although that RFC doesn't talk about these...
 
3:49 PM
@NikiC Noted! And thank you for the heads up!
 
4:14 PM
Does anyone know of a way I could test how a change in PHP would affect things in general, performance wise? As in, typical PHP code that's already out in the wild, rather than me trying to simply create a loop, and time that?
 
benchmark the cpu load, memory usage and time taken to process a fixed number of requests
 
web requests, to something like a WordPress install?
 
the ab tool from Apache isn't the worst place to start
 
I suspect I need some kind of PHP code that's representative of what's out in the real world?
 
well yeh that's where it starts to get more interesting :-P
there are other tools available (iirc postman has some benchmarking things built in)
 
user14697742
4:18 PM
why is fun forbidden?
 
but one of the problems is that yes, in order to effectively test a specific app, the test has to be appropriate for that app
 
Doesn't PHP have a WP benchmark?
 
however you might also think about unit testing, and other forms of testing smaller chunks of code
 
ahh... well, I think WordPress is fairly messy/complex, but it hitting the db might not be the best test (I'm looking at something that affects string concatenation)
 
rather than testing the effect of a change, you should test the change
 
4:19 PM
good point, but I worry that whatever I come up with might not be that representative.
 
but that's not easy to do if you don't already have that test infrastructure already in place
@CraigFrancis well possibly, but think about it the other way around - if you had a performance problem you'd need to identify it
 
@NikiC should we create a separate organization on Github for some of these repos (like php-cfg)? I'm happy to let it maintain under mine, but feel bad since I don't have a ton of time for it. Any thoughts on that?
 
if you test everything at a lower level it's easier to find the wider scale problem
 
True, I'm hoping to check the work with someone more experienced later... but would also like to get a rough idea of the impact now (as in, is it even worth looking any further into the change)
 
well you can see if you can craft a request that performs a meaningful test and then fire a fixed number of those at your server
that's the best "rough" I can think of
the key point is that you need a fixed test case that is repeatable and you control all the variables
 
4:23 PM
Thanks
 
have a look for "web server benchmarking tools"
it's a while since I had to do it so there are probably some much shinier free things about by now
 
I'm just not sure I could do something like this and say it's of value:

$start = microtime(true);

$k = 0; $a = 'a'; $b = 'b';
while (++$k < 100000) {
$c = $a . $b;
}

echo round((microtime(true) - $start), 4);
 
web server/web application
@CraigFrancis not really no
well if you are testing a tiny unit of code then yes, but if you are testing an app-wide change you need to make the app stretch it's legs and you need to put the server under heavy load
it's not that hard to do, but it's definitely not a thing you want to start by rolling your own
 
Just for reference, I'm trying to see what kind of impact this would have: github.com/php/php-src/compare/master...krakjoe:is_literal
 
Isn't stuff like that exactly why we have benchmarks?
 
4:27 PM
^^^
there is a test suite for that somewhere
no idea where but it will be in the wiki somewhere I imagine
 
I'm not too familiar with php internals, or whatever benchmarks are available.
 
wiki.php.net start here :-)
also someone here will know more about that test suite
 
Isn't it called bench.php?
 
sounds dangerously logical
 
huh, bench.php is oddly faster with the patch (seems wrong)... but micro_bench.php is making a difference
 
shouldnt it be considered biased as it is using hrtime inside of a function call
just saying
 
Biased to what?
They all use the call
 
Adding to the time of the test when the hrtime counter should be in the global scope instead of inside of a function call ?
unless calling a function inside of another function is the same as calling a function directly in the global scope but I don't think so
 
it's nanoseconds, if that
 
4:37 PM
still
 
the granularity of the clock on a typical system is ~14ms
(iirc)
it's a lot more than a handful of nanoseconds
 
@ln-s On top of what Random said, you can still compare it to other (previous) runs that do exactly the same to see the impact of a change
 
14ms feels wrong though
might be usecs
 
as in, using sapi/cli/php Zend/bench.php?
 
Hm ok
 
4:49 PM
@CraigFrancis yes
there might even be a make bench
worth looking in the Makefile
 
I am still fixing Undefined index notices in my project and I just found my first actual bug caused by it. No pain no gain.
 
can't see anything in the make file... but running it a few times seems to be getting some results... A vs B 3 times; then doing B vs A 3 times (just incase coming off the back of the other test has an effect).
bench, 0.420 vs 0.416 = -0.004
bench, 0.422 vs 0.417 = -0.005
bench, 0.419 vs 0.417 = -0.002
bench, 0.423 vs 0.416 = -0.007 *
bench, 0.421 vs 0.418 = -0.003 *
bench, 0.423 vs 0.412 = -0.011 *

micro, 2.310 vs 2.334 = 0.024
micro, 2.315 vs 2.335 = 0.020
micro, 2.320 vs 2.337 = 0.017
micro, 2.305 vs 2.329 = 0.024 *
micro, 2.303 vs 2.326 = 0.023 *
micro, 2.308 vs 2.328 = 0.020 *

* tests run in reverse order
 
cmb
@CraigFrancis I think Dmitry/Zend has a performance test suite for several common apps (WP, Drupal etc.) The Windows team has one as well, but it is currently broken and being reworked. Anyway, I think some micro benchmarks are fine for now.
 
I'm assuming the +0.021 s on micro_bench.php is gonna be a big no-no?
 
5:21 PM
Humm, ok, that's almost entirely from accessing $_GET... maybe it's not as bad as I though
 
5:31 PM
@ircmaxell I think it's fine as is
 
Anyway, gtg, thanks everyone for the pointers, really appreciate it.
 
5:44 PM
Does RecursiveDirectoryIterator also suffers from "too many open files" like using simple recursion with a simple DirectoryIterator ? Or is this handled ? Is there a way to avoid it with simple recursion by using DirectoryIterator? Would not like to just tell my users to increase ulimit
How would I keep in line the amount of open files (directories) when doing recursion
I guess that is the question
 
6:02 PM
Coworker: my head hurts, drupal is fucking terrible
Trying to parse a drupal database
 
Seems like you coworker is a sane person
 
parse as in what kind of parsing
 
as in simply understanding the schema
 
finding columns, use information_schema, finding content just dump the database with the corresponding line terminators, cat | grep
 
the docs via drupal are completely different than the db
 
6:04 PM
@Bill.Caffery ^ coworker
 
Understanding the schema, SHOW CREATE TABLE table;
If FK's are proper it should be fine
 
omg!!! duh!! it HAS fried my brain...
 
@Bill.Caffery 😂
 
@Bill.Caffery Do you want me to tell you about numeric strings in PHP to fry your brain even more?
 
noooooo no fk relations... whyyyy?
 
6:06 PM
@Girgias oh god
 
actually yes... i could use a good coma
 
Ah Doctrine models ?
 
lol as if
 
just check the models then
 
6:08 PM
yep looks like im digging through drupal source...
 
@Tiffany I mean that one is relatively fine, now large numbers to int is a fun one depending on if it's a float or a string
 
I'm currently in DOMDocument/string mutation hell
almost done with this bloody parser, almost done... but it fails on a file and I'm trying to figure out why
wish I had null-safe operator :P
I've had to put in three if (!is_null()) checks for DOMElements
 
Sure you meant to type !== null :)
 
does anyone know what the "strict" flag to mb_detect_encoding actually does?
 
6:23 PM
@PeeHaa my brain is about as fried as @Bill.Caffery's
so sure :P
 
@IMSoP According to the comments (so yeah) it stops it being confused about ISO-8859-1 and UTF-8 with characters that both support
 
that sounds like nonsense
I mean, every ISO-8859-1 string literally is a UTF-8 string
 
It's in the comments, so that is to be expected
 
@IMSoP It means it doesn't stop detection as soon as there is only potentially valid encoding left
 
ah, so if all the encodings in the list are wrong, it returns false rather than assuming you knew what you were talking about?
oh, wait, I'm talking nonsense about that comment being nonsense
 
6:33 PM
@Tiffany, cant you just use ?? ?
 
@NikiC :+1:
 
@Bill.Caffery I could, but what's the alternative? empty string?
 
given what you're doing, probably...
 
@Tiffany Let me go back in time and create an RFC for PHP 8. Done, you should have it now.
 
$node ?? 'Array' would be one way to handle it :P
 
6:44 PM
@IluTov :P could you backport it to 7.3
(if it's not obvious, sarcasm ^)
 
@Tiffany Sorry, flux capacitor is out of battery.
 
Almost impossible to make a file finder which implements iterable also following symlinks without some sort of array file tracking due to links pointing to other links and causing recursion :D
 
I am near that point and it's not even 2PM ...
@ln-s add a counter, if it goes more than two or three times, ->next()?
 
Nah, array_key_exists or in_array with the full file path
 
(probably a bad idea, I dunno)
 
6:47 PM
           if(array_key_exists($file, $this->files)){
                continue;
            }
 
ah
 
But hey content searching on 5252 files takes 728ms
 
how about 660,000 files? :P
... I am full of snark and need a break
 
I'll find / and meassure that for you too
 
7:23 PM
-r--r--r-- 1 root root 0 Apr 13 16:22 /proc/1/maps
cat: /proc/1/maps: Permission denied

Cool
 
+x
?
 
Nah it says it's readable but it's not
weird /proc stuff
 
@ln-s I mean file doesn't need to be executable for cat command?
 
no
just readable
 
process 1 is the init process, so I guess messing with its proc files isn't the best idea :P
 
7:37 PM
I'm just testing my stuff through fire, doing find /
 
7:54 PM
@Tiffany About 50 seconds
in 660000 files
Would say it's decent
 
00:00 - 20:0020:00 - 00:00

« first day (3832 days earlier)      last day (1098 days later) »