« first day (3275 days earlier)      last day (1670 days later) » 
02:00 - 17:0017:00 - 00:00

2:20 AM
method_exists() in php74 works differently from php73 in checking priv. methods – #78632
 
 
1 hour later…
3:45 AM
\o
 
4:18 AM
@beberlei ping
@pmmaga ping
 
4:42 AM
o/
 
5:27 AM
@MarkR the issue with var_dump is that ... it outputs too much sometimes. It is not useful to get a few GB of var_dump output in a log file (seriously, that happened to me and stalled everything due to full disk after a short while)
 
6:18 AM
o/
 
for every OSS project saying "we need contributions" theres another one with dozens of PRs waiting to be looked at, and zero commits from maintainers for months at a time.
 
7:18 AM
gut moaning
 
7:49 AM
 
cmb
o/
 
futhark the runic alphabet : any of several alphabets used by the Germanic peoples from about the 3rd to the 13th centuries
 
8:07 AM
the whole western tech world keeps pushing for E2E encryption on everything because of privacy. Meanwhile here I am wanting HTTPS apt repos just so the shitty transparent HTTP proxy my ISP uses doesn't cause package updates to fail.
 
@JoeWatkins on trip home from vacation, can update you this weekend
 
I don't care if the Chinese government or the orange idiot himself knows that I installed Apache. I'm more bothered when it just shits itself because $reasons.
or I guess in my case, its more likely to be the Thai government than the Chinese government, but my point is the same.
 
@beberlei awesome
 
Wes
@Stephen my favorite kind are those maintainers that are 100% anal about my PRs, while they fail to realize that their project is utter crap already
mornings :B
 
morns
 
8:20 AM
some fridays are better than others ...
 
lol
 
@Wes maybe that's why they want PRs, to fix the crap :P
 
Wes
@Stephen no i mean they are super pedantic about your changes, while the original code is much worse. and they completely fail to realize that
 
@Wes oh. I think at this point I'd welcome any kind of feedback compared to no response from the maintainer for <checks notes> 5 months.
 
Wes
lol
 
8:36 AM
@JoeWatkins is that 3 different varietals as well
 
@DaveRandom 2
 
the middle one looks kind of kush-esque, very indica, other two look more sativa
but then I never was good at identification
 
outer two are white widow, the middle one is just generic cheap feminized seeds, they sell them for 2 bucks a pop, lucky dip ...
they're not the best ones ... the last plant I'll cut down today is taller than a 10 year old .. the bud on the top is as long as my whole arm ...
 
white widow, not heard that name for a while
 
I know right, it's like school again ...
 
8:40 AM
crack out the super silver haze
 
they got some really crazy stuff, like 50 bucks for a single seed ... but we tried that, the more exotic strains are really fragile, and we've just got a simple setup .... the cheaper varieties, ones that have been around forever, work the best for sure ...
 
9:29 AM
current mode: testing Debian vagrant box under VirtualBox inside Ubuntu VM under Parallels.
all inside the matrix.
lol, is that an Easter egg of S/O chat, that the screen flickers for a second when you type "inside the matrix"?
 
good moonings
 
Email from (business) bank: "Your (faulty) token has been replaced with a new one, serial number <...>. Please use the new token when logging on".
Literally no instructions about how, where or when to get said new token.
Just for kicks, they've also disabled the old token.
 
Hi, professionals, I have a question
i want to do this
getting values of a column together in a single row
SELECT

`testlist`.`testname`,

STUFF((SELECT '; ' + `normalranges`.`name`
    FROM `normalranges`
    WHERE `normalranges`.`testlistid` = `testlist`.`id`
 FOR XML PATH('')), 1, 1, '')

FROM `testlist`
and that is my code
but that gives me an error
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'XML PATH('')), 1, 1, '')
What should i do?
thanks for any help
 
10:13 AM
@Wes Is this you? wiki.php.net/rfc/deprecate-backtick-operator if so can you resurrect it, or allow me to
 
Wes
yes that would be me @MarkR i don't want to do that / you shouldn't do that
i mean unless you have full body armor, hand grenades and stuff
:B
 
Can I assume the reason you didn't push it forward was because of opposition then?
Is there an internals discussion on it?
 
Wes
@MarkR i have made the mistake of mentioning "unicode strings"
rule number one on internals. never mention unicode
 
heh, well to be honest it doesn't look like it had much discussion. I only realised there was an exiting RFC when I saw it on Reddit. I think the better case would be made purely on a clean-up and security grounds.
 
"purely on a clean-up" - if you want to see that RFC progress, you need a much stronger justification than that.
saying it's a cleanup assumes that it's something that needs a cleanup....pretty sure not everyone (or a majority) will agree with that.
 
10:23 AM
Well I guess we'll find out if it goes to a vote.
Seems a no-brainer to me, identically functional, more intuitive, fully supported alternatives exist.
 
The counter argument will be that it's easier for when you're using PHP as a replacement for Bash.
Where the terseness is quite valuable.
 
Well based on the top comment on our own help files being the problems I think taking a shot at depreciating then killing it off is probably worthwhile. I just didn't want to tread on @Wes 's toes if he still planned to bring it.
 
Wes
@MarkR feel free to do anything you want with it
it's going to be utterly chaotic though
 
10:39 AM
There will no doubt be loud detractors, but it's a fairly simple set of arguments for / against.
 
@Wes @MarkR just wants to see the world burn :P
 
I just want to see the world have a PHP which has less "WTF!?" moments
 
"I had a very difficult time solving a problem with my script, when I accidentally" - The same is true of any quote character.
Anyway - if you feel strongly about it, go for it. my advice was just to say what I think needs to be done to make the RFC more likely to pass.
 
Well I'm not about to go to war over it, but I think it at least deserves to have the question properly raised.
 
10:48 AM
hint noted - will update mine...
 
11:08 AM
yo @PeeHaa, do you have any work on the new bot, that I can help with?
 
@mega6382 Yep I do. I will be writing some things down this afternoon for people to work on if they want cc @Ekin @Sean?
 
@MarkR while I'm probably in favour of deprecating backticks, please if you do revive that RFC spend some time writing up a list of problems caused by it, and don't mention anything that people will see as "coding style" or possible future uses
 
Aye
 
@PeeHaa cool, thanks <3
 
simply because of the current politics on the list, terms like "compatible" and "clean" are heavily loaded and likely to derail the discussion
@Wes just noticed the version number on that RFC :D
 
11:24 AM
@NikiC should nikic/PHP-Parser contain php7.4 support? I tried to use it for ace but it still didn't fix everything
 
11:35 AM
@MarkR Yeah, I wouldn't mention Unicode strings - definitely not as the main reason for deprecation. IMO the main reason should be that the feature is confusing - it's not obvious that code will be executed, which can be dangerous. Especially since in other popular languages backticks are a common way to delineate strings. Include an example of code that can cause confusion. BC breaks section should mention that a notice will be output instead of saying "None".
 
I would say BC section should discuss the BC impact of removal, and the RFC should set a timeline for that
deprecation is just an implementation detail of a plan to remove something; it's the removal that needs to be discussed in most detail
 
I think BC impact would be minmal as there's already an identical, better exposed, easily searchable way of finding it
 
BC impact isn't about how to write new code, it's about how to fix old code
which includes: how commonly used is it, how easy is it to find usages, and how easy is it to replace those usages and get 100% identical behaviour
 
ls becomes shell_exec("ls")
Chat filters them out, go figure
` testing `
testing
 
not filtered, interpreted
 
11:40 AM
`ls`
@MarkR add a \ before the first `
 
because apparently everyone except me loves Markdown
 
@IMSoP it has it's benefits
 
Well it's used for the greatest sum of knowledge humanity ever compiled, so yeah :P
 
@MarkR if you're talking about Wikipedia, then, no, that's a completely different syntax
 
I meant readme.md files, but yeah
 
11:42 AM
lol
 
meh, README files predate Markdown by decades, and work perfectly fine in plain text
 
Hello. Where can I find a discussion about good text readers to use on Windows? Google isn't helping.
 
if you need formatting in your documentation, build a website :P
 
@ahorn I think you are confusing this room with the good text readers for windows room
4
 
I'm not sure where the general chat room is.
 
11:46 AM
@ahorn I'm not sure this is even the right website to begin with; maybe softwarerecs.stackexchange.com would be a good place to ask
 
Ok.
 
be sure to search for existing questions and read their FAQ first, of course :)
@MarkR regarding BC, the key is to put yourself in the shoes of someone who is charged with maintaining a massive application which they didn't write, and doesn't have test coverage; the scope of the BC break is the steps they would need to follow to have confidence the application was working 100% the same as before after removing the feature
 
@IMSoP platforms like github, packagist, npm etc automatically parse the md and format them accordingly, so it makes sense to use md in these scenarios, and some documentation generating software like the ones available for github.io or gihub wiki itself also support md, so it makes sense to just write md rather than create a whole css library for your documentation etc
 
@IMSoP A simple token replace using double quotes should get the job done. There's no logical change per se
 
@MarkR I'm not saying it's complicated; I'm just saying that's how BC breaks should be presented in proposals
 
11:50 AM
@ahorn this isn't bad
9
 
IMHO
we should do better than "it's basically the same, and probably all you need to do is this" and say "if passed, these instructions will be added to the manual explaining precisely how to fix existing code and if there are any subtle differences to worry about"
@mega6382 yeah, I'm mostly just being grumpy; still, if those platforms didn't render Markdown, I'd be perfectly happy with plaintext
my point about building a website was that if your readme is 50 pages long, it probably shouldn't be a text file in the root of your repo in the first place
 
In a docs/ dir... with 50 different .md files xD
 
@PeeHaa Count me in!
Been trying to read through grafana's repo but christ there's a lot of it.
 
@DaveRandom It's been a while I fell for it :-P
 
@MarkR yeah, and then you start extending Markdown to have includes and automatic navigation and it ceases to be a simple format
a couple of years back someone was advocating rewriting the PHP manual in Markdown, but in order to preserve the current features, they would add a bunch of special tokens that replicated all the features of DocBook
it sounded like you'd get the ugliest markup language in the world
 
12:00 PM
I'm working on rewriting the entire manual
 
Specifically I'm working on making a functional UI with multi language support php-doceditor.markrandall.uk
 
a replacement for edit.php.net is definitely welcome; but converting XML to JSON underneath is a massive WTF for me
 
Just easier to work with as an intermediary format.
Can still spit out XML as the output
 
surely the intermediary format is JS objects
XML -> JSON -> object -> JSON -> XML feels like adding more layers to debug
 
12:03 PM
JSON already is an object, there's no particular need for the middle conversions
 
no, JSON is a string
 
By that logic so is XML
 
yes, it is
so you parse the XML into objects
you don't need JSON in between
you need an XML parser
 
I find XML fugly to work with tbh, there's a reason JSON made it near obsolite
 
but if you're not doing string manipulation, who cares?
 
12:05 PM
ಠ_ಠ
 
foo = new ManualSection; foo.content = 'hello world'; export = serializeToWhateverFormatYouWant(foo);
 
XML is good, it has semantics and mature standards which use it. JSON is a free-for-all, which is also bizarrely picky
 
I mean, now YAML is being used as an intermediary for JSON
 
/me throws up a little
 
12:06 PM
[head explodes]
 
Not a fan of YAML myself heh
 
/cc @Jimbo
 
99% of your code shouldn't care whether the serializeToWhateverFormatYouWant function produces XML, JSON, YAML, ASN.1, or EDIFACT
 
can it make T-shirts?
I need some more socks as well
 
what it absolutely shouldn't do is execute some homebrew pipeline that converts to each one in turn, slightly mangling the structure each time because the data models are subtly different
 
12:08 PM
There still needs to be a way of storing the "working" data before it's rendered
 
The YAML spec is larger than the XML spec
And it's whack
 
@MarkR why? what's the difference between "stored working data" and "rendered"?
in memory, you have objects in whatever language you're using; when you store, you have some sequence of bytes
 
@Girgias have you read the JSON schema spec?
 
@DaveRandom no, and I don't want to because I do think XML is a well suited format
 
@DaveRandom Which one? The number ones or the date based one :P
 
12:09 PM
JSON won out because it has native support for objects, ordered arrays and scalar types.
 
YAML has so many ways of writing strings that people have written tools for exploring them all: yaml-multiline.info
@MarkR JSON is really great for small ad hoc data packets
that's what it was invented for, and it's still the best for them
 
all of these formats which have arrived to "replace XML because it's too complicated" are now in the process of having all the complicated bits tacked on the side, because it turns out that they are too simple. It's almost as though the XML people actually knew what they were doing, and the people who think it's too complicated don't actually understand the problem it's solving. Just saying...
swagger in particular is busy making all the same mistakes as SOAP, only in a format with weak semantics. Sounds great.
 
Going to need a [citation] on that one Dave, because I'd say pretty much every API and the likes I've used in the past 5 years has returned JSON, not XML.
 
@DaveRandom precisely! horrible though SOAP is, it's kind of interesting seeing XSD and WSDL being reinvented but in JSON
 
I pass almost all the JSON I use through Justinrainbow's JSON Schema, it works well
 
12:11 PM
@MarkR the citation is the number of projects there are to implement schema and service description languages for those APIs
 
@MarkR yes, with absolutely no standard way to validate it
I will freely admit that XML is unnecessarily complicated for a lot of things
tools for jobs
it's all about semantics. I'm not sure whether the PHP manual needs those semantics, but the fact that they are there enables the production of a jillion different output formats
 
@MarkR Does that also support the latest spec?
 
I don't think we need those output formats any more, though
 
I'm not sure off the top of my head PeeHaa. The last push was a month or so ago on Github if that's any indication.
 
Morning
 
cmb
12:16 PM
JSON isn't a markup language; it's great for data, but that's about it, IMHO.
 
^
 
Well data was what I was talking about re: a docs editor
 
Anyway I'm off, having lectures again (erf)
 
cmb
"Netscape 6.0 is finally going into its first public beta."
Oh, totally missed that. ;)
I won't mind which format is used intermediary, but I would mind if existing XML would be reformatted.
 
IMO it makes a lot more sense to just spit out docblock or whatever from an intermediate format. Because zomg that multi language stuff :|
 
12:22 PM
@JoeWatkins I should have some time next week to pick those up
 
Ultimately it's a choice of how accessible do you want it to be to work with
 
@Sjon What did it not fix?
You also need to add necessary lexer support
 
@NikiC I started testing with typed-properties, but those aren't recognized
 
12:42 PM
@Sjon no idea then
typed properties are definitely supported and also don't need lexer support
 
@MarkR surely documentation is the perfect example of needing "markup" rather than "data"?
 
It needs both @IMSoP. Data to define structure and markup to define contents
 
true
but XML can do both
JSON, on the other hand, can only do data
e.g. the value of <arg>haystack</arg> is interpreted as a <type>string</type>
that's going to be ugly as hell to represent in JSON
 
Nah, just use the same tags
 
@NikiC thanks. Apparently the worker was still using the old sources. Typed properties work, but Arrow functions don't
 
12:50 PM
but then you have two formats
again, it just feels like unnecessary complexity
 
It's solving two different problems
 
<note>the value of <arg>haystack</arg> is interpreted as a <type>string</type></note> vs {"note": "the value of <arg>haystack</arg> is interpreted as a <type>string</type>"}
either of those can be the output of note = new Note('the value of <arg>haystack</arg> is interpreted as a <type>string</type>'); note.serialize()
 
Does this chat support bold
 
@IMSoP Mark is a software developer. Mark is trying to solve a problem where data is represented in flat files. He decides to use JSON. Now Mark has two problems.
nothing personal @MarkR
:P
 
haha
 
12:52 PM
Honestly if I could have my own way i'd have transferred the entire thing to a database and had the entire thing up and running a week ago :-)
 
I think you're not thinking modularly enough
the sequence of bytes on disk, and whether it's in SVN, Git, or MariaDB, should be invisible to the editor component
 
Yes, but in reality those represent very different challenges.
 
trying to change them all at once makes the job harder, not easier
 
Only if you're not ambitious enough. Try to cut a tree down by chopping an inch off at a time and you're going to expend a lot more energy than taking a chainsaw to the bottom of it.
 
that's why I linked the Joel On Software article earlier
it's exactly the thinking that killed Netscape
 
12:56 PM
I was under the impression that IE killed netscape
 
sure, but not releasing a new version for several years while they tried to rewrite everything at once definitely didn't help
 
@Sjon you'll have to add the fn token to the lexer
 
you have to find the happy medium between cutting an inch at a time, and growing a new forest
 
I have no social life, when I set my mind to a project like that I literally do nothing except eat and sleep until it's done.
 
these analogies are terrible, FYI. :P
@MarkR if you wrote some code in between eating and sleeping imagine how much faster it'd be finished :P
 
12:59 PM
lol
anyhoo, I'd better get on with some work before my boss notices ;)
 
... lmao, okay yes you have a point
 
m.imgur.com/7EkJRM0 @PeeHaa @DaveRandom @Danack
 
1:13 PM
@NikiC thanks. Now fixing Syntax error. Unexpected ???
 
1:49 PM
Hey, what conference was everyone going to?
 
barcelona
 
Ah man, if it was IPC in Munich I could have probably gotten an all expense paid trip >.<
 
who makes a conference tuesday-wednesday.. :|
 
@pmmaga One targeting professionals that can take time off or have work-sponsored trips.
 
they all kinda are, I just find it a weird schedule. in the middle of the week
I'm just complaining because I wanted to bundle it together with going to the office for a week and the fact that it is on those days messes up my plans :P the weekend would have been perfect
 
1:55 PM
Joys of being a consultant, no work sponsored trips \o/
 
@MarkR Or all trips work sponsored? :)
 
Wes
is this bwoebi or kelunik speaking in the amphp tutorial youtube.com/watch?v=kfVsfOSbJY0 ? sounds germanish
could be also @PeeHaa. which as we know, is german :B
 
@StatikStasis lol right in the kisser :D
 
@Wes :P
 
2:14 PM
@NikiC Permission has been granted to you by the supreme overlord. =P i.imgur.com/RFbqkD7.png
 
^^
 
@Wes do you have vector images of the amp logo(s) for me?
 
Wes
they are in the amphp web repo iirc
 
tnx
 
2:50 PM
realpath function does not return false – #78634
 
3:02 PM
Using MySQL I calculate metrics per user across order_items - e.g. SUM(order_items.price)
I can do the users average order price by doing SUM(order_items.price) / COUNT(DISTINCT order_items.order_id)
Is there any way to do something like that for MIN / MAX
i.e. getting each users MIN and MIX order total
But without grouping the results by order?
The metrics are more complicated than the price (e.g. calculating profits) so that information isn't stored directly on the order
 
@PeterTheLobster I'd strongly recommend doing it in PHP. Until your customers have thousands of purchases, that will work fine.
 
Sounds like a job for a subquery to me
 
@Danack Why PHP? Aren't databases generally faster for these sorts of things?
 
I'd certainly try to do it in SQL if you can.
 
It will be slower and buggier to write code in SQL than in PHP. And until you have customers and enough purchases that slowness is a problem, doing it in SQL provides no value.
 
3:06 PM
The metrics are more complicated than the price (e.g. calculating profits) so that information isn't stored directly on the order more complicated, but are they still derivable only from order information? Or do you need external info?
 
@ircmaxell No, they are only derivable from the items that were ordered
 
@PeterTheLobster gabi.dev/2016/10/17/understanding-generated-columns if you're using a modern version of MySQL, then a generated column may solve that for you (may)
 
@ircmaxell I'll think about that but last time I checked I think there were some restrictions imposed on those that ruled them out for some job and I think it was using conditional statements but I'm not sure
 
docs.google.com/document/d/… could I have initial comments please (before putting it on the wiki where the rfc bot will pick it up)
 
@Danack This is part of system for reporting business metrics to the client. There is a lot of data aggregate - sometimes across all orders in a given year so MySQL made more sense to me tbh.
 
3:13 PM
If it's only for a report, check out dev.mysql.com/doc/refman/8.0/en/window-functions.html (though I'd suggest only using that for analytics/reports, not normal business logic)
 
This iis my example of most expensive order per user using MySQL 8, @PeterTheLobster
You could also use a Common Table Expression. Those features (I don't remember if the LATERAL JOIN is) like Window Functions and CTEs are available on Postgres too
 
Wes
@MarkR maybe @DaveRandom can add something. i remember him saying something about the escape working dangerously or something like that in some platforms
 
@MarkR nitpick: depreciation -> deprecation throughout
 
Good catch
 
3:19 PM
I don't really appreciate the backtick operator though
 
wouldn't depreciation just mean it was worth less and less over time
 
@ircmaxell Yeah I explored that possibility but atm we are on 5.8 and that didn't support window functions yet I think.. Thanks anyway I got plenty of suggestions here so I'l figure something out :)
 
@IMSoP If it's deprecated it will be worth less :)
 
@PeterTheLobster good luck :)
 
Any other feedback before I put it up as draft and get flamed to hell and back for it?
 
3:23 PM
The only use for the backtick operator i can imagine is the use in some exploit for sanity check evasion. Nothing else.
 
@MarkR I will wait with my feedback until the vote is almost done
 
Like I mentioned earlier in here, I've no plans to go to war for it, but I think the Q should be asked and voted upon all the same.
 
@MarkR Could you write a script to convert existing usages of ` to shell_exec() (or a suitable alternative)?
I think having that when you propose to say "Yes, it's BC, but it's trivially solvable via a tool like this" could make it easier...
 
Should be pretty easy to do using any of the existing PHP parsing tools yes maxell
 
@ircmaxell That should be the default where possible imo
 
3:26 PM
Oh, I know it should be easy, I'm suggesting having the tool written and ready when the proposal is made (and included in the RFC)
 
Reactor is pretty decent btw
 
Reactor would be my go-to
 
*rector sorry
 
I made that naming error so many times I just call it reactor now :P
 
Yes. Include reactor migrations into every rfc would be pretty fancy.
 
3:28 PM
@MarkR :-D
 
I mean for all changes refactorable by that
 
3:44 PM
yes, precisely that
and the exact text ready to paste into the Manual as well
 
@ircmaxell following your crypto bag signals the other day, you're as good a person to ask as any. Do you have any contact (or contact of a contact) with Max Bubenick?
 
Don't know that name
 
Well that's posted and to the ML too. Either which way it goes, I think it's worth asking.
 
@ircmaxell I believe he works at Percona, but more interestingly he's the author of mydumper
 
4:03 PM
@MarkR My opinion: :thumbsdown:
 
Good job I'm not fighting lions then isn't it?
 
@Stephen not sure. @gabidavila doesn't know him either...
(she has way more contacts in the database world)
 
@ircmaxell no worries, thanks anyway. Just hoping someone would give him a poke and find out what's going on - if he's given up on the tool or just busy.
 
4:38 PM
cc at least @mega6382 @Ekin @Sean because they were specifically asking about it
 
so this PeeHaa dude tells me I'm the only one who compiles php from source
How many others in r11 compile php from source, and also run make test on it? :-P
Genuine question.
 
Seeeeeeee
:D
 
@Ekin I have only done a it a few times, mostly on opensuse, but I have never ran make test on it.
 
thinking I did it on all the versions I installed locally
If I'm installing it on a server I might just grab it from the repo and all but say, if someone like @PeeHaa makes me get an RC locally... might as well just test it and play around :-P
 
@Ekin I did that once only, when I needed to install multiple version, and I chose to compile from source only to see if I could on windows.
 
Deleted it @mega6382 to prevent too many shitty PRs :)
 
lol
 
There again \o/
:-)
I will also be updating the full stackoverflow example of the bot if you want to play it @mega6382
 
yes, definitely
@PeeHaa have you created any plugins for the new jeeves yet?
 
4:55 PM
I have a basic stack overflow chat client, imdb plugin, basic example timer plugin and an half arsed tested wikipedia plugin
oh and the github status checker
 
cool, I would like to work on wotd and dad plugin, if I may
 
aye
I will create both repositories with just a readme and a basic composer so that you can just PR to it
 
02:00 - 17:0017:00 - 00:00

« first day (3275 days earlier)      last day (1670 days later) »