« first day (3338 days earlier)      last day (1601 days later) » 

Wes
12:00 AM
then make the auction start at that price
why is ebay so stupid
 
Hi guys, how can output what is match in_array? not true/false
 
@Wes That is not a unique-to-eBay concept.
 
@winresh24 what? You know what the output is because you are asking in_array to look for it
 
Wes
yeah but what is the purpose?
 
Yes, I compare the currency and it is found. But I want to output the currency found by in_array
 
12:14 AM
@Wes The low starting price entices people to bid on the item, and often once people have decided to place a bid they will continue bidding on that item, even if there are other items that could be had cheaper. Basically is a psychological thing.
I, and many others, tend to avoid auctions with reserves.
 
@winresh24 I am literally not seeing the issue
If you have the currency that you are comparing
You can output it WITHOU going through in_array
 
wait I'll show you maybe I'm doing it in a wrong way
here is the var_dump of array prntscr.com/q6vcu7 and I have a ip detection of the user which will must output which currency he is using. But I can't make it going
 
I am still not understanding your issue
 
I want to compare the Currency inside the array to the current currency of the user. And output the image inside that array.
 
Well finaly getting somewhere ... you didn't say any of that before
So what prevents you from just doing $array['key'] when you know that the currency is in the array ?
 
12:27 AM
Yes, For example, the browser IP was from "CAD". I need to find the "CAD" in the array and output what images belong to them.
 
The thing is I have no idea how you get these arrays
And I still don't see any major issue
just if (in_array($array, $curreny) { echo $array['yourèimage_key]; }
Like I don't see where you are strugelling, possibly because I don't have all the information needed for me/us to help you
 
Wes
@Trowski is there a way to know if there is a reserve on ebay?
looks like you can only find out if you bid once
 
My issue is yes the in_array return "true" it matches the $currency. But the output only show the first array.
The first images in the array
 
@Wes Oh, it used to say it right away with something like "reserve not met."
I haven't bought anything on eBay in some time, so maybe they changed that.
 
I am still not understanding your issue
Because that seems to me the reasonable and expected behaviour
And that image ain't really helpful btw
Code is helpful
 
12:41 AM
wait let me show you
pastebin.com/sWH7K3CB - here is my current code @Girgias
 
That is still not helpful
Where do you get your arrays what the hell do you want to do with them
Because I am still not seeing what is wrong/what you want it to do
 
Those array are custom fields
 
That seems to me like you got the expected behaviour
 
 
2 hours later…
2:38 AM
OMG all these DnD resources I can't even donjon.bin.sh
 
 
5 hours later…
8:00 AM
gingerly very cautious or careful
 
cmb
8:13 AM
Are there any (emergent) best practices regarding preloading? I mean, would these recommend preloading in addition to autoloading, or as replacement.
 
8:25 AM
@Girgias I get the impression that the person didn't know what the currency type would be and wanted to output it if the conditional was true. But that's without checking the images.
 
Hi, I am written an endpoint that will accept POST request. User can upload file to request and the output is a JSON value. I was wondering why this cannot be a GET endpoint?
 
8:49 AM
@cmb in addition to, I'd say
It's not like autoloading has any additional cost
As the recommendation is to only preload hot code, it's not really possible to avoid autoloading completely
 
cmb
That would be great, since for Windows replacing autoloading would not necessarily work.
(file_cache_fallback)
 
9:06 AM
where does the fuzzer live?
I see it in sapi in master but prior to that is it a separate repo?
nvm finally found the externals post on it
 
9:54 AM
moin moin
 
Yo!
sup guys ?
 
cmb
10:07 AM
\o
 
o/
 
Wes
\o
 
o/
 
Hey
Back again with my famously terrible questions
I want to make an invoice generator that can be reused in multiple projects
 
any suitecrm developer here..
I am using soap api and from the code I am expecting an array(value1,value2,value3) like response but it is always forcing me to use following response array('id'=>value1,'id'=>value2,'id'=>value3)
 
And the generation service is picked based on client needs
Which means that at some point the client needs to convert their order representation to an expected one by the services API
Im looking for patterns to look over
Factory for the service implementation pick imo
But im not sure how to handle the input problem
I.e. client can have an order represented in All sorts od manners and I guess I need some sort of an expected input
Or do I just pass data via arrays and each service just expects a different one?
(different array structure)
Well still a single class that does the conversion provided by the client would be nice
Guess the client can always convert his data to the data expected by the concrete service
Or they could convert to an object defined by me and I will convert it to the proper structure for the different APIs
Is it the Adapter pattern I am basically looking for?
Adapter + something in the middle with the factory that constructs the desired service and calls it?
Same API but delegates work to child
 
 
1 hour later…
12:17 PM
@NikiC can I merge the mbstring changes and drop the exception for empty needles later?
 
12:32 PM
Segfault with preloading Laravel – #78918
 
cmb
12:44 PM
@Girgias, not sure if it's a good idea to let mb_language() throw, since there is no mb_list_languages(), but even more so, because changing the INI setting mbstring.language wouldn't. Or am I missing something?
 
@cmb seems reasonable, tbf I do those changes semi blindly
However I also tried to have a look at removing the 3 mbstring deprecated INI settings
 
cmb
That's why we have reviews for PRs. :)
 
And I'm getting failures with zend_encoding and related and segfaults and I have no idea why lol
Gonna leave that to someone more competent on that code base
@cmb indeed :D
 
cmb
See also externals.io/message/103087 (especially Nikitas comment)
 
Aaaaa
Makes sense, that I'm getting seamingly unrelated failures
 
12:53 PM
@cmb that should be resolved in 7.4
 
cmb
You mean the Zend Multibyte issue?
 
not sure about multibyte, but at least since 7.4 they should work at all
 
1:05 PM
Why would you want a scalar value to be stored in an object?
i.e. a ValueObject that holds nothing but a single integer
I guess this kind of answers my question: medium.com/@nicolopigna/value-objects-like-a-pro-f1bfc1548c72
 
@PeterTheLobster to put constraints on the scalar value
Easy example a RGB value can only range from 0 to 255
So you use a value object to ensure the integer is within the correct interval
 
Well I get that
 
I don't think Zend Multibyte works with mbstring tbh @NikiC
 
I mean that's at least a little complex and reasonable
 
Or at least the default propagation
 
1:14 PM
But like the age example given in the article did not persuade me at all
 
What if I provide you with -15 as an age
That's not correct
You can also reasonably assume an age of 200 is bollocks
 
The author even mentions "primitive obsession" when all I thought about was "OOP abuse"
 
Well that's not OOP abuse
 
Yes ah but that sort of thing should be handled during data submission anyway
 
An age is a concrete thing
Well yes but the thing is if you need to handle something like that thought out your codebase you want an object
And not a rando integer which can be modified who knows where
Anyway I need to go
 
1:16 PM
I mean in a form for example - the age should never get through the form in the first place.. there is validation in place before it's even assigned to a User object for example
It just seems to me like a lot of coding overhead with minimal benefit
Also since primitives get passed by value not reference I wouldn't necessarily be worried about it being modified on accident
Oh ok see ya
What I mean is that if the argument is that you can't always guarantee that validation will be performed then by the same token you can't always guarantee that the value object will be used
I don't know I'll think about it more but so far I'm not sold
It makes a lot of sense with money to me for example
if you want to make it's always in cents for example
ie not a float
 
2:03 PM
@bwoebi bugs.php.net/bug.php?id=78904 <-- I think we should have given __get() the same treatment as __set()
@cmb yes, it is
@Girgias I'd prefer dropping that first, it seems like half the PR is about those error cases
 
cmb
@NikiC, but see 3v4l.org/pMXsa
 
@cmb Referring to empty needle errors here
Not sure what that snippet is supposed to tell me though ^^
@ircmaxell ping re internals gathering. Did you get the mail?
 
cmb
Ah, thanks! That snippet is about https://externals.io/message/103087.
TL;DR: I think all exts should support the same encoding names.
 
@cmb ugh
 
@NikiC I don't really get the issue? Is the problem that __get() is called when otherwise it would just fatal error if it weren't called?
 
2:15 PM
@bwoebi yes
 
cmb
@NikiC, "ugh" for adding ISO8859-1 aliases?
 
And because certain artisanal frameworks implement __get() in every single f'ing class...
...the end result is that the premise that you'll easily catch uninitialized property errors kindof gets lost
@cmb ugh for this being a problem
 
@NikiC I think it could be sane to expose something in reflection so that they can properly throw in their getters
I think overusing __get() is nothing we should design the language around
but we should provide library authors the means to inform the user that they're doing bullshit
I mean expose some method to check whether a prop is initialized
 
> So, sounds like we should have given __get() the same treatment as __set() in how it interacts with uninitialized typed properties. I'm not sure if we can still make this change at this point.
I disagree. The first .0 usually finds oddities in new features, as it actually gets used more widely.
 
I think the current behavior is sane - e.g. it allows you to have an access-time loaded typed property.
 
2:20 PM
@bwoebi You can still get that with an explicit unset(). Just like for normal properties
While for typed properties you get the access-time loaded property as a default behavior, which most people don't expect
 
@NikiC so you want yet another state?
 
@bwoebi No, I want to extend the existing __set() check to __get() as well
Or rather just to all magic getter/setters, rather making just __set() special
Right now the behavior is asymmetric
 
@NikiC just to remove confusion: what exactly is the existing __set() check?
 
@bwoebi __set() does not get called for uninitialized typed properties, only for properly unset() ones
 
but .. unset() props are uninitialized?
ah, if (Z_PROP_FLAG_P(variable_ptr) == IS_PROP_UNINIT). okay
 
I didn't recall that we actually changed that
I guess it's fine to mirror that behavior to __get().
@NikiC yes, it is 7.4.0, but I guess, if we don't change it now, we won't really change it later or it is quite the unnecessary weird behavior break between 7.4 and 8
 
o/
 
maybe ask the RM if you feel unsure, but I would do it and categorize it under bugfix: forgot to mirror __set() behavior to __get().
 
@Derick ^
I think I already have a patch for this ready somewhere, just need to find it
 
@NikiC okay will try to do tha this evening if I'm not too tired
 
2:42 PM
CLI server does insufficient cleanup if php_request_startup() fails – #78919
 
@NikiC Thanks. I think also relevant for you @Ocramius
 
Yeah, I'm checking if this breaks ProxyManager right now...
It doesn't
 
Great
 
@NikiC Oh shoot, yes I did I just need to reply. crap
 
3:12 PM
@Tiffany This gets me thinking, is there some serialization format one could choose to efficiently store structured text on dbs other than html? Something more compressed and db friendly would be nice.
 
@2dsharp Compressed HTML? :)
 
@2dsharp db friendly? Do you want to search in the html?
 
@cmb iirc we already do some encoding mapping for oniguruma, so having more of that wouldn't be new
 
3:30 PM
@NikiC What's the question?
 
cmb
@Derick, whether github.com/php/php-src/pull/4974 is good for 7.4.1.
 
By the way, when is 7.4.1 tagged?
 
cmb
RC1 is next Tuesday, GA one week after (to sync with 7.2/7.3)
@NikiC, see github.com/php/php-src/pull/4975 (ISO8859 aliases)
 
3:48 PM
@NikiC Looks like a BC break, not?
 
@Derick Yes, otherwise I wouldn't be asking ;)
That's why it's a time sensitive manner. It's a BC break in newly introduced functionality, so it's our only opportunity to fix it.
 
I don't think we should be breaking BC, but I can also see that this is a bug. Do the frameworks continue to work with this change?
 
I've checked Symfony and Laravel, they continue to work
And our usual suspect ProxyManager of course ;)
 
cmb
Could someone have a look at bugs.php.net/bug.php?id=78560#1571737398 please? We already got 3 duplicates.
 
welllll who has access to that server? ^^
@cmb write to systems@?
 
4:04 PM
@Derick I too would consider that a bug.
 
cmb
Well, I think systems@ is basically Sascha, but he's not listed there. Also, I've switched to systems issue long ago, so mail should already have been sent (and they should get mail for every comment).
seems we suck at infra ;)
 
@cmb you don't say
 
it seems I have root
 
I have a confusion with var_dump and doctrine

foreach($onboarding_data as $user_id => $document_id) {
var_dump($document_id);

With this foreach I'm dumping $document_id and I get an array with many documents which is fine.

But when I dump it in an object

foreach($onboarding_data as $user_id => $document_id) {
$documents = $this->em->getRepository('Entities\Documents')->findById($document_id);
var_dump($documents); }

I get the object with only an array of 1 document instead of all the rows that I get when I dumped $document_id
 
@cmb
 
cmb
4:10 PM
@Derick, should I list you in the Wiki?
 
no
:-)
 
cmb
k
btw, that might be nice opportunity to exercise some manual SQL ;)
 
... I have no idea what I changed, but it works now.
no
uh
 
cmb
4:29 PM
@JoeWatkins, should we close bugs.php.net/bug.php?id=75235, because there is PHP_CLI_SERVER_WORKERS now. Or not document that at all?
 
@PeeHaa Searching isn't a priority rn, but could be a nice-to-have maybe in the future.
 
@cmb There were some weird records in the databases:| 8310 |     421 |    8321 | ssh2-1.2.tgz    |
| 8311 |     421 |    8321 | ssh2-1.2.tgz    |
| 8312 |     421 |    8321 | ssh2-1.2.tgz    |
| 8313 |     421 |    8321 | ssh2-1.2.tgz    |
| 8314 |     421 |    8321 | ssh2-1.2.tgz    |
| 8315 |     421 |    8321 | ssh2-1.2.tgz    |
| 8316 |     421 |    8321 | ssh2-1.2.tgz    |
| 8319 |     421 |    8323 | ssh2-1.2.tgz    |
+------+---------+---------+-----------------+
lots of duplicates (8321) which actually belonged to something else
   | 8317 |    1021 |    8321 | nsq-3.4.3.tgz |
 
@LeviMorrison That's what came to my mind in the first thought, but I was wondering if there's some better representation for storage that can be rendered back to html at runtime.
 
cmb
@Derick, that looks like a bug somewhere. Anyhow, thank for fixing!
 
4:49 PM
@cmb I'm still scared to document it officially, but do whatever you think best
 
cmb
Why are you scared? Stability?
 
I'm scared people will use it to actually deploy stuff
I don't want us to become responsible for maintaining a production server by the back door, the only reason people don't deploy the cli server today is because it's not possible ...
when they realise it's possible, they might ... and then we're in trouble because the cli server is not good, and not meant to be good
it only has to make it's way into one laravel podcast and we're fucked
 
@JoeWatkins What is this documentation that you don't want to do about?
@NikiC I think you're good for that __get() change
 
I hacked up cli-server to support multiple processes, in order that we can actually test concurrency in things like opcache and so on ... but I done it quietly without documenting it, because it's really just for internals and extensions devs
 
cli-server is really for internals to test stuff
I don't think you should document it either
 
4:59 PM
yep, but you'd be surprised how many laravel (etc) tutorials and tools use the cli server already
 
and I would potentially also hide it behind a configure flag (--with-maintainer or whatever we use for that now)
 
i would document it and add a disclaimer, then you can close all tickets based on the disclaimer
becaues otherwise extension devs will also not find it
 
well they tend to be familiar with source a little, but I guess they might not see it ...
 
the change that extension devs read that documentation though: 0
 
also true..
 
5:01 PM
I'm reluctant to do anything at all, I'll leave it to other people ... then I can blame the other people when it starts getting deployed
 
hrhr
 
@Derick a configure flag is problematic if I want to use it in some extensions test suite, I need to be able to rely on 7.4+ having the feature, or alternatively add some strange constant or something to detect support ... I'd rather it was just there all the time, quietly ...
 
cmb
Well, the built-in server is actually publicly used (see e.g. bugs.php.net/78047). However, people also do other highly unreasonable things, e.g. drink & drive. Is it the car manufacturers' fault, or that of the beverage industry, that this happens? I'm generally not in favor of hidden features (IMO better document and warn), but I don't have a strong opinion on this (partly because it's not supported on Win, and I can see FRs coming).
 
Morning
 
@cmb should the public be allowed to arrive at VW headquarters at the weekend and use their crash testing equipment for fun ?
should they also have access to the operation manuals for said equipment ?
 
5:07 PM
I did composer require amphp/http-client, but the namespace is still Artax, is this right?
 
some things are best left unsaid, this is one of them, imo ...
 
5:23 PM
would it be a good idea to change the default argument to phpinfo() to INFO_ALL - INFO_VARIABLES? The $_SERVER output is highly critical and people having public phpinfos isn't rare
extensions can easily hide security related information via minfo handlers, thats not possible for $_SERVER and with 12 factor env architecture people are putting more and more secrets into this section
 
@NikiC / @JoeWatkins in "ZEND_TYPE_IS_CE(info->type) ? ZEND_TYPE_CE(info->type)->name : ZEND_TYPE_NAME(info->type)" what does each of the two options represent?
 
@cmb The CLI webserver sometimes segfaults when there isn't output. I mean, that's an unusual case for it to happen intentionally, but sometimes when there are bugs in the error handling behaviors it can happen, and you don't want that to crash...
 
I don't understand the question I don't think ... it's a zend_string*
 
I haven't filed a bug because it's only intermittently reproducible for me, and haven't got the time.
 
@JoeWatkins That's the output. In which case is a class property type hint a CE, and when is it not?
 
5:34 PM
@Derick if it's already resolved it's a ce, otherwise a string
 
ah, OK :-)
 
yes, resolved, which is everything internal, and then at runtime, if a typed property is being assigned it's resolved
 
hmm, I can't seem to get the CE variant. I thought this would do it:
class foo {
    public string $x;
    private int $y = 42;
    protected Fibble $z;
    protected \DateTime $a;
}

$f = new foo;
```
(both are strings)
 
> if a typed property is being assigned it's resolved
 
ah :-)
cheers
 
5:42 PM
yw
 
cmb
6:09 PM
@JoeWatkins, if they are allowed to use it, they should have access to the manuals. But I'm fine with not documenting it (and leaving the FR open). :)
@beberlei, not sure. IMHO phpinfo() should never be publicly exposed, and it's quite handy to have all info available by default. Don't mind to change the default, though.
@LeviMorrison, well, we're bad at maintaining the built-in webserver (bugs.php.net/…).
 
Let's be honest, we're just bad at everything :P
 
@cmb i agree about should, but since you cant access phpinfo for a webserver from the CLI that is still what is done a lot
 
@NikiC @bwoebi thx for the ping :)
 
7:14 PM
@NikiC replied
thanks for the push
 
7:25 PM
yellow
 
7:46 PM
@kelunik I might have found a new bug in http-client
Need to test a bit more though
 
8:07 PM
good mornings
@NikiC no we just repeat the same mistakes iteratively so that we can learn from the same mistake multiple times ^^
considering a utility/program aims to adhere to the XDG Base Directory Specification but none of the XDG_* parameters are given and HOME not as well, how should it behave?
 
8:41 PM
@NikiC I just blame the Pink Hat People for all the bad stuff
 
9:36 PM
@cmb This is one thing having paid contributors would be nice for.
 
How safe it is to rely on having $HOME set and non-empty on a (another's) computer system to be available?
(on a scale from 1 to 10, where 1 means totally safe and 10 means defective by design)
 
@hakre probably a 2-3
 
9:52 PM
If on MINIT I spawn a thread for background usage, and I share objects from a PHP thread with it on a ZTS build, will those objects get destroyed on RSHUTDOWN even if I've added refcounts?
I'm wondering how reliable it is to use a background thread to deal with things like serializing and transporting those to our backend without blocking the main thread at all.
/cc @bwoebi since you seem to be around.
 
10:04 PM
@bwoebi thanks. let's throw an exception on precondition if $HOME is unset or empty and see who complains - defer the details.
 
cmb
@LeviMorrison, I think that all non-persistent memory is freed on RSHUTDOWN.
 
I figured it was something like that. Probably have to serialize in the thread that holds the objects, then pass it to the other thread for transport.
 
@LeviMorrison are you only doing that on ZTS? or in NTS you create a thread per process for the background work? i never felt the RSHUTDOWN serialization of payload was taking too long, but i guess every ms counts at some point
 
Currently our background thread is in beta, and the engineer who built it is on a different team.
I'm trying to figure out the soundness of the overall approach.
 
hehe
 
10:20 PM
We have had a handful of reports of us increasing memory usage that turn out to actually be that we slow down the requests (sometimes due to serialization and transport) and this means there are more FPM workers active, and that's where the higher memory usage comes from: more active workers.
Sadly, I think the existing code needs to be thrown out. I hate that.
 
:-(
its very hard to do these things if you are not familiar with zend engine internals
 
Yeah, that's the story of my whole 5 months so far. The previous engineers were talented, but they did not know PHP or its internals at all.
By previous, I'm not including Sammy. He's still here, and he is talented. Thought I'd mention that lol
 
11:11 PM
@LeviMorrison rshutdown is going to free all zend allocated memory (i.e. emalloc), so...
 
Yeah, figured.
 

« first day (3338 days earlier)      last day (1601 days later) »