« first day (1438 days earlier)      last day (3510 days later) » 

10:02 AM
@JoeWatkins got my ping from this night?
 
didn't show me again, sorry
 
12 hours ago, by bwoebi
@JoeWatkins I have some random todo I encountered while working on the xml protocol. Had to review the whole code so… Anything from the list below you'd like to do? :-)
12 hours ago, by bwoebi
- check if an exception will remain uncaught; if yes, remain in that frame
- introduce custom error handler to catch fatals and remain in that frame
- run/clean: ask if should restart/stop (y/n) via bailout to run, same for wait
- stepping attribute in print command returns always false? rather inform about line/opline stepping type
- sh command, allow stdin
- watchpoints resolve escape sequences
- make watchpoint internal pointer optional (via set command)
 
oh I saw that list, you wanna open bugs for that stuff ?
and assign yourself when you start and I'll take some if I can ...
 
I'm still busy with xml protocol etc.
 
ok cool, keep it around then ... if I can I will ...
 
@FlorianMargaine wtf
 
Yeah I looked at the code and found that.. Wanted to confirm if it was that shitty... It is...
 
Well... I rely on the extension of a file to know its type so...
why isn't that good enough for most cases?
(I suppose it's that edge cases that make or break many things, though)
 
Depends if user input or not
And that lib does not explicitly state that it does not make it safe to handle user input
 
I'm a little bored of the "this is bad practice, don't use it" response, which now tends to be (by people who consider themselves experts, or are considered experts): "well, there may be a use-case for this, here's a really contrived, out-of-the-way example to demonstrate how big my ego is". This is about igor btw.
 
10:11 AM
@NikiC this isn't a case where it does.
huh ?
you don't think there's a difference between the recursive call implementation and the goto one ?
 
@JoeWatkins Between the non-recursive one and the goto one ;)
tail call optimization is something entirely different, but nothing to do with goto in that case
 
clarify that, the issue states "May I ask if there is a reason why you prefer using goto instead of function recursion?"
 
> I wanna meet dinosaurs
 
^ YES!
 
Rob
Hi All
wondering if I could get a little help on something
Im trying to understand how this loop works
for (l = 0;
(p + l < firstLength) && (q + l < secondLength) && (first.charAt(p + l) === second.charAt(q + l)); l++)
;
l is the iterator
and increments
is it basically going up by one while the middle part of the for loop is true ?
 
10:27 AM
@Rob it determines the length of the common substring between first starting at p and second starting at q
 
@Rob danm that is an unreadbale mess
 
OH: "The problem is if the child DOESN'T die"
 
The person who wrote it is an idiot
 
On process children, obviously ;)
 
Rob
:D
its php js - I just realised
sorry I asked this in the PHP room
your right it is a mess
 
10:29 AM
@Rob It's both crap. Just different crap
 
Rob
hehe
 
Although JS is in an even worse state than php imo
 
Rob
this is what its based on
 
@Rob For future reference, if you're ever writing anything like that, create your variables above, named really well, and a nice long comment explaining it
 
Rob
 
10:29 AM
Does anyone else ever apologise for something in their code, in comments, for the future developer?
 
Rob
maybe even a health warning
 
lol
 
0
Q: How to see authanticated user in annoymous section in symfony

StaticVariableI have a little problem in project with symfony. I am developing a article website in which normal visitor can see all the article without login and admin can login and add or remove article but admin can remove the comments that are marked as spam in article page after login.The problem is that...

 
Rob
My company wants me to get the function working in VBA
So I tried to find the similer text thing from PHP
 
Rob
10:31 AM
really nice function for compareing text and producing a %
 
Rob
instead of using the PHP js thing - could I use the PHP source code ?
 
@Jimbo Yes I often refer to "future me" or "next person who sadly enough picked up the project after me"
 
Rob
Just want to find the inner workings of similar_text()
 
@Rob Then view the C source, PHP is OSS you know.
 
10:33 AM
@Jimbo Usually myself
 
hi dear can u tell me which data model best for cart project ?
 
@Rob Just implement it yourself
 
Also @Jimbo:
 
> This calculates the similarity between two strings as described in Programming Classics: Implementing the World's Best Algorithms by Oliver (ISBN 0-131-00413-1)
 
Not just me then haha
 
10:34 AM
@AkashDeep Only deers here sorry
 
Rob
ok I will have a crack
thank you :)
 
@Rob What the shit
 
Anyone used OtterBox Commuter phone case, something, something?
 
hey @Rob, not written any VBA for a while... I'll race you :-P
 
Rob
10:36 AM
lol
wanna head start?
 
Nope, that would be cheating
 
Rob
warning: may cause migraines
:P
I have something that kinda works
 
Oh believe me, I am acutely aware
 
Rob
but some strings produce percentages above 100
so when I say kinda
its with a smile
 
> i wanted to know if there is a way to do URL masking somewhat without the use of .HTACCESS file
 
WTF. OPs are now just randomly dropping somewhats in the middle of sentences
 
I tried to find a duplicate but couldn't
If anyone gets a chance to hammer it with mjolnir, take it.
@PeeHaa I don't somewhat see what you mean.
 
You mean they are somewhat answering it right? — PeeHaa 14 secs ago
 
@JoeWatkins okay, added all the issues. Now have fun! :-D
 
10:48 AM
 
I have no clue. Might be the case but OP refuses the further explain
 
Hello I have one problem in my website when i simple click on reload page icon then it show me jquery function error ... Can u please tell me the solution ... me using cake php
Please guys tell me ?
 
jquery and cake php, my two favourite subjects.
 
11:04 AM
@AkashDeep Without any code or a specific eroor.. There is no way we can tell you the solution
 
ya it show me jquery function not found in debuger
 
well, then, jQuery is not there.
 
@DaveRandom I read this the other day when I was deploying something that I'd have rather set on fire and thrown off a bridge; it too, was a parser. I have commented said code thusly.
 
but when i press control f5 then everythink going good ..
 
11:09 AM
I don't know if the code will survive long enough for me to forget about it before I have to go back and fix the mess, but hopefully it does.
> Y U GET SO MAD WHEN I SAY GIMME MODEL!? FINE! I SAY GIMME DOMAIN!
Aaaand now we have "Action Domain Responder", which is really just "MVC" with the letters switched around.
 
@Fabien lol
 
Action Domain Responder, I will ignore this.. =]
 
lol, I just came back and watched that video again, and lol'd again.
 
:)
 
Forget MVC,ADR.. I give you SCARF,ROBIN =>
String, Callback, Array, Resource, Float, ResourceHandler, Objects, Boolean, Integer, Null.
 
11:48 AM
People still use highcharts or is there a better charting library these days?
 
highercharts?
 
:P
 
@Fabien I use something else because more shiny
If you want even more shiny raphaeljs.com
 
:)
 
12:02 PM
hehe
 
Cheers @PeeHaa
 
o/
 
@DanLugg no, it' actually "Rails pattern" by a different name
it's the same story as with MOVE: you define "MVC" as something broken-by-design and then go about fixing your own mistakes
 
@FlorianMargaine Eh (the element of WordPress)
 
12:13 PM
Building a DIC for fun this weekend...
Then hopefully feeding it to reckti-ct :D
 
@ALL To all who hate hosts still running outdated PHP Versions. Proposed #eol suffix for semantic versions on GitHub. Would be great if you support that.
 
OH: “I’m building a DIC” - “Stop building dicks!” #php
3
-.-
 
@Ocramius I should restart working on mine too
 
@Ocramius this will probably make me look like noob, but what's OH?
 
12:23 PM
"OverHeard"
 
Okay, so it's not the noise a lady makes in bed ... gotcha
 
I always think it means "other half"...
 
12:46 PM
I always think it means... "OH!"
 
@Ocramius reminds me of:
 
@Jimbo yyyyep
 
1:12 PM
Do we support reflection on operators?
 
@tereško I know, but everyone thinks it's MVC. Baby steps...
 
@DanLugg sorry, but anything that pmjones pushes is "baby steps" in the wrong direction
 
@tereško Agreed. I don't care for that man's motives. It's transparently obvious that he, like so many, is trying to create a proprietary ecosystem of pseudo-patterns and abbreviations, which he can soapbox about pioneering.
IIII'm important, because IIIIII came up with <3-letter-abbreviation> which uses <something-something>-pattern which IIIIII came up with too.
 
Are you talking about javax.servlet again?
 
@Ocramius Moi?
 
1:19 PM
that thing that java was doing 15 years ago and that now PHP calls "Action Domain Responder" for some reason
 
Then yes, apparently I am.
 
@Ocramius actually, a pattern with that name was described 20+ years ago
 
oh, there's a different pattern with that name?
 
I wish people would spend more time solving problems and less time trying to generalize web solutions.
 
I'm throwing my hat into the ring: introducing the TTT architecture! The Thing with the data, the Thing that you see, and the Thing that does the rest of the stuff.
 
1:22 PM
(unless your solutions are in an uncommon language, such as Rust)
 
Global state - the shared-all architecture
 
(That's valuable if only for research purposes)
 
@LeviMorrison Even then, application of generalized architectures should be applicable to most languages, shoe-horning aside.
You're still not "solving" anything, per se. You're just building the machine out of different parts.
 
@DanLugg But doing it in an idiomatic way, adopting special language features, is a valuable experience.
 
@Ocramius it was defined in this book: books.google.lv/books?id=foTALGsu488C&redir_esc=y
 
1:23 PM
@LeviMorrison Oh surely; FP-driven parsers vs. imperative ones, for example.
You can parse anything with anything (barring turing incompleteness) but elegance through language-specific features is something to strive for.
Another thing, I haven't watched the video, but I can only assume this to be accurate:
 
pmjones really likes pmjones .. /r/PHP is full of his bullshit
 
I rarely read /r/PHP, but when I do, I regret it.
7
 
lol
 
I read r/PHP whenever something important happens on Internals to gauge community reaction.
 
Like discussing the colour of grass or the next php version number
 
1:31 PM
Yeah, community got that one right.
 
I read r/PHP looking for comments from you guys just ridiculing the mass misinformation.
Which I don't see often enough :(
 
RIP PHP 6
 
haha
 
@DanLugg Dunning–Kruger, f* yeah!
 
1:39 PM
I don't always image-spam, but when I do I'm trying to be funny:
I abbreviation'd when I should have acronym'd
user image
4
 
Here's a star, and a leg!
 
hi guys :)
 
at the first glance, this seems link a good article: adamwathan.me/2014/09/22/when-to-mock (will read later)
 
1:54 PM
I such suck at writing tests...
 
@DanLugg Please, please tweet that
 
@Jimbo I hold no license to it, feel free :-)
 
@webarto so you need to manually do them instead execute written ones :)
 
@hakre Erm, shit just works :P I write most of them for things I'm not sure how they work in the first place :P I should read more 'bout "writing good tests".
 
@webarto You mean you like to live life on the edge!
 
2:01 PM
Gray hair and shed tears means you don't need test for simple things.
I have no idea what I'm talking about.
 
@webarto Well if you don't need tests, then don't bother. Really. Don't just do because everybody says it's the next cool thing.
 
@webarto well, my tests are crap too
bit I suspect that it's mostly because of issues in the code
 
posted on September 23, 2014 by kbironneau

/* by Ganesh S */

 
You can prevent issues in your code by doing the design by writing tests first.
 
Thing is, IMHO, tests prevent that you or someone else break something, but won't help you much with already existing bugs (that you are not aware of). I really rarely broke something I wrote. Maybe that's why I'm so slow...
I like TDD when I know use cases up front. Like e.g. IP class.
I sometimes write dumb tests like *.phpt ...
And sometimes testing is f* hard...
I currently work on a plugin, and only way I can run the thing is in production instance no one uses, code is crypted and even if it's not it would be hard to setup dev instance.
 
2:12 PM
Good morning
 
Morningggg
 
user895378
mornin'
 
user895378
@webarto This is php-src in a nutshell. I can add new tests as I go, but so much of the stuff I'm touching has exactly zero testing in place so who knows if I've broken other things.
 
@webarto it kinda depends on case by case basis: if you have to test some complicated calculations (for example - I recently had to make a lib for figuring out cheapest shipping from a given list of providers), it is easier to make tests first and then write code that actually produces the expected result
 
@rdlowrey Or sometimes they have tests but there are so many things tested in one .phpt that it takes a while to figure out what failed.
 
user895378
2:16 PM
That too. Everything is one giant integration test.
 
I'm proud to say I'm at 40+ tests on return types.
 
user895378
Nice!
 
@LeviMorrison osom!
 
user895378
Chris and I nearly doubled the number of ext/openssl tests in 5.6 :)
 
I'm currently working on giving them better names than 0 .. 40.phpt
 
user895378
2:17 PM
Care to guess how many tests exist for PHP's main streams API?
 
I'm doing things like inheritance0..10.phpt instead.
@rdlowrey Roughly 3?
 
user895378
Spoiler Alert: it's zero!
 
Oh.
Surely the file stream api is tested somewhere?
 
@rdlowrey Yes, sorry I can't find good words to explain, I'll force myself to test if I'm sure someone else will use the code, I'm not that sort of dick :P
 
user895378
@LeviMorrison I'm sure there's coverage on those functions in other tests but there are no specific tests explicitly for streams (superping, sorry).
 
2:19 PM
Bleh.
 
@rdlowrey You done much with big-ish database stuff?
 
@tereško Yes, of course, it really depends, usually when I work with numbers it's so much easier that way... In 8th grade (last) I was going to physics competition and practiced much, I could solve most of the tasks if I knew the end result :)
 
I think @AndreaFaulds' tests for ?? is one giant integration test :D
 
user895378
@Fabien not really. The largest DB I work with is only about 4GB without indexes. But feel free to ask whatever you were planning to ask and if I can help I will :)
 
test/operator/coalesce.phpt, I think.
 
2:21 PM
Looking for some advice on what I should use for storing this kind of data. @cs suggested flat filtes.
yesterday, by Fabien
id | Data | indexed | dateAdded
1      foo     0       2014-12-10 23:33:33
We select on indexed = 0. and update on id.
Once we update we rarely if ever touch the row again
 
SQLite?
 
user895378
Generators are soooo awesome.
 
Size wise about a billions rows.
 
I don't think flat file will work nice at all.
 
But we realistically only touch the last few million. We can archive off the rest but someday we may need to select from it again
 
2:23 PM
You can't beat DBMS.
 
foo will only be about 500 chars length.
 
user895378
I generally think flat file "DB" is something of an anti-pattern for anything other than a personal blog (and maybe then too).
 
Speed is a big factor.
 
@rdlowrey IMHO SQLite is so easy with PHP it would be a crime not to use it.
Driver is integrated I thinks, it works just fine.
 
user895378
Looks like a super trivial key-value store that isn't very relational. Seems like an in-memory store like redis would be great as well.
 
2:24 PM
@Fabien Store it all in memcache :-D
 
user895378
If the data isn't relational I think NoSQL options are great.
 
Is there not an issue with the amount of memory we'd need for it?
 
I was joking but @rdlowrey's suggestion of NoSQL is good - mongodb
 
Yeah. It's not relational. It's more or less a history of jobs for processing.
 
@Fabien Check out a NoSQL solution.
 
2:25 PM
Or... use YAML files
 
user895378
Yeah, if your data isn't (and never will be) relational and super normalized across lots of tables then NoSQL can really really simplify your life.
 
/trolol
 
Any recommended NoSQL that fit the bill of the SELECT on indexed =0 and update on ID?
 
Yeah, mongodb...
@Fabien You don't need to use the mongo php driver at first either, just run terminal commands and play about with it, selecting what you need etc
It's all just JS
 
js :(
 
2:28 PM
As in, JSON and dot syntax, that's it
 
Ah right
 
db.data.find( { indexed: 0 } )
 
What about archiving older data?
On the premises some day we may likely need to unarchive and go through the whole thing.
An example is this stuff can get pushed in to ElasticSearch. If we reindex we can just re-read from that storage place.
 
@Fabien So MongoDB has TTL which expires data after a given time. You'll probably want a cronjob to see what data needs archiving, save it to another archive db, then let TTL remove it
So you'll have a big ass, slow, archived db, but it'll have everything you want in it
and it'll keep your current one fast and pruned
 
Slow in what respect?
 
2:33 PM
Well, because it's massive if it's containing billions of rows
 
Furry muff
 
"rows"
 
We'll give it a wangle.
 
@Jimbo "documents" ;)
 
@PeeHaa Shut your tits
Are you coming to PHPNW?
 
2:46 PM
yeh
Real life room 11 circle jerking ;)
 
Anyone heard of WestWing.de ?
 
@PeeHaa you are coming?
 
@ircmaxell yes :)
 
Do you need visa for UK? (No you don't)
F* asshole of Europe :(
 
@webarto back to the balkan with you!
 
2:50 PM
I will just acquire diplomatic passport.
 
oh good lord
/me cancels trip
 
It's fine, 80% sure @webarto is on the no-fly list.
 
You are funny Fabien, I might visit you sometimes.
 
> You're a funny guy Sully! That's why I am going to kill you last...
 
I LIED
 
2:55 PM
heh
 
My passport covers more.
Of the wrong part of the World.
 
@ircmaxell That is not very nice :P
 
:-P
 
:-)
 

« first day (1438 days earlier)      last day (3510 days later) »