« first day (4498 days earlier)      last day (433 days later) » 

12:39 AM
@Trowski Nothing specific. The async stuff is new to me, so I'm not sure what to look out for. :-)
 
@ramsey Off the top of my head, I'd say be sure you're reusing the same connection pool across multiple requests so connections get reused. The pool can injected when creating an instance of HttpClient. You can give your users an opportunity to inject their own pool or create a new one. The pool only provides connections – your instance of HttpClient controls other aspects of the request cycle, such as the interceptors used, timeouts, etc. Thus its safe to accept an external pool.
 
1:24 AM
@JRL I've been looking into comparisons for fun, before postponning it to actually dedicate time to is as part of work :)
 
JRL
@Girgias you mean the operators? what are you planning on doing to them?
 
@JRL Trying to tidy up the semantics by introducing a proper uncomparable state to the engine
Also polymorphic comparisons for internal objects that overload the compare handler
 
JRL
ah, i actually did the work on an uncomparable state like a year ago
didn't ever finish it though
still interested in the work i did as part of my 'equals but not comparable' stuff for internals classes
but it seemed like there were too many cooks on that one
as far as feedback goes
 
I mean, if you want to work on this again together let me know. Probably not before March/April tho
 
JRL
uncomparable?
 
1:34 AM
Yes, I'm busy with other stuff :) trying to push 4 RFC at the same time was a bad idea
 
JRL
my eyes were bigger than my fingers on that one when i did my old implementation. i wanted to pair it with an Ordering enum that had the LeftLarger, RightLarger, Equivalent, and Uncomparable values
which could be returned by the <=> and be accepted in place of ints for all sorting functions
but yeah, i'd help with that when you get around to it
 
I thought the issue was you were trying to support userland classes at the same time. But the enum would be nice but not sure how feasible it is in practice :/
 
JRL
eh, when i was working on the overloads yeah, but my uncomparable and equals != comparable stuff didn't support userland classes
the equals != comparable stuff shouldnt even need an RFC imo
 
Right, yeah, the idea is along the same vein. So I suppose seeing what you did will be interesing and useful
 
JRL
i only did the PR for the equals != comparable. i never pushed my work for uncomparable.
 
1:40 AM
@JRL Probably not, adding a mandatory handler which defines equals and if a compare handler is set use that, which would preserve BC for extensions
I think I did say I was going to go back to your PR...
 
JRL
yeah that's about what i did i think
ah, no it was a default handler for equals that falls back to compare
but then the equals handler could be overridden separately
 
I mean, that's probably the "sensible" behaviour? Although maybe overloading ``==`` is a bit weird but can probably make sense to prevent comparing DB connections or polymorphic equality.
Yeah need to think about this properly lol
 
JRL
== and !=
but not === or !==
for all the work i've done on these operators, i very firmly believe that ===, !==, ||, &&, xor, and, & or should never get overloads anywhere
even for extensions
 
I'm pretty sure you can overload the bitwise and logical ones already. Need to double check tho
 
JRL
you can overload the logical ones in extensions yes
afaik
 
1:49 AM
I mean, the do_operation handler just takes an opcode number probably should add a test in zend_test
 
JRL
yeah, though the do_operation handler isn't called for any of the comparison ops
 
Yeah because that's handle by the compare handler :p
 
JRL
i learned so much about the /Zend folder by trial and error, lol
getting the IDE debugger working for php-src was critical for me learning /Zend
 
Don't we all when we start... it's not like stuff is really documented...
 
JRL
i'd just set breakpoints in the VM and then step if i couldn't find something
though i never did learn the parser that well
 
Wes
2:56 AM
this is BS, right?
 
May be right, we do know a lot of digits of pi
Also 1/10 chance it is right regardless
 
JRL
the record for calculating pi is only about twice that many digits
 
Wes
> 31.4 trillion digits
oh damn i thought was much less than that
 
JRL
100 trillion
in 2021
ah sorry, in 2022
 
Wes
crazy
"how do I convince a math nerd that zero factorial should be zero"
 
JRL
3:02 AM
eh
it's much more convenient for 0! to be 1 if it has to have a value
 
^
The point of a factorial is to know how many ways to arrange n elements
 
Wes
every time i encountered zero factorial in programming i had to special case the zero :P
 
JRL
in combinatorics yeah
 
Which is why it's only properly well defined on ZZ>=1
 
JRL
you know what really gets people
 
3:04 AM
@Wes You are using it wrong then /s
 
JRL
is like 12!!
double factorial
 
Wes
@Girgias not unlikely
 
oh boi
 
JRL
which is not (12!)!
it's 12 * 10 * 8 * 6 * 4 * 2
you decrement by 2 instead of 1
 
Huh TIL
 
JRL
3:05 AM
also called semi-factorial
mch more useful for statistics and combinatorics
 
So 12!!! is 12*9*6*3 ?
 
JRL
lol
double factorial is useful in stats, i dunno if triple factorial is
 
/me woke up, saw what looked like maths discussion, decides its actually a nightmare from 6th form maths class and goes back to sleep
 
Wes
lol
 
 
3 hours later…
6:43 AM
@Girgias yes, makes me wonder if there's a gamma function equivalent for triple factorial :p
 
 
1 hour later…
8:01 AM
morning all
There are topics on type checker and typed variables and I started thinking in that context if type erasure at runtime could be a good approach but from my recent experience I think the serialization mechanism require type information at runtime. Please correct me if I am wrong
Recently I had an issue with PHP objects serialized in database (by Symfony Messenger) the issue was in my code ofc which I completely forgot may happen, the serialized object was stored when one of the fields was nullable.
At the time of unserialization the class was already different and the field was no longer accepting null. So the unserialize failed - which is good. But if we erase type information at runtime I'd have to debug in order to find the root cause of the problem at first use of the object field with unexpected null value in it. Is that correct thinking?
 
 
1 hour later…
9:16 AM
I find this hard to answer as I don't know whether native deserialization would be considered run- or creation-time.
I'd say it should be creation, but I don't know. @brzuchal
 
@hakre What's the difference in your understanding?
 
Perhaps similar as yours: If invalidation would be/is at runtime, and deserialization is creation time, deserializing would type-error as the runtime invalidation would not yet apply to that object being created.
AFAIK there is yet no runtime invalidation in PHP, right?
 
Well it depends, you can run into problems if you change type of a field via direct assignment or by ref. That would be runtime, right?
 
 
1 hour later…
10:29 AM
@brzuchal IMHO changing the property type by assignment should not work, same by ref. Do you mean that by runtime invalidation? Lets say this would be, then creation time should be different, because it is initialization, so both assignment or aliasing should not redefine a properties type on creation/initialization. Otherwise what would be the benefit of specifying the type while defining a property?
 
It doesn't work now as it resolves into TypeError AFAIR
 
Think so as well, but as you're asking what would be if and on deserialization specifically, I'd say that would be similar as for example new and then initializing within the constructor (or constructor property promotion).
as the protocol is the name of the class of which the definition comes from current state (and must not necessarily be defined the same as when the object was serialized), the current definition should be leading as otherwise its a total chaos.
As I did understand you, you would also benefit that it's throwing for handling the case, right?
 
10:59 AM
My concern is if while ideas like type erasure should consider these kind of issues, I guess yes.
 
Morning all!
 
11:15 AM
mornin
 
 
3 hours later…
1:59 PM
Ah brilliant, the ext-tidy error messages depend on the locale
 
Hm, there's no way at run-time to figure out whether a class implements an interface itself or inherits it from a parent class too, right? I.e. given class Bar implements Foo {}, class Child extends Bar implements Foo {} and class Child extends Bar {} are indistinguishable, right?
 
I suppose method_exists() does return true if the method is inherited?
I'm confused, I just found a memory leak in Tidy using ASAN, but it only seems to be caught by Clang?
 
@Girgias if the method is defined on the parent and the child class, it doesn't help.
 
Well don't think there is a way hten :/
But that's an oddly specific request you have there
Do we already have a file that is over 4GB in php-src?
 
GitHub repositories only accept files with up to 100 MB. I suggest to generate a sparse file as part of the test if that's what you're looking for.
 
2:12 PM
@Girgias the intention was to trace a function depending on whether it's the primary implementation of a method - which would be defined by the fact that it directly implements an interface (or has parents which don't implement the method themselves). Maybe that's not such a good idea
 
Welp ok
 
Frankly, you don't want to force 4 GB of data onto anyone cloning or checking out the repository :-)
 
@TimWolla That is true, welp time to write more tests then
 
 
2 hours later…
4:36 PM
@Wes hey wes o/ we're doing okay, we live in Cesme, Izmir - indeed we're pretty far from where it happened, we were lucky... I have friends whose families are still under collapsed buildings :( it's been one hell of a week so far over here, to say the least
@Wes thank you! I know, right :-) it's great to see you around and alive too!
@StatikStasis ha! it was a really plain and simple event :-) if we do end up planning a summer time event for it however, you can bet I'm going to also plan for that, heh.
 
4:51 PM
\o
 
5:43 PM
Saw a couple pictures, one showing a road where the earth shifted it about half a lane...
The most minimal in terms of damage, but unexpected
 
interesting
 
Is there any way I can improve this question? It has gotten two answer that don't address how I can solve this problem? Should I bounty it? How do use Guzzle 7 fully asynchronously with ReactPHP event loop without blocking for I/O?
 
 
3 hours later…
9:30 PM
@Tiffany That is INSANE!
 
 
2 hours later…
11:35 PM
Who do I work with to upgrade wiki.php.net? It is currently running PHP 7.0.33.
 

« first day (4498 days earlier)      last day (433 days later) »