« first day (3665 days earlier)      last day (1507 days later) » 

00:08
@DaveRandom I recently heard a complaint from a coworker why we don't have an in operator in PHP (it being easy and trivial to remember if you know python or JS) - something I proposed like 6 years ago and got shot down on exactly these grounds
@bwoebi that's actually the specific example that came to mind :-/
00:23
Maybe nowadays there's more willingness … but I sort of doubt it
at least enough willingness to pass the 2/3 vote
 
2 hours later…
02:03
@bwoebi used for looping?
@DaveRandom you don't what any reason? wat
 
5 hours later…
07:00
Deprecating password authentication ・ API Requests has Under Maintenance
Good morning.
@DaveRandom we will, very soon. Currently, we are working on autogenerating the signatures for the manualy and we had a nice progress recently.
07:34
morns
cmb
cmb
08:27
@DaveRandom null is allowed to skip that arg for quite some time, see heap.space/xref/PHP-7.2/ext/json/json.c?r=7a7ec01a#297
Wes
Wes
08:40
@PeeHaa code works most of times, sometimes it hangs. i think it has something to do with writing files on windows
yield pipe($response->getBody(), yield open($mediaPath, "w"));
is this correct?
i am using a old amphp version, not the time to update yet
09:12
SegV on assert with phpunit ・ Reproducible crash ・ #80290
09:23
Data loss on session_write ・ Session related ・ #80291
Wes
Wes
i've simplified code and i am fairly sure i got it right, even if i don't get why i get promises where i seemingly don't need any
09:57
Hello there! Someone working with Laravel?
All issues have been resolved!
stackoverflow.com/questions/64554594/… Someone can help me with these question? I struggling with this but I still can't figure it out.
Deprecating password authentication ・ API Requests has Under Maintenance
All issues have been resolved!
alright, chill out
Deprecating password authentication ・ API Requests has Under Maintenance
All issues have been resolved!
 
1 hour later…
11:18
Can anyone tell me how this example from PHP Manual works? php.net/manual/en/mysqli.commit.php
@Dharman Which part? ^^
The transaction. I can't imagine that this would ever work like a true SQL transactoin
If the second query fails, the first one is still committed.
@Dharman But autocommit is disabled?
But there is commit right after.
the commit will be executed unconditionally since there are no exceptions
I just tested in locally and the first query is submitted into the database, but the second is not, which is the normal behavior without transactions
Either this Manual page lies to me straight in the face or I am not understanding how transactions work.
I have written a proper documentation on Stack Overflow stackoverflow.com/questions/12091971/…
Okay, i get what you mean now. I agree that the example is not good
11:30
@Wes Shouldn't pipe have a callable as the second param?
@PeeHaa did you see my messages?
I did now you mentioned them :P
1 sec
Wes
Wes
@PeeHaa outputstream instance
i am using a very old amp version... will update as soon as i get this thing working again
I think I did it all @mega6382. Let me know if I need to do more
@Wes I don't see that accepting a outputstream at least since 2015
Wes
Wes
well the code is old but not that old
11:40
:D
What instead of piping instead just write it out?
Wes
Wes
some files are over 300mb so they should go straight to files
You can stream it right?
@PeeHaa thanks
Wes
Wes
@PeeHaa what do you mean?
Wes
Wes
11:56
congrats @pmmaga \o/
cmb
cmb
@Dharman so basically something like:
if (query1 !== false && query2 !== false) {
    commit
} else {
    rollback
}
feel free to provide a PR (using the class account transaction example might be even better)
Or you know like a sane person enable error reporting
Imagine you have not 2 but 20 queries
Keeping a variable for each and trying to executing all 20 of them even if the first fails is an overkill
I'll see if I have some time i might write a PR
oooooh @Wes
You are using bytestream\pipe not amp\pipe
Wes
Wes
yes
Where does it get stuck when you write it out?
Wes
Wes
12:10
hard to tell
if i run through the debugger it takes ages to do anything
$file = yield open($mediaPath, "w")
while (($chunk = yield $yourStream->read()) !== null) {
    yield $file->write($chunk);
}
Wes
Wes
i threw some echos randomly just to see where it would stop and it stops on that line
What line?
Wes
Wes
the pipe line
@PeeHaa isn't this what pipe does internally?
yes it is
But you have more control over what is going on
You can pinpoint exactly where it gets stuck
Wes
Wes
12:12
imho it's some windows bug
because i ran it for 3 hours yesterday and worked like a charm
Could very well
Or an old amp bug
Wes
Wes
will try to update
Either one of those are equally possible
Wes
Wes
i am polishing it and at the same time simplifying code. it's not much, should work, so must be something else
How old is the code (and amp deps)?
Wes
Wes
12:17
2.3.2
At least it is 2 :D
Morning all!
Morngins o/
12:27
Incorrect use of code in manual's example codes. ・ Documentation problem ・ #80292
 
1 hour later…
13:28
@Tiffany no, for contained in checks
(in_array, strpos)
13:45
When testing against MySQL 8 and MariaDB I get two different error messages.
```
Fatal error: Uncaught PDOException: SQLSTATE[HY000]: General error: 1366 Incorrect integer value: 'true' for column 'some_bool_1' at row 1 in C:\xampp\htdocs\formatter\rubbish.php:114
Fatal error: Uncaught PDOException: SQLSTATE[22007]: Invalid datetime format: 1366 Incorrect integer value: 'true' for column `test`.`test`.`some_bool_1` at row 1 in C:\xampp\htdocs\formatter\rubbish.php:112
```
Is there a way to handle this in EXPECTF?
cmb
cmb
@Dharman you can use placeholders (%s to expect some arbitrary string). Maybe something like:
Fatal error: Uncaught PDOException: SQLSTATE[%s]: %s: 1366 Incorrect integer value: 'true' for column %s at row 1 in %s:%d
ok, thanks, let me test it
14:49
@cmb ah, raymond. his posts either bring joy, or the opposite of joy.
cmb
cmb
:)
what karma would I need to delete comments on bugs.php.net?
@Danack Just an account should do IIRC
Are you trying to do it on master.php.net or the docs directly?
> bugs.php.net
14:54
oooh bugs :|
Sorry. I should have read more carefully
@salathe ta. I'm going to wait until I crack my neck one more time (so I don't feel quite so much like shite all the time), and then do the needful.
15:27
mornin
15:39
@cmb IMAP is truly being a pain with these 3 tests D:
cmb
cmb
yep; and I just found that some Win mail tests require the same kind of setup ;)
@Derick there are some errors in the speech to text of phpinternals.news/56 . do you accept PRs?
16:00
Deprecating password authentication ・ API Requests has Under Maintenance
wat ^
this is like, ssh authentication password and not like, actual site UI auth login I presume
think it's basic auth with generated keys or something
I've been getting emails about something on my computer still using that api.....and will stop working at some point.
didn't read the details...
ah yes, that sounds like something I've done to not login on each remote git command once or twice :)
16:21
@cmb @NikiC What do you think about this example? 3v4l.org/WiCEu
cmb
cmb
16:32
@Dharman I like using exceptions here, but I think an explicit mysqli_rollback() wouldn't be bad (in case of error). I also think that one example would suffice for mysqli_begin_transaction(), mysqli_commit() and mysqli_rollback() (example only on begin transaction page, and the other pages can link to it)
I am actually thinking of making slightly different examples for each
OK, maybe you are right. I can make it generic
You can make generics? fantastic!
I can make everything, I know PHP
Ok, how about this? 3v4l.org/9jIdh
Do I just copy it to the other three? How do I link them?
cmb
cmb
16:48
yes, that looks good to me (I, personally, wouldn't use FQNs for examples)
to link, the mysqli_begin_transaction example would need an ID (say <example xml:id="mysqli.begin-transaction.example.basic"), and then you could do just something like See the <link linkend="mysqli.begin-transaction.example.basic">example</link>
Do you have some guidelines or is this just preference? I feel that at least for Exceptions we should always use FQN since this might be a very difficult to identify bug.
cmb
cmb
17:01
No more like personal preference, but we don't use FQNs in the function signatures as well. And frankly, I don't think these examples should actually be copy-paste stuff, but rather give some idea of how to use.
I tend to agree ^
Concur.
twitter.com/erincandescent/status/1321468283783127040 - Go folks: 1.15 and older don't support the new "slim" zoneinfo format that became the default in tzdata 2020b, causing DST to become permanent.
@Derick ^^ of interest?
@mega6382 all fine buddy .. what about you? is everything ok?
17:11
@Danack It's not a problem for PHP until 2038.
(unless distributions change what PHP does)
@Shafizadeh yes, everything is good, thanks for asking
17:48
If this was removed in PHP 5.3 why does the header say PHP 7? php.net/manual/en/mysqli.rpl-query-type.php
@DaveRandom That's crazy!
18:06
@Dharman because it's wrong?
@Derick Cool. Are there any other 2038 things you're aware of? I might start a list....
nope
FWIW, this does need fixing, but it's not high on my todo list
(I'm hoping that MongoDB will contract me to do this, as they will run into this problem soonish)
o.o
@cmb I have submitted a PR. If I have made any typos let me know and I can adjust.
@Danack @cmb Can I submit a PR to remove mysqli_rpl_query_type and mysqli_send_query or at least move it to php.net/manual/en/ref.mysqli.php
cmb
cmb
@Dharman I'm already at that :)
"PRs welcome" is a universal rule. And in this case it's not even sarcastic....
18:26
@Sara Charlie is aware.
18:40
@GabrielCaruso Looks like something with generators has changed in the last week or so, but it's not mentioned in github.com/php/php-src/blob/PHP-8.0/UPGRADING.INTERNALS
@GabrielCaruso github.com/php/php-src/commit/… is the commit
18:57
Is (1 << 32) > 0 a reliable way to check for 32/64 bitness (in PHP)?
Just check PHP_INT_SIZE (or PHP_LONG_SIZE) for 4 or 8 ?
@Derick ah, nice. thx
All issues have been resolved!
@Jeeves 2 hours later?
Deprecating password authentication ・ API Requests has Under Maintenance
oniguruma not bundled in mbstring extension per docs ・ Compile Failure ・ #80293
19:04
@PeeHaa a new PR has been made
@Jeeves lol
All issues have been resolved!
Alright. I am just about to call it a day. So now is the time to point at things I need to look at and tell what to do :)
Deprecating password authentication ・ API Requests has Under Maintenance
But I basically just copied the functionality from the old code, I will try to optimize it a bit later, when I add the tests
19:05
All issues have been resolved!
@Jeeves you ok?
@cmb When I want to process a refentry document with DOM, I get "Entity not defined" errors, because DomDocument doesn't know about reftitle.seealso et al. Do you have any suggestion how to solve the problem? I have 3 options: suppress the warnings by providing LIBXML_NOERROR, using another extension (XMLReader maybe?), or falling back to pure regex :) Which would make the most sense?
Deprecating password authentication ・ API Requests has Under Maintenance
All issues have been resolved!
Update: Option 1 doesn't work, processing the file fails immediately
@PeeHaa Thanks. Naming things is hard, I didn't know what to call those files and folders, so I just went with what came to my mind. Also, tomorrow I will work on adding "pin" functionality to the SO chat driver.
19:13
@MateKocsis You would rather need to pass the option which disables the DTD check
Oh wait it's the entity
There is something about partial output in PhD but not familiar with it
@Derick I need to keep track of that as well, right? My bad!
@Girgias yeah, I can't find any related option. No matter how shameful it is, using regex seems like the best solution so far :D
Btw any timeline on the generating Class entries from the stubs PR? :D
Can I put an alias at bugs.php.net to bugs.php.net/…?
uh... why would Travis suddenly miss my "xdebug" repo?
hm, not sure if you (or me) can edit them ther
19:25
@Girgias :D I think it's mostly ready, waiting for review. There's a pending question in connection with iterators, though. I hope that we can revisit it once the methodysnopsis generator stuff is done. :) Hmm, are you asking it because you want to add new classes? :P
urgh, people are really still adding PHP 7.1 support to their stuff? =_=
So I recently had an SDE interview (managerial round), where they asked me that if on a given day I had an overwhelming number of high priority tasks, how I would approach the tasks. Can anyone pitch in how one should actually handle this in a real life situation and also how to answer something like that in an interview?
I would say look into prioritizing them and also look for some low hanging fruit
@twodee first:
But also.....that's a good question, as it reveals if the interviewee has ever had to deal with that situation, and did they have a plan or just run around waving arms in air.
It's also a disturbing question.......you should ask them, exactly how many days a year are their developers having to fight fires....
cmb
cmb
@MateKocsis ugh! If DOM doesn't work, XMLReader won't either. It's probably best to go with your the most comfortable. :)
19:35
@cmb Yeah, it didn't :) I would have happily used an XML tool, though.
A reasonable answer might be, quickly estimate how long each one will take, and then ask whoever answers to the finance director "which do you want us to work on first?". If they don't answer, start work on what you think gives the quickest value for the effort.
/and then go home and update your CV to start looking for a better job.
I said something like, I'd look for the easier tasks, do them first and deal with the bigger ones later. Then I asked if I have someone else who can help me out, and they said that I have a colleague who's free. So, I said, "well, if the work is unbalanced and they're free, I'd ask them to do some of the easy quick stuff while I deal with the harder ones".
cmb
cmb
@MateKocsis I'm no XML expert. Maybe @beberlei has some suggestions?
And if I still see this is a lot of task, I'd need to talk to my team lead to help me prioritize the tasks or update the scope of the project if it's really that overwhelming.
@PeeHaa Yeah, I did figure something similar would make sense.
Hi
who has been used this opensource?
19:40
@Danack I will keep that in mind, "which do you want us to work on first?" sounds like a good question to ask back.
what is required for using telegram bot opensource except api token?
@MateKocsis well I've got the branch/PR on my repo about the throw_on_error declare and that needa adding a bajillion classes for specific cases, and currently it's manually lol so that landing would help it a lot :P
19:56
If anyone ever needs a good example, apparently the shutting down of the faker library is an example of choosing to close a project down, rather than have to talk to GC any more: github.com/fzaninotto/Faker/pull/2063#issuecomment-712938133 github.com/fzaninotto/Faker/pull/2063#issuecomment-717118799
He is like GPL
Only worse. He also infects projects he is not linked to
20:21
The PhpUnit issue is really pervasive for projects that still support PHP 5. I suspect this plus future versions of composer not supporting PHP 5 at all may finally kill it.
But I could be wrong, of course.
21:06
ALL PROJECTS SHOULD IMMEDIATELY DROP ALL SUPPORT FOR PHP <= 7.4
@LeviMorrison Juliette made a thing: twitter.com/jrf_nl/status/1320690339519352832
EIGHT POINT OH, OR GEE TEE EFF OH
...
@Danack Thanks. Symfony has a bridge too, so now I have choices.
@Sara Unpopular opinion, but I think it's still okay to run PHP 7.4 now :P
21:22
@cmb I dumped regex, it works really bad in case of a hierarchical document. So I worked around the issue with DOMDocument by... - please don't judge me - replacing the entities with a dummy string :D Works like a charm, recommended by 10/10 programmers.
@NikiC Heretic.
((Just so people know I'm not serious, I think anything >= 7.0 is still perfectly fine. Provided one understands where one's security patches are coming from...))
But anyone on <= 5.6 is bad and they should feel bad.
Does anybody really know?
@PeeHaa we need a phrase for when people ask a question, and then refuse any attempt to give an answer that doesn't meet their predefined expectations.... e.g. for en.reddit.com/r/PHP/comments/ji6oge/…
you got anything?
other than users.jpg
21:38
round hole square peg comes to mind
square peg round hole?
One of those?
21:52
Neither one fits.
Or, both fit in context.
segfault reading or writing to ssh2.exec:// (or shell) stream ・ ssh2 ・ #80294
@Sara What if you are on paid support for PHP 5.5 from Canonical? (this is not theoretical, I've encountered such customers)
IIRC it ends April 2022.
@LeviMorrison Charge 50% more for each version behind 7.3 they're running for pain and suffering. In a month you can charge it for anything pre 7.4. :-)
cmb
cmb
@MateKocsis that's the spirit – make it work! :)
22:43
@PeeHaa i was hoping for something more like 'precommittent to facts' or 'alternative avoidance'..... perhaps the twitters will know. twitter.com/MrDanack/status/1321582973179879424
22:57
@Crell If you want they hate you. If you want they love you, make PHP5 price and discounts for upgraded versions. :P
23:16
@twodee That shouldn't even be a question, it should already be prioritized for you.

« first day (3665 days earlier)      last day (1507 days later) »