« first day (1341 days earlier)      last day (3832 days later) » 

I'm working now with SOAP. What a mess...
@HamZa Welcome in commercial world? :D
@Leri it's for this damn school
@HamZa so now you're working as a coroner ?
09:02
I need to "save" my team
@AlmaDo lol something like that
Therapist knows all but can not do anything. Surgeon knows nothing but can do anything. And only coroner knows all and can do anything. But that's already too late.
09:23
Anyone good with Artax?
is Artax really good for production usage?
how does it compare, performance-wise, to curl?
I mean, curl is just a binding to the C lib, so it sounds like it should be way faster
I'm actually using it for async stuff, so that part is really awesome ;)
why do you need async if the rest of your code is sync?
@FlorianMargaine I'm not writing sync code?
@FlorianMargaine Why does curl_multi_* exist?
09:33
really? in PHP?
@FlorianMargaine This isn't what I'm doing right this second, but websockets + async is brilliant in php, and good fun too
@Jimbo show me your full-async code in PHP, seriously. I'd be amazed.
Well, this is the async example I'm going by, with my own requests...
@SergeyTelshevsky just because you have been making shit-code for 5+ years does not make you good at choosing frameworks
@FlorianMargaine One of the key things Artax gives you for sync is an API that does suck very hard
09:35
@Jimbo oh, so it's just async to have concurrency
@tereško right, it's a matter of whether a person want's to be good or want's to get things done asap not thinking about maintenance and support
What were you expecting :P
@FlorianMargaine Yes, although we do have fully async applications in PHP as well... and @Jimbo's will be one of them by the time I've finished with it...
Yay :-)
@DaveRandom I'm surprised, as long as PDO and the likes are not async... it seems pretty hard to have fully-async php apps :|
09:37
@SergeyTelshevsky also, Yii was "reddit's favorite framework" before the Laravel's campaign begun
Yii/Laravel: opinions?
@FlorianMargaine This is a fair point - DB I/O async. I haven't tried this yet, but here's something I just found with 5 seconds googling for async mysql with react: github.com/bixuehujin/reactphp-mysql
Also, see @tereško's opinion
:D
@FlorianMargaine as of PHP 5.6, ext/pgsql will have full async support
@Jimbo that's cool. I'm expecting C extensions though, PHP is too slow to have this kind of driver in PHP.
@DaveRandom oh, that's cool!
09:39
@FlorianMargaine those both are "one person projects", with ignorant community, bad practices and unsustainable code
@SecondRikudo 'That technique!'
PDO will probably never have it because it doesn't belong there
@FlorianMargaine props to @rdlowrey for that one
@FlorianMargaine Because PDO is an abstraction layer for an arbitrary rdbms with a lowest-common-denominator approach. All the things that PDO supports have their own extensions as well, advanced functionality belongs there
@DaveRandom hmmm
that's not how I saw PDO
but well, I guess it's like that.
09:42
What would you use async postgresql for?
That's not what I would like it to be, but that's what it is
Hey guys,
@FlorianMargaine uh, really. PHP is not so slow…
@Fabien Consider a websocket server for example, you don't want to block the process waiting for a database query for one action on one specific socket, you want to just send data to the DB, go off and service some other clients, and deal with the response from the db when it comes back
I cannot seem to connect to the database. Keep getting this error "Fatal error: Class 'myslqi' not found in <pathname>
09:45
Makes sense. I need to do more and by more I mean anything with web sockets at some point.
@andro What's your O/S?
I double checked and made sure that "extension=php_mysql.dll" and "extension=php_mysqli.dll" in php.ini is not a comment
any help?
Try it in code:
if (!function_exists('mysqli_init') && !extension_loaded('mysqli')) {
    echo 'We don\'t have mysqli!!!';
} else {
    echo 'Phew we have it!';
}
Windows 7 Prof
32 bit
yeah i tried that too. "Phew we have it!"
No word back from work on PHPNW so far :(
09:47
@FlorianMargaine there's a bit of movement to bring a proper async I/O stack into PHP core for 6 at the moment, we'll see how that works out but a few people are campaigning to have some libuv based stuff under the bonnet. I'm telling you this so you can take it back to room 17 so you can all get the pointing and laughing and "hey look at PHP, they can't do it themselves so they're copying us!" out of your systems now and we can all move on to making things better instead of language wars :-P
@andro Are you using namespaces?
Probably not the reason actually....
No i am not using namespaces
Also, make sure you've restarted apache/wamp and phpinfo() shows mysqli is loaded
@andro Please read that error message, very carefully, paying particular attention to the class name /cc @Jimbo
lol...
AHHH, nicely spotted!
@andro You absolute strap. Read the exact letters in that error message.
09:50
@DaveRandom is there ?
@JoeWatkins Y U NO READ INTERNALS?!?!?!?
@JoeWatkins How are things on the housing front?
@JoeWatkins [PHP-DEV] Refactoring our IO multiplexing layer
started by jpauli
got link chris ?
@Fabien they aren't ...
Well that sucks. Council need to stop faffing around.
09:53
I found it ...
@Fabien it ain't happening, they won't help us ...
Well you won't get kicked out most likely. There's some laws against doing it to people with families.
I think...
no there isn't, the judge already granted possession and will grant eviction too, the council won't help us because our landlord is perusing us in small claims court for damages, they already told us we can't be housed by them ... I have 7 days left in this house :(
@DaveRandom libevent is fundamentally incompatible with the threading model used in php ...
the only real option is bespoke ...
@JoeWatkins Go tell jpauli, he mentioned he would like to talk to you on that subject in irc yesterday
> <jpauli> LeviM: I let the thread part for thread-aware persons, like krakjoe
10:00
@DaveRandom nah I mainly work in PHP, so this kind of stuff is genuinely interesting to me
@JoeWatkins speakerdeck.com/trent/… should be particularly related here… (via Pierre)
even worse, I mainly work with Drupal ;)
@FlorianMargaine I'm sorry. Are you OK? Can I get you anything?
:-P
@DaveRandom it pays the gigs.
off-work, I mainly work in lisp :P
I always wanted to try and learn lisp, never had the time to properly try and wrap my head around it though :-/
10:04
@JoeWatkins I mainly mean the part of the threads not sharing write access. Write access to global scope should set a lock on all threads except the writing one.
that's an rwlock, tsrm doesn't work in a way that can make use of rwlocks ...
also we don't have a gil ...
I know that. Just from the concept.
oh right
but we can implement code at the writing locations to use rw locks… (in write fetches?)
I'm creating dispatcher and wishing there were anon-classes. /cc @JoeWatkins
10:11
but tsrm doesn't work like that does it, when you write a module global (which isn't a global in the true sense of the word anyway in a threaded interpreter) you fetch the table from tsrm containing this threads resources, if necessary exclusively, you are then returned the module's global's from the table outside of exclusion, that's just for you to get the base address for a modules globals, by the time you write or read a member of the structure you are nowhere near any locking whatever ...
@JoeWatkins each thread should have it's own module globals?
yes it does
they are global in the sense of an interpreter context, not in the real sense ...
yep
@FlorianMargaine Bit of a personal question but you're happy working where you are? I'm always curious how far the pay can go working with CMSs predomintantly.
and the issue is now?
10:17
> Choose Refactor | Rename on the main menu or on the context menu of the selection or press Shift+F6Shift+F6Shift+F6Shift+F6Shift+F6Shift+F6Ctrl+RShift+Alt+RShift F6Shift F6Shift F6.
^^ Oh PHPStorm
@Fabien That technique which we never used or even tried before, obviously never trained on it, but now we can perform it perfectly!
lol
$10 on Fusion-Ha!
I just used PHPStorm for merging for the first time. My stuff on the left, server stuff on the right, the merges in the middle. You can click little icons to just put the changes back in or delete. I think that's awesome!
smells like C++
10:24
@Leri E_NOT_ENOUGH_STATIC
@Leri private setters. WTF.
SemVer the go to place for reading/learning about version numbering?
@bwoebi If that was the only thing that's wrong there, I'd be proud of me. :D
@bwoebi Well, you can have private setters I guess if you want validation for some things that are being set, but only that class can set them
And that my friends is a part of my old framework and yes, it's still in production.
10:28
and you don't want to pollute your constructor with loads of validation rules
@Jimbo in such a small class. yeah.
wow, I do have DI there (that massively violates SRP). Hmm.. I guess I did not write that code..
How do you change the default font-size in PHPStorm?
I went to Editor > Colors & Fonts > Font, but it's not editable.
Mines there
You on 7.1.3?
10:34
@SecondRikudo You say so? /me stops spamming
7.1.3 yeah
@Fabien Yea, but is it editable?
Yeah. Works like an input field.
dafuq...
10:36
Size 11 FTW btw.
Well, I need to eat more carrots, because in my world 14 FTW.
Dropping down to 10 actually. 10 is nice too.
Makes my functions smaller.
this is better... Just scroll to change size
10:37
@DanLugg You can't edit the default schemes
Save As a scheme and then you can edit it
@SecondRikudo Ah!
Bingo, thanks @SecondRikudo
@Leri well, that's it. I've done with manual for now. So if you'll read those it's parts, which are interesting for you (I guess, API, testing results & functions may be) and then try something, that would be great
should public OSS libraries be free to use private properties in classes (and thereby restrict inheritance)?
Also, one other PHPStorm dealio; any way to favour a single, comma'd use over multiple?
user924016
@hohner why not?
10:43
@AlmaDo Great. Let's see what I can do. That's quite a big challenge. I've never developed that kind of GUI.
@hohner How does using private properties restrict inheritance? All it does is restrict access to those properties, if those properties are part of the API then they will be declared in a way that allows access to them (public/protected or with accessors) and if they are not part of the API then inheritance is not the correct way to do what you are trying to do...
@Leri if you want, make a branch in the repo
And OSS has nothing to do with those principles
@DanLugg Wha?
use A, B, C; vs. use A; use B; use C;
10:45
@DanLugg Not that I have found, and the GUI doesn't fold a comma separated one in the same way either :-(
Damn.
Ah well
If you find a way, please tell me because I also want that
@AlmaDo It's not quite a branch, imho. GUI should be separated from it.
@DaveRandom I had a way, it was called NetBeans. Problem was the rest of the features could be qualified as bugs.
Hence PHPStorm :-P
@Leri fair enough. I have, however, gh-pages branch (:
10:47
@DanLugg open a support ticket with jetbrains. It hasn't annoyed me enough to do something about it yet
You could prob write a plugin as well
While you're there get them to look at DIC support for click to definition
@DaveRandom @DanLugg start a ticket on it for them
Works for Dave but not me.
I didn't write plugins for NetBeans because Java, so I probably won't for PHPStorm either. I will open a ticket however.
Either they'll start working on it, or they'll tell you how to do it under the cunningham's law. Win-win :)
10:50
@AlmaDo And that should be separated. :Ь
@Leri well.. that's what github wants from me in order to publish my doc pages :\
@AlmaDo Oh.. leave it alone then. :/
huh.. writing documentation is a hell
The Pull Members Up... feature just made my fucking day.
@DaveRandom You know if we meet IRL I am going to struggle to not call you Dave right?
11:01
@Fabien I similarly will struggle not to call you twat face. I have that issue with everyone though.
@DaveRandom exactly, but that's not an opinion shared by others. They think using private visibility is an unnecessary restriction placed on end-users not being able to override the class.
@DanLugg I have found it breaks docblocks, I tend to do a ctl + alt + L afterwards
@hohner Those people do not understand OOP
@DaveRandom again, exactly right - but it boils down to this, how strongly should you enforce these OO principles on a public project where the majority of consumers just want things to work
@DaveRandom lol
I guess my question is this: is purity/correctness more important that flexibility (no matter how incorrect)?
user924016
11:05
@hohner it is not a matter of flexibillity
@DaveRandom Seemed to work okay for me :-) Then again, I'm new, and everything is exciting.
@RonniSkansing if you're using private visibility extensively, you are enforcing strict encapsulation; i.e. preventing child classes from accessing properties from classes they inherit. That is a deliberate restriction - how is that not a matter of flexibility?
@Fabien yeah, you can still make pretty code and enforce coding standards, unit tests, etc.
honestly, it's just the boilerplate part of other frameworks (forms, declaring entities, etc) which has a nice UI, the rest is still code
that said, it depends on people. I work on websites that are a lot customized, they require lots of code.
We're about to introduce unit testing to our workflow. Any tips regarding that and drupal?
We seem to build more within Drupal and not much custom module creation. But it does happen.
user924016
@hohner yes encapsulating, but what you are saying still makes no sense to me. could you make like a 10 line psudo code
11:16
@RonniSkansing I want to introduce private visibility and perhaps even final keywords into a project. I firmly believe in strong encapsulation and that inheritance is often an anti-pattern. But some contributors are uncertain, so I'm trying to anticipate counter-arguments
in a recent project (of 2 month or so), we have 15k lines of code in custom modules/themes
pasta-code?
nope, phpcpd runs on the code and says nothing
not "copy-paste" code
11:17
pasta-code .. hm.. spagetti :p
actually, not that much
phpmd runs on the code too :P
Any way to generate docblocks for all members at once?
@DanLugg telepathy
@Ocramius I don't have that plugin.
Nor do I have the "magic" plugin.
I was looking for a money plugin
11:20
Srsly tho, I can /** for every method/property, but can I auto it for the file?
Say I have a framework that runs multiple websites from inside that framework. The framework is a git repository. The sites inside are also git repositories which get worked on my different developers. Should I be looking at git submodules or git subtree? Or perhaps some other method?
@Fabien if you want jenkins integration, use my PR on drush github.com/drush-ops/drush/pull/226
user924016
@hohner okay, I think there are enough resources on when x should be public, protected or private.
I'm trying to scrap a website for a school project, I need to login. That was successful. But here's the problem, "CURLOPT_FOLLOWLOCATION" is redirecting me to index, I want to automagically go to say foo.php, is this possible? Or should I just make a second curl request to foo.php?
@Fabien anyway, you'll want to pass these 2 links around: drupal.org/node/265762 and drupal.org/node/265828
oh yeah, and write some script to make sure drush returns something other than 0 when there is an error.
right now, it returns 0, so jenkins doesn't see test failures as build failure
11:23
Cheers @FlorianMargaine saved them for sharing.
Problem solved, thanks
It seems that CURLOPT_COOKIEJAR needs a complete path? So I did '/temp/cookie.txt', I also tried 'temp/cookie.txt'. Didn't work, but when I did 'cookie.txt' it worked, now I've used __DIR__ . '/temp/cookie.txt'
11:39
@hohner I do see where you are coming from, but I don't think you should cater for the lcd from the ground up - you should write the best possible code, and if you find you need a version for simpletons then publish a wrapper for idiots.
Or simply say "look, if you don't understand why what you are trying to do is wrong, you need to go away and understand why it is wrong, and then you will understand how to do what you are trying to do"
everyone back to work ...
Of course, if people are trying to do something that requires access to a private property, it's always possible the original design is wrong and that data should be accessible
@DaveRandom so tough love basically :P
I've laid out all the technical reasons in the mailing list, and they're still not getting it - so probably worth reaching some kind of compromise (protected visibility)
@DanLugg you can set templates for file creation
11:57
Feb 9 at 21:37, by Gordon
useful phpstorm shortcuts: http://www.sitepoint.com/phpstorm-top-productivity-hacks-shortcuts mention @Danack
@Ocramius Yea, I see that. But what I'm talking about is: I create a class/interface/trait with X methods/properties. Now, I want to generate the docblock skeleton (based on return type, parameters, etc). Right now I have to /** + for each member of the type to generate it. Is there a way to just generate all the docblock skeletons at once for a given file?
Thanks @Fabien, will memorize :-P
I don't think I could live without duplicate line(s). Shift up / down and end/beginning of line. Those aren't exactly PHPStorm exclusive.
Yea, NB has those too
And NP++ IIRC
user895378
12:24
@DaveRandom it should be noted that the async pgsql functionality is pretty unwieldy without a good userland event loop + stream IO abstraction like react or alert. The native API for using it necessarily sucks because it's impossible to simplify it in the absence of a native event loop. For it to really be useful people doing async things will almost certainly need to wrap the native functions in a simpler userland library /cc @FlorianMargaine
user895378
It's on my to-do list, though.
user895378
Also: morning.
@rdlowrey go go libuv /heh
user895378
yup.
@rdlowrey morning :)
next thing you know, php is renamed nodephp
:P
12:28
@rdlowrey mornin
@rdlowrey Hey man, I'm trying to do digest auth with Artax and it's a bit of a nightmare - you have any experience with Digest auth?
user895378
All it involves is setting headers. What's the problem?
I'm getting a load of 401's and I'd like to think my header is set correctly
1 sec
user895378
If you can post a gist or something somewhere with your code I'll look into it
user895378
But you're right: that's a feature that I could automate so that you don't have to do the work of generating the hash yourself.
12:34
@rdlowrey I'd like to write that if I can :-)
I was thinking about extending request with Basic / Digest
Here's what I'm trying
user895378
@Jimbo any chance you can post the output of the WWW-Authenticate header the server is sending as part of the 401?
'WWW-Authenticate' =>
    array(1) {
      [0] =>
      string(102) "Digest realm="whatever-api",qop="auth",nonce="53a186dcefcf9",opaque="f0f36dc0aee59c72a3a1a1f16413c889""
    }
You guys use git submodules or subtrees before?
user895378
I use submodules frequently. Fair warning: they can be really frustrating for a while until you understand all the ins and outs. Never used subtrees.
Trying to see if it's applicable then. Framework is shared. Sites use framework (and sit inside it) and are built individually.
Note: Drupal.
 / Drupal
      + Core Files
      / Core Folder
      / Sites
           / Invididual Site
           / Invididual Site
12:41
@DanLugg Right-click in the class, generate, PHPdocblock, select all the functions you want to generate the doc block for. And Robert is your father's brother.
So Drupal is the parent repo. Individual sites are built by devs on their own.
why not a single git repo?
Cleanliness.
user895378
@Jimbo it's been a long time since I've looked at any of the digest auth stuff. Reading up on the relevant RFC now so I can help ...
afaik git subtrees is just having another .git folder somewhere
12:46
So perhaps subtrees may be more applicable. I'll keep reading.
So @rdlowrey this whole bridge thing has made me realise how important it is to make the version of your lib detectable at run time :-P
As it is I've had to use reflection to look for stuff that changed between versions
user895378
@Jimbo Your logic in generating the header looks correct. Have you double-checked that the values you're parsing from the server's WWW-Authenticate header are correct?
user895378
@DaveRandom Should just be a matter of adding some sort of version constant to the Alert\Reactor interface, right?
user895378
And since you updated artax to use the latest alert version then it won't matter that it isn't present in the older versions, yeah?
Yeh something like that. By "you" I didn't mean you specifically, I mean everybody
12:55
@DaveRandom can't you read the composer.json instead?
@rdlowrey Well idk, other people are presumably using Alert for stuff given then random contributions you've had from other people
@FlorianMargaine I thought about that, but this is a bridge lib so I need to know the exact installed version, and hacking around in installed.json didn't seem like a great idea
user895378
@DaveRandom I don't know ... I honestly wouldn't worry about creating bridges for older versions if I were you. But if you really want to I won't stop you :)
@rdlowrey I have, one minor change from quop to qop, but still no joy. Must be some issue server-side maybe
user895378
@Jimbo I don't know ... it looks right. If you don't mind sharing the auth info with me via email or something I can do some old fashioned try-fail-repeat debugging later today
user895378
@DaveRandom You're right -- that's something I realized was useful in aerys and I'm going to start including a couple of version number and name constants in all my libs
12:57
@rdlowrey It's become something of a point of technical exercise - it's more important to do it with React because it's more widely used
user895378
Yeah I'm totally onboard with the react old versions, but I think you'll get seriously diminishing returns to support old versions of alert.
user895378
I'd only support old versions of alert if someone specifically asks for them.
@Jimbo @rdlowrey writing an HTTP auth plugin for Artax is on my todo list, but that list is quite long and it's not at the top...
I might have a look at it later because it's probably a quickie
(famous last words)
user895378
@DaveRandom Yeah I know the feeling. I have a bunch of things to do (@Danack's auryn stuff as at the top of my list right now) but the long-awaited artax improvement needs to happen.
good good

« first day (1341 days earlier)      last day (3832 days later) »