« first day (4014 days earlier)      last day (950 days later) » 

12:24 AM
Much as I adore seeing stats for PHP usage, it really is best practice to not advertize. I'd vote for removing it, or at least removing the specificity of the version number.
 
Powered-By: Secret Elephants
 
 
8 hours later…
8:16 AM
@Dharman mornings, updated.
Powered-By: A Horde of 8.0.11 Elephants
 
just an idea, but have you ever thought about maybe producing an advanced installer for xdebug ?
configuration, and getting the thing to work, is top of the list of complaints I (and I guess you) hear ...
 
8:31 AM
apt is pretty advanced
And FWIW, I'm chatting with the VS Code plugin author to automatically get the right DLL for WIndows users...
 
it seems like a PHP script itself could do most of the installation and configuration... if it were to exist
 
@MarkR Yes, but the main issue is that there are so many different platforms/setup that it will need to support. This issue was regarding "magento store", of which I never heard of.
 
Magento, as in the main magento?
 
I don't even know.
Did you read the SO entry?
 
Magento is probably the largest open source storefront that exists, PHP of course.
 
8:38 AM
@Derick aren't a large portion of your users windows or mac based (during development) ?
people like point and click interfaces, the people looking after the servers mostly don't need help ...
 
I wouldn't go that far Joe... I don't think I've ever encountered a person who hasn't struggled to get xdebug running and hooked up to an IDE.
Mostly due to the remote connect back I'd think
 
generally the people looking after servers are not the same people struggling with dev time setup, that's what I'm saying ... an installer would target the people trying to get an IDE (or any kind of local) setup
 
The risks of me writing a tool that changes people's configuration does not weight up against their inability to 1. understand how their set-up works; 2. read some docs
 
erm ... it's been a long time since I wrote an installer, but the basics of changing configuration files is like core to these things ... I do mean an installer, like installshield or whatever, not a custom app that you write every line of, a setup.exe that can be executed and re-executed to guide initial and further setup ....
I agree that it shouldn't be necessary
 
Your first install page is 13 pages long, the one after that is 34 pages, the one for step debugging is 19 pages. Methinks you overestimate how much time people will give to 'read some docs' before getting frustrated =)
 
8:46 AM
and if you say it definitely isn't, then you know best ... it was just an idea that never occurred to me before so I thought I'd say it ...
 
@JoeWatkins The problem is still finding out which myriad of setup things people used. Luckily, on Windows, it's WAMP and XAMPP and friends mostly, which just have Xdebug there.
 
Wouldn't bet the house on it staying that way for too much longer tbh, WSL is making huge inroads.
 
@MarkR I have no idea where you get these page counts from. The first install (/install) page is large because there are so many fricking variants.
 
I hit ctrl P and looked at the page count =)
 
@Derick for windows, from an installer, the standard way would be registry probes, and I would wager 99% of setups will be detectable in this way ... it's really a case of learning how to configure things like phpstorm or insert ide out-of-process, in some cases there's going to be a way to do that in the registry which would be preferred ...
 
8:57 AM
Perhaps an intermediary step could be you offering a form on xdebug.org that will generate a suitable INI file based on user provided information, and maybe a help script they run on their dev?
 
@MarkR You mean like xdebug.org/wizard ?
 
Let's see, one sec i've not used this before
 
I don't mean to say "no, it's simple" at all, there's a lot of moving parts in the thing I'm suggesting ... maybe the level of complexity rises above acceptable before you have a useful thing, I don't know
 
cmb
@Derick, are negative values supported for DateInterval::$f? (see bugs.php.net/81500)
 
No
 
9:01 AM
Ah, I was thinking something a little more form-like that would allow you to select which type of services you want to use (profile / debugging / helpers etc), connect backs, activation and so forth. This wizard appears to say (paraphrased) "cool, now go read all these docs"
 
@MarkR Yeah, but the problem is not asking these questions, it is that people know what these things mean most of the time. Or not knowing what their network setup is, or what an IP address is, or localhost...
 
@Dharman I created two PR's for ext/standard (containing different changes), and one for various extensions. :)
 
@JoeWatkins I am aware of the problem. Thought about doing an installer, but I feel very reluctant writing a binary tool that can modify a system's setup 1. for free; 2. runs on Windows which I don't do.
 
Which is why I was wondering what a small user-side script could glean that might facilitate it by detecting those things as best it could.
 
@Derick I also don't do windows, but I remember when I did, and remember that these installer things are their own environment, you don't need to know much about windows but do need to know all about the installer, they are generally scriptable in some strange language and that's more important to know than the nuts and bolts of how the registry works ... if that makes it any better ...
as for free ... I never did figure out how to get people to pay a reasonable amount to do obviously useful things, I've given up, not going to waste any more time trying ...
 
9:09 AM
@JoeWatkins Yeah, I have done these before (25 years ago). But they don't generally apply to installing things into a system/Apache/PHP setup that already exists.
@MarkR Which brings me back to the point that it needs to support so many different setups that it won't ever cover enough of them :-)
 
Have you considered, or done, a twitter poll to ask people what they're using? I'd be shocked if 80% of it wasn't split between xampp, docker, and apt.
 
cmb
As a user, I want a 1-click Xdebug installer, so that Xdebug fixes my code. ;)
 
9:31 AM
@MarkR Twitter polls only allow for 4 options ;-) There are potentially a hundred. Even just "docker" has many different possibilities. Docker with NAT, Docker with Bridge, Docker on Linux, or OSX, or Windows, Docker running on a remote machine, Docker running locally. And old Docker Engine or a new one. And that's just the ones I can think of in one breath.
@cmb :-þ
 
If only there were... other polling services :P "Bro, do you even market research"
 
cmb
IMO there is no way for Xdebug alone to provide such installer. Each tool would need to do its part.
 
Right, like how do you make Xdebug integrate with Laravel Valet, or Homestead, I've NFC either. But by reading the docs and following the instructions you can make it work. You just need to know a little bit of how things work.
 
maybe true, but the common thing among all those setups is docker, and there's a standard way to install things in docker ... so you install an agent in the normal way and it figures out the setup from there ... could maybe work ... maybe ...
 
@JoeWatkins You sadly still run into the problem that making a network connection from a docker container to the outside world isn't always trivial. Luckily at least "host.docker.internal" now mostly works, even on Linux.
 
9:35 AM
plus no tool can do any part, until there's something to do ... you have to invent autoconfiguring-magical-xdebug-thing before they can do anything to help ...
 
I've considered to support "xdebug-gateway" as a hostname (instead of IP or "localhost"), and make Xdebug try to connect to the subnet's default gateway. That could work in many cases... but will also confuse people that have a less traditional setup.
 
in the ideal world, where I don't live, you don't have to do any of this for free ... you could flesh out what is really required, do some blogging and a video explaining what a complicated endeavour this is, and how much time it will save onboarding and how sponsors can get a custom setup executable for their machines with their pretty logo on and the money will come rolling in and you'll move to a mansion and live happily ever after ...
if only some of that happened, that would also be good ...
 
Yes :D
 
In a pragmatic world.. you could handle the 2 or 3 most common use cases and eliminate 50% of the people moaning ^.^
 
@MarkR The people using the 2/3 most common use cases don't moan, because it already works...
I have spend a significant amount of time making 5/6 minute videos about many variants: youtube.com/playlist?list=PLg9Kjjye-m1g_eXpdaifUqLqALLqZqKd4
 
9:42 AM
So you do have a list of the most common mechanisms?
 
Only a guess.
XAMPP, Standard Linux, Docker
 
Is there a mechanism to override the hostname that xdebug sends?
 
Xdebug doesn't send a hostname
Xdebug connects to a configured IP address or hostname, unless xdebug.discover_client_host is set, in which case it will try to find out the IP address from HTTP headers.
 
Maybe it's phpstorm inferring it from headers of some type then. I know my path mappings can fail depending on if im connecting from localhost, or from inside the docker network
 
PhpStorm injects an environment variable when you start the debugging through their UI I think.
but that "hostname" is only to link your PhpStorm configured server configuration with that, it's not really a "hostname" - more like an identifier
 
9:52 AM
I had no end of trouble with it not long back (and this is probably all on phpstorm) where things I accessed via localhost:8081 which was port forwarded would map right, but internal services accessing it via 'nginx' would completely break.
 
tbh, I am not sure what I can do about that
 
Probably not a lot tbh. IMO the thing which would solve the most problems would be flipping the connection direction.
 
How would that work?
You'd need to make PHP wait at every request for an incoming IDE debugging connection.
However, Xdebug Cloud does help with this.
 
@Derick couldn't one connect ahead of time? e.g. on a socket which is started at (first) minit and then available for each process
 
minit for a command line script? :-)
 
10:04 AM
I had been meaning to look at the proxy app and see if that supported reversing the connections.
 
@Derick well, if you invoke a cli script you can also specify -dxdebug.wait=1
 
No, Xdebug still needs to connect to the dbgpProxy
@bwoebi You'd need a sort of out of band connection accepting mechanism, and also convince every IDE that currently supports the protocol to rewrite their connection handling ;-)
 
@Derick that's a much more valid concern :-P (which I agree with)
 
Sure, but the debug proxy can just stay running forever as a service in the compose, and then the IDE could connect to whatever port it's exposed on, I'd think? So you'd be telling the IDE which specific instance to connect to, rather than xdebug trying to connect back
 
@MarkR You're describing Xdebug Cloud, if it would run on-prem. With the dbgpProxy the IDE merely registers with the proxy, and then when Xdebug connects to the proxy it opens a new connection (for every request) to the IDE. This means that IDEs don't need to change any connection handling when using a dbgpProxy.
 
10:09 AM
Something like that yeah,
 
But Xdebug Cloud doesn't run on-prem, because then it doesn't provide an income ;-)
 
Well it won't provide an income from most of these people anyway considering you won't sell it to individuals =)
 
I can, but not in the EU27.
I don't do it yet because of invoices and getting them paid is a pain. Looking at integrating Stripe this week.
 
perhaps an on prem would be something useful to offer in your pro subscription, nudge nudge.
 
on-prem would mean you're going to have to maintain a mongodb cluster - and I'm going to need to write a whole new admin environment
 
10:20 AM
Well, your pro subscription has had "commercial add-ons (soon)" for as long as I remember.
 
Yes :-)
But I didn't say that was going to be on-prem.
 
Oh, using xdebug cloud also requires a pro subscription?
 
No.
I've something else in the works though.
 
I've been looking for something to justify the business price to my workplace tbh, as they pay for my licences now.
 
I'm curious to know what you think that could be though. And I need to figure out how I can include Xdebug Cloud into it.
 
10:31 AM
Might I ask what the reception to xdebug cloud has been like? I've not looked at it in any depth but assuming it supports everything xdebug does, I can't imagine many people are keen to allow that much remote access to their platforms.
 
Xdebug Cloud does not have remote access to platforms. It only takes incoming connections from both Xdebug and IDEs and routes debugging sessions accordingly. I have a few heavy users, and a few that use it occasionally.
 
Is it end to end encrypted?
Or more verbosely, can xdebug cloud servers (potentially) see the content of the variables, and potentially adjust them using the same protocol. I'm not implying you'd ever do such a thing, I'm just thinking of it from a corporate security PoV
 
\o
 
End-to-end is not something the DBGp protocol or IDEs support at all. I would like that to be the case in the future.

The connection between the IDE and Cloud is SSL, and I'm working on doing that for Xdebug to Cloud as well (https://github.com/xdebug/xdebug/pull/646/files). So far, nobody has asked for it, so haven't put a lot of more effort into it.

So that means that technically I *could* look at debugging traffic, but I don't. And have no intention of doing either. Privacy policy: https://xdebug.cloud/policy
 
10:40 AM
Wait a sec, the data sent from xdebug to xdebug cloud is sent in the clear?
 
yes :-/
 
Good grief man you're mad
 
I know.
 
11:00 AM
wireguard offers transparant encryption with minimal setup to add new nodes
 
cmb
@Derick, in case you don't get GH notices, I requested your review on github.com/php/php-src/pull/7572; no hurry :)
 
@Derick perhaps implement PSK
:roll_eyes
 
@ln-s You made a typo
 
plus I forgot <?php declare(strict_types=1);
 
You misspelled <?php declare(strict_types=1); as <?php
8
 
11:12 AM
In that case the result is what I would expect
yea thanks NikiC
 
 
2 hours later…
12:52 PM
hm @NikiC Do you think attributes should influence behaviour of classes? If it were me I'd rather provide a trait \AllowDynamicProperties; rather than an attribute…?
 
1:08 PM
Morning
 
Hi, do you know the php doc refresh frequency ?
 
'bout an hour
 
Want to validate that the number contains dec point
what's wrong there
 
@ln-s decimal is the decimal separator, so "." or ","
Doesn't have an impact on whether it is required
 
1:18 PM
Writing a regex is probably easier than figuring out how to make filter do what you want ;)
 
erm ok
@NikiC Would you have a magic regex on a drawer? I don't think something as naive as [0-9]+\.[0-9]+ would cut it
 
cmb
@RemiCollet once a day (unless that has changed)
docs.php.net is about 4hrs
 
ty, will wait until tomorrow
 
@ln-s depends on your requirements, but I'd say that does cut it, if you're not interested in exponential notation and abbreviated forms (like .1 or 1.)
 
ok
 
1:36 PM
@bwoebi I think so yeah. If you like, it doesn't change the "behavior" of the class, but rather the behavior of the engine interacting with the class.
The only bit of internal magic here is that adding the attribute will add an internal flag, but apart from that this is pretty much vanilla use of attributes
A trait wouldn't really be the same, because it would not work with classes that already use __get/__set
Even ignoring any other minor discrepancies between __get/__set and proper dynamic properties, e.g. in reference handling
 
1:49 PM
@NikiC (yes, I was thinking of some more "magic" trait, i.e. not directly implementing the __get/__set but just the functionality).
 
@bwoebi I don't think traits need more magic :P
 
I was thinking that a trait could be semantically more apt, i.e. mainly a question of expressing it
@NikiC And attributes not more magic behaviour happening when set :-P
But nevermind then … at least attributes are trivially backwards compatible, so there's that
(a trait would need to be polyfilled)
 
Hi all,
Is there any way using which I can access one modules lib file into another module. currently, I am trying using autoload.yml file in my module but not working.?
I am working with symfony framework
 
FYI php org is now on github issues beta
 
@Exception I suppose you want to add an autoloader to your composer.json file
 
1:57 PM
@cmb For the main site, twice daily (around 6am and 11pm CDT). For docs.php.net, you're right it's every 4 hours (around 12am, 4am, 8am, ... BST).
 
cmb
@salathe thanks! /cc @RemiCollet
 
@cmb fpm does not build on windows right?
 
cmb
@NikiC no, it does not build on Windows
 
Okay, then using FAM is probably fine
 
@ln-s actually symfony has autoload.yml way to include those lib files. Not sure how to override them in my module
 
2:03 PM
do you have a composer.json file ?
 
yes, I do have
 
well then add whatever you need to autoload there and it will become available
regardless of symfony
 
is it not possible using symfony way?
 
Check the symfony documentation ?
 
yup but for me it's quite confusing..
 
2:18 PM
@ramsey @PatrickAllaert who will take care of RC4 (it is today IIRC) ?
 
3:09 PM
@NikiC So you killed DynamicObject altogether?
 
3:21 PM
@Trowski It never existed in the first place -- DynamicObject was a suggestion for an alternative name for stdClass
 
@NikiC Oh, I see now that was in a separate discussion anyway. I had recalled it as part of the RFC.
 
morns
is aws management console down for everyone?
 
3:38 PM
@RemiCollet I'll handle it, haven't seen @ramsey here today.
Unless he now pops in :)
 
Anecdotally, what do folks reckon the liklihood of deprecated dynamic props in 8.2 is?
Expecting that to be an audience question at Longhorn this week.
 
Reception seemed pretty good
 
I got that same feeling, yeah. No rioting mobs so far...
 
that will come once people start trying it out with PHP 8.2.0RC2...
 
@Derick Someone is being optimistic ... isn't that what RC6 is for?
Who am I kidding, the right time to start testing is 8.2.1
 
3:52 PM
Just going off by what happened with PHP 8.1
@NikiC One Q for you though, does the new DynamicPropertiesAllowed attribute work in combination with the ReturnTypeWillChange one introduced in 8.1?
 
This is why we need an official discord :P special bughunter emojos for everyone who submits a valid bug report
 
@NikiC And, wanna chat about this for podcast episode?
 
@Derick What was that podcast site again
 
let me know when you have new episodes, I will promote them on PHP Developers (linkedin)
 
3:59 PM
This is why I try to do feature roundups at conferences, just get those couple extra people aware of new features and what's about to break.
And let's be honest, deprecating dynamic props is bound to break things like a bull in a china shop.
 
@Sara Yeah, I give this talks too... a 8.1 on this Thursday.
@ln-s There is an RSS feed :-D
 
@Derick Interesting
 
@ln-s And twitter account: @PHPIntNews
 
Wonder if I could auto post
 
People still use tweeter?
 
4:01 PM
there's 170k people in the group
mostly devs
 
nice
tbh, I've been slacking with it a little
 
@Sara Well phpunit changed its default behavior, so the deprecation itself shouldn't break much for people who upgrade... Now when it gets pulled in 9.0, that's going to be a sight to behold
 
Wondering if I could make you an admin
 
@ln-s I don't want that, but thanks :-)
 
Well don't know if you are interested, let me know
ok
 
4:02 PM
@MarkR I honestly don't have a read on who out there is depending on dynamic props.
 
@Sara It'll break loads of my (shitty) code
 
I know I have code (still in use) at Yahoo that does.
 
probably folks rolling self-made templating engines. I think I use dynamic props somewhere in such a thing
 
It's probably going to be one of the most breaking changes in recent history I'd think
 
$param->url_html_upper; // Lazily generated prop the result of strtoupper(htmlentities(urlencode($raw)))
 
Fortunately they can easily add extends stdClass to that, so I'm not worried
 
unless you're already extending something
 
MY class isn't.
Then again, from what I understand, upgrading PHP is also not a priority, so the whole deprecation issue is the least of my worries.
 
oh right, I think I remember having exactly that train of thought some time ago "oh hey I probably use dynamic props" => "oh it's ok stdClass still accept them"
hopefully this time I'll remember...
 
@Sara Didn't you tell me once update or GTFO ? Was that sarcasm ?
 
4:06 PM
I thought I could stop my migraine this month, I thought wrong. :|
 
the last sentence that is
 
If we really wanted to be "get modern" we'd enforce types on all the properties =) ... maybe in 10 years
 
@ln-s Nope. It's gospel. Upgrade or GTFO.
 
lol
 
But I haven't had any say in that particular upgrade in over a decade.
 
4:08 PM
@MarkR amen to that
 
It'll come. PHP's default dynamic typing days are numbered, it might be a large number, but the tide shifted years ago
 
cmb
4:39 PM
@Sara This RFC offers #[AllowDynamicProperties] as a way to opt-in to the use of dynamic properties. A previous version of this proposal instead suggested to extend from stdClass, and make stdClass the only class with first-class dynamic property support.
 
@cmb Ah, hadn't seen the update.
 
there's strict_types, I wonder why couldn't there be strict_properties=1
¯\_(ツ)_/¯
 
Certainly a less violent way to provide an escape hatch, though I was warming to the benefits of stdClass only :)
 
Certainly one has the option if the bull in the shop is wanted or not
then you could go full fascist on a future version of PHP
Same rules of strict types would apply, only in file which is present, etc
 
@ln-s There would be too many, quite quickly. And that route doesn't have a plan for how to eventually change the default settings.
 
4:50 PM
major version change set stricter defaults
 
lol
I only know that PHP has always been (up to now) all about having a choice to be strict or not to be
Which is neat to a degree (for some), I like strict better
But it's not about what I like
@Danack declare_global('strict_types=1'); maybe, just a thought
 
5:11 PM
(could also be set in php.ini)
 
@ln-s no. Neither of those work very well. It was fine for adding one setting, but not for a whole load of them. Being able to set settings per package - separate from namepsaces - would allow something like:
 
5:27 PM
I'm very much torn... package level declares would solve a lot of problems, we could vote to tighten a lot of things up via a declare, without needing to spam every file with 20 of them... but once they're given, people will riot if they're removed.
 
To me this kind of works just like ini_set, perhaps there's something that I'm missing which tweaks settings per package or something else, I wouldn't know
 
vs editions where you can opt in to specific behaviour early, knowing that it will become the default maybe 6 years down the line.
 
@MarkR "but once they're given, people will riot if they're removed." - you mean individual settings being removed?
 
@Danack Yes
 
I can also see that happening
 
5:34 PM
@MarkR meh. People do that already, but being able to run code with either setting (and without having really annoying deprecation notices appear, until people are ready to upgrade their code), means that internals would be able to say "you've had x years to handle this change, and we've made it easy to do on your own schedule.".
Plus probably you'd have fewer people complaining....rather than a large chunk of people all in one go.
 
I recon the problem would be that we'd end up with first and second class declares, those which are temporary and those which are not.
Lumping them together in editions (for want of a better word) is that it's a carrot to upgrade code to meet the standards of the day, well in advance of us pulling the plug on the old crappy way
 
> those which are temporary and those which are not.
Sure, but some of the ones that we think should be temporary are going to turn out to be desirable to be kept, and others that we think are pemanent are going to be turn out to be temporary (e.g. mb_func_overload).
 
Both have advantages and downsides, I'm not really sure.
 
To me it sounds like there should be something like "per package" settings
 
Per package would be userland, whereas per edition would be determined by the src
 
5:48 PM
The main advantage of having separate settings, over editions, is sociological.....instead of having huge arguments over what needs to be in each edition (which sets having winners and losers, which leads to discussions being really heated), having smaller settings would allow for smaller discussions around each of those....
/the discussion around the trade-offs of what goes into each version is a system...
 
I see the main disadvantage of having separate settings as 1) the number of possible behaviour interactions increases factorially (or is it exponentially?), and 2) there would be a demand to keep those choices in for much longer
 
1) There shouldn't be that many interactions....most stuff should be isolated. And in anyone one code base, most people will have a single set of settings (except when they are migrating) But yeah, there will be bugs, and a lot more complexity in core.
 
@RemiCollet Unless Ben do it before me, I'll do it in about 4 hours, sorry for tagging late today
 
2) again, meh. I can't see it being worse than it is now, and possibly not as bad. But mainly, I care less about dropping old things, than being able to improve things. If some old setting isn't causing a problem, then unless there is a strong need to remove it then it can stay.....and if there's a strong need to remove it, then it's justified being removed.
 
I certainly see the benefits of those of us who like being at the cutting edge, being able to push ahead (seriously, give me a declare(a_zero_length_string_is_not_falsey=1)), but there's a wider view, I think it's important we use this power we have, to push people towards writing better, more reliable code. From an ethical standpoint I think of it like manufacturing and selling a car that gets 2mpg.
 
6:02 PM
Maybe.....but the standard library is probably the worst bit about PHP right now.....and packages would also give a way of migrating to better versions of that, without sudden huge BC breaks.
 
Are we talking packages in terms of engine operation, or packages in terms of prebuilt functionality?
 
tbh, not sure what you mean.
 
@FélixAdriyelGagnon-Grenier probably less than webpack does....
 
and there I was, thinking I'd nail formatting a link in a quote directly
 
6:08 PM
\o/
 
@Danack You mentioned the standard library. So I was wondering if we'd moved on from talking about packages in terms of something like namespace declares, into something such as versioning the standard library
 
but er, if I understand correctly, we're discussing making declare(strict_types=1); the default in PHP right? steps away briskly
 
... and that, friends, is how gpb ended up in jail for murdering Felix.
 
@MarkR currently the way that libraries are used in PHP just isn't as nice as in JavaScript. There's a couple of overlapping problems, such as only 1 version of a library being installable at once, having to pull in functions requires a giant list of use statements, and that PECL is a massive impediment.
Being able to declare that all files that are part of a package, should have a particular set of functions imported and available in all of those files, would make writing code quite a bit easier. probably.
 
6:20 PM
JS is cleaner imo in a large part because of its scalar objects
 
 
4 hours later…
10:15 PM
@FélixAdriyelGagnon-Grenier now that you are a freelancer. Are you open for react work?
 
@PeeHaa yes, React still figures in the few frameworks I'm not against working with :P
more seriously, yes, I'm open to react work, we mutuals on twitter? you can send me info there, or maybe even we can exchange emails.
 
Cool. Potentially we know of somebody who is looking for a react dev in the future.
Pretty sure I follow you on the twatters
 
cool, I'm in no rush either, when the time's ready just tell. I'm not looking at full-time work load any time soon.
 
Not sure yet whether they need it or not, but if they do I will be sure to drop you a aline and introduce you if you want
 
10:23 PM
:D
 

« first day (4014 days earlier)      last day (950 days later) »