« first day (1207 days earlier)      last day (3967 days later) » 

00:00
@andho where them PRs from this weekend? =oP
00:18
guys, besides ffmpeg, are there any other way to convert video formats upon upload?
@reikyoushin What's wrong with ffmpeg?
@DaveRandom just looking for other alternatives.. if none came up, then ffmpeg it is
@reikyoushin Well there's libav.org/avconv.html but I've never used it
@DaveRandom but you've used ffmpeg already?
A few times, yes
http://stackoverflow.com/a/21540846/782822

Took me minutes to figure out. Damn parser :(
Should've seen my face once I had deleted almost everything and it still did not work
01:25
Ahhh yiiiiissss - dat smooth upgrade
02:04
@crypticツ It was kinda too coupled. I wanted to write tests for ChatCrawler but that thing is a black box. and that ^
02:17
Things - that are mildly ironic - travis-ci.org/sebastianbergmann/phpunit
@MadaraUchiha: this is flagged as a dup / merge request. It looks like you're trying to write a canonical answer there; perhaps you could just post it to the original question?
@andho I made sure to pass all dependencies via ctor, so not sure about the whole coupling thing. Can you elaborate?
02:40
@crypticツ not much coupling yeah :P just getting my head around it first.
@andho teresko said he would write the tests, but he's missing
@crypticツ i'm getting an idea now on how to test. I'm not a fan of PHPUnit though.
user652649
mornings
@andho I've never written a test, but I think I will start for the backlog
@Wes morning
user652649
02:57
i wish i could sleep as i used to when i was a kid, especially during college times [...] man 12 hours straight sleeping. today instead something like 4 hours, probably less
@Wes How much exercise do you get a week? I get insomnia when I don't get enough exercise - which is annoying when I've also got a bad problem that stops me exercising :P
@Wes awww those sleepy days eh
user652649
my only exercise is writing on my keyboard. xD dunno something like 4 hours/week. i think my problem is too much caffeine xD
@crypticツ I love testing with PHPSpec.
never heard of it
03:07
it's the BDD to PHPUnit's TDD
user652649
looking for a unit testing framework too, is there a way to run phpunit just on a raw server, with web interface?
I don't think there is a web runner. But there is a tool to convert from PHPUnit xml to html
why do you want a webrunner though?
user652649
@andho i guess phpunit would be ok too, but a web gui would be better
user652649
portability, easier to use etc
03:20
@Wes true, about portability. Easier to use, not so much. In CLI you can easily run the tests and change options. plus it will run on CI server.
user652649
@crypticツ cat got lost again?
@Wes weird things are happening in house O_o Small objects left on countertops and tables are ending up on the floor or under the couch. Mysterious grey/brown fuzzy objects are appearing in odd places.
user652649
in HTML / CSS / WebDesign, 17 hours ago, by Wes
@crypticツ does RMA for cats exists?
Found this in php sources

unsigned char mbsequence[16]; /* allow up to 15 characters in a multibyte sequence */
int mbseqlen = sizeof(mbsequence);
int status = SUCCESS;
unsigned int this_char = get_next_char(charset, old, oldlen, &i, mbsequence, &mbseqlen, &status);
could anyone explain why we allocate 16 bytes for a multibyte character?
4
isn't it way too much?
@zerkms forward compatability for say utf-125?
03:32
ps: forgot to mention it's from php_escape_html_entities_ex
@crypticツ :-S
user652649
must be for allowing some weird character encoding
user652649
how many bytes can take a character in utf-* ? i know utf-8 is 4 max, not sure about other unicode based sets
utf-8 is 6 bytes max
utf-16 is either 2 or 4
utf-32 is always 4
user652649
i thought it was 4 for utf-8, but you are right it also could be up to 6 accordingly to wikipedia
@zerkms This RFC limited utf-8 to 4 bytes - the original spec said 6 - tools.ietf.org/html/rfc3629
"Restricted the range of characters to 0000-10FFFF (the UTF-16 accessible range)." which map into at max 4 bytes.
Which....doesn't help answer your actual question at all.
03:53
The unicode codepoint space lasts to U+7FFFFFFF
so may be there is a newer revision of the RFC
lol
@Danack yep, it's 4 bytes now, thanks
@zerkms np - btw which version of the src were you looking in? I couldn't see that line of code in 5.5
oh, for some reason I checked out to 5.3.10
I remember, I gdb something and needed sources for that
now it's const unsigned char *mbsequence = NULL;
04:10
And the code seems still as unintelligible.
04:24
morning! :3
morning
user652649
05:02
47
Q: Should url be case sensitive?

ImagereeI noticed that HTTP://STACKOVERFLOW.COM/QUESTIONS/ASK and http://stackoverflow.com/questions/ask both works fine - actually the previous one is converted to lowercase. I think that this makes sense for the user. If I look at google then this url works fine: http://www.google.com/intl/en/a...

@Wes fuck no. People are allowed to type URLs in, and can't be guaranteed to get them case accurate.
user652649
in fact i was thinking to make them case insensitive :P
@Wes about != ABOUT so it's perfectly acceptable to show 404 if user types latter.
And one of the things I always blamed on windows is case insensitive file-system. Well, IIS can be configured to be case sensitive though.
Off-to work. Later
morning
user652649
@Danack not sure how should i modify my current code tho
atm urls (filenames of paths) are always lowercased upon creation and stored in a utf8_bin field
should i make it utf_general_ci or should i leave it as is and lowercase the request url on the fly instead?
05:17
"leave it as is and lowercase the request url on the fly" - that sounds sensible.
"stored in a utf8_bin"- backs slowly away.
How come you chose to use that?
user652649
wat?
utf8_bin - why not utf8mb4?
user652649
@Leri well,,, web is different... sites should allow some "errors", like inaccurate case
user652649
i don't even know @Danack what's that? i always used utf8_bin for this kind of things
user652649
ah, i see
05:24
why is my new spock avatar doesn't show up?
user652649
do you know where can i get a list of characters in this range? because my urls are "special" i allow any kind of shit actually
@Wes do you sanitize them?
yeah - utf8_bin is case sensitive, so gives different results for like, which other character collations don't do. But also doesn't know about 4 byte characters (probably not a problem for URLS).
could someone request ../ ?
user652649
i strip out some characters instead of urlencoding them ( / \ ?)
user652649
05:26
but i allow everything else
if the script running it as enough permission could someone just request your own configuration file trough it?
user652649
nope
@Wes A list of characters can be found from en.wikipedia.org/wiki/… or here some examples - apps.timwhitlock.info/emoji/tables/unicode
user652649
mh anyway id go with a complete unicode charset. i may have users that added hearts in their usernames [...] and i don't think they will be included by that, right? xD
user652649
but is it a superset of utf-8? can't understand the difference -__-
user652649
05:33
wtf are supplementary characters? private use range ones?
@Wes Emoji's mostly.
en.wikipedia.org/wiki/Emoji - my browser doesn't like this page.
user652649
uhm but those works also with utf-8... because i have many already
@Wes Actually I really need to go to bed. The short version is utf8 characters sets and collations don't support the 4 byte UTF8 characters. The 'bin' collation doesn't support the 'like' SQL operator, which is meant to be case insensitive and also know that "dån is like dan"
user652649
:P no prob, gn thanks for helping
@Wes utf8_bin is for the utf8 character set - it def can't store those chars......they can be truncated when inserted. See if you can actually store the char "\xF0\x9F\x98\x94" - and let me know tomorrow.
nn
05:39
@Danack got a git question if you got time
quickleee
.idea
cache/*
composer.lock
composer.phar
logs/*
vendor
is my root .gitignore file
I want to make sure there are two empty directory in git at all times, logs and cache/json
how do I make sure git will not ignore them because they are empty directories?
I have ampty .gitignore files in both logs and cache/json will that suffice?
Er - that gets complicated. You're telling git both to ignore that directory and then have files in them.
user652649
05:43
@Danack checked, it doesn't work you are right, it allows lower ranges emoticons but not unicode 6 ones
Rdlowrey tried to do something similar - and apparently there is a way but it's a bit frigging magic.
The logs one would be fine, but for the cache one "cache/json" matches "cache/*"
@Danack but will the .gitignore in logs work? Because the above gitignore did not upload the empty folder
Actually - I think you need to put files in the folder for git to track - if you do that it may work - stackoverflow.com/questions/5600621/…
@Wes VINDICATION.
But it's more than a bit weird adding stuff and then telling git to ignore it. You'd be better off just making sure the directory exists, and then putting stuff into a sub-folder I guess? But it's almost 6am, so I can't brain.
user652649
i wasn't pretending to know anything tho xD and argumenting with you xD i didn't even know
user652649
so basically it's the "right" unicode, the complete one with four bytes
user652649
05:48
as opposed to utf-8 that allows just "older" ranges
user652649
anyway thanks for help :P going to switch all the things to utf8mb4
user652649
50gb db myisam, it will take hours xD
@crypticツ It's dangerous to go alone - take this pastebin.com/S3gCPcCn
@Danack wait, what?
So stick a file in placeholder file in cache/foo.txt and then actually write your cache files into cache/somedirectory/ and add cache/somedirectory/* to the git ignore?
that function can make sure that the appropriate path exists to be able to write a file.
anyway I have to go - nn.
user652649
05:58
gn @Danack
user652649
/me gets ready to work
user652649
later
> PHP Warning: Zend OPcache can't be temporary enabled (it may be only disabled till the end of request) in index.php on line 17
Line 17 ini_set('opcache.enable', 1);
us1.php.net/manual/en/… says it is PHP_INI_ALL
06:24
btw this is on PHP built-in server
I know there is a opcache.enable_cli which is run fine, but should it produce warning error just because it's being set in wrong environment?
06:54
@crypticツ I see empty files named empty in empty directories
@andho yeah any file can be placed there as long as there is some file the folder will not be ignored, well unless specified in .gitignore
@Wes inaccurate case in url is not what user expects to be fixed by application. Also, in modern UX all you (as user) need to memorize is domain of site you want to visit. If you want fast access to some internal page you bookmark it and not type url in address bar (well, unless you are my uncle).
Morning @all
.empty .gitignore .gitkeep and .placeholder are the common ones
07:06
guys i have issue with mysql can anyone help me here?
@andho got it working github.com/Room-11/CVBacklogUI/commit/… I wonder if there is a simpler way to do it though.
07:26
I could not find the list of all predefined exceptions in manual. Do we have one?
BTW, I want some predefined exception for illegal state
user924016
=]
hmm, how do you deal with a help vampire on a mailing list? :|
@crypticツ Is not this pure presenter? No offense, just asking.
user924016
user924016
fun rant
07:41
morning
@Leri huh?
@RonniSkansing larawhat?
user924016
hehe
user924016
LaraCroft i think
@crypticツ Well, I was pretty bored so browsed through the code and that seemed to be presentation layer not controller since it just gets state and deals with twig template rendering. However, never mind, I'll get to my work. ;)
07:51
@Leri ok, so what is your suggestion or how should it be instead?
@Wes Changing name (e.g. Presenters\BacklogPresenter).
This will give you room for creating true BacklogController that may have additional hooks (if you'll need them) to alter state.
It's just me though. ^
So all I am doing is changing the name?
This is what I'd do. If that seems legit to you then yes.
So what is the difference between a Controller and a Presenter?
08:04
Hey
Anyone can help me to test the Web API in the rest client ?
In pure MVC controller should not have any presentation logic (accordint to Matin Fowler and @tereško). Since in http world it's pretty hard to have such architecture I go with MVP.
Presenter acquires state (which is either presentation model or domain object (if I am lazy enough to map)) and presents it.
@Leri So where does the Controller come in?
@crypticツ In MVP?
Short answer is, it does not, unless you are doing something weird
And even if you do, that should be service layer.
If my route points to a controller method do I change it to point to the Presenter method?
I thought a controller is what gets access by the route
@crypticツ Presenter has application logic, so yes it should point to presenter method.
@crypticツ I think of presenter as controller with presentation logic pushed in.
user924016
08:14
^ its good valid points. I actully do the same thing, call my presenters controllers without giving much thought to it.
Gets request, alters/gets model state, passes presentation model to template, gets buffered output, pushes to user over network
user924016
yea it fits like a glove
user924016
Thanks.
You're welcome.
@RonniSkansing I got to this point when moved to android development, where view is truly view (speaking of MVC).
is packagelist down for anyone else?
user924016
08:19
@Leri i started doing abit of java yesterday (while reading clean code and thinking in javatar) only to get a better understanding of MVC. But already now (18 hours) in I can see that there are many benefints to playing with a oo lang.
or reaaaal slow
So bottom line is: Thanks Android Application Framework developers for giving me clear idea of MVC finally!
user924016
hehe
user924016
@crypticツ No lag here
@crypticツ why not just keep .gitignore empty?
08:22
@andho because I want it to ignore all other files in that directory except itself
@Leri it entirely possible
@andho There's difference between hard and impossible and I've used the first one. Although, benefits of achieving MVC does not worth effort, imho.
@andho BTW, if you meant asp.net mvc 4, it's also MVP more than MVC. Razor is still templating engine and can't really listen to state changes.
I honestly don't get the difference.

> In MVP, all presentation logic is pushed to the presenter.[1] Eventually, the model becomes strictly a domain model.

Ummm, why would the Model have presentation logic in MVC?
@andho Model has state and bussines logic
user924016
One of the difference is that in MVC the Controller does not work as mediator between M and V
08:31
@RonniSkansing okay that makes more sense. In that context we can call all the Web MVCs MVP
Exactly. ^
user924016
@andho yea something like that... But many of the framework also makes strange assumptions. Like that the model is a database layer
I miss the days of just plain old .html files in a directory =oP
@RonniSkansing they do. Also they make the assumption that Model is an Entity, lol
user924016
hehe
08:38
@crypticツ now I use static code generators to write HTML XD
@crypticツ I was just a school kid and did not know what the hell I would do in future... and I am kinda missing that too.
@Leri I do MVW, that's the only way not to argue with anyone on the internet :D
@RonniSkansing Most web development is building database skins or simple personal portfolios for businesses :D
@BenjaminGruenbaum Where W stands for: Whatever but C! :D
user924016
@BenjaminGruenbaum =] sure.
@Leri W just stands for 'whatever' - no lies :D
user924016
08:46
But i would better like a database persistence wrapper presenter
user924016
hehe, but no I love talking about it and exploring
Broken record time: It's a lot more important to do separation of concerns and proper code structuring than to know the names or to apply a specific named pattern.
user924016
^ you do some c# or am I not remembering that one right?
just write good code and send all those hundreds names of patterns to the hell :p
morning room
user924016
Morning Alma
08:49
@RonniSkansing I do C# too.
Morning
user924016
@BenjaminGruenbaum on a sitenote to that, have you used mono?
Morning @AlmaDo, @Fabien
Not over time - I played with it.
hi, @Fabien
08:50
Yay, super ping.
user924016
I love c#, but rarely use Windows.
heh
only double ping
@RonniSkansing so you're using asp.net under wine ? :p
user924016
.. hehe
@RonniSkansing I love bash as a shell and all the unixish commands but rarely use linux
08:51
What are peoples honest thoughts on asp.net?
Life is tough, so I'm stuck with git bash using Ming and you're stuck with Mono
@Fabien ask SO team
@Fabien you don't want to know.
wow first time ever doing:
php login.php | php get-stock.php
They're thinking of starting asp.net work here to approach more enterprise level clients.
08:52
feels good
Is that really a good reason to go to asp.net?
@Fabien haha, it's the name that counts
no
@Fabien asp.net also has several types - webforms and .net MVC (and things like FubuMVC that are very similar)
If you end up with webforms - quit.
user924016
hehe
I'd say, maybe it's because ASP.NET has better cages?
08:53
Languages and platforms don't matter nearly as much as concepts.
What I find funny about it is that they say it but I've done nothing but css/html/javascript since I arrived, well maybe about 3% PHP which was putting stuff in Drupal.
@Fabien maybe C#, but not ASP.NET...
user924016
@Fabien arrived where?
Started a new job here about 1.5 months ago
digital agency doing websites
good architects matter. If you don't have anyone controlling the overall design and structure of a system it will go out of control
user924016
08:54
oh, I missed that. Congrats on that
@Ocramius Can't you use any language with ASP.NET?
@AlmaDo Not really, they are good for not ending up with: ClassThatDoesSomethingImportantButHasDifferentResponsibilitiesFromOtherClassWit‌​hTheSameName
E_TOO_LONG ...
^ this has nothing to do neither with patterns nor with good code (:
@andho so far only saw ASP on it, but yeah, .NET should allow that
@Ocramius wat?
ASP.NET is written in C#
(Or VB.NET or any other .net language - but not really, in practice it's just C# )
08:57
@BenjaminGruenbaum company I worked before, they use ASP.NET only with VB and ASP
@AlmaDo It has, e.g. I may have class Contact under Controllers namespace and Contact under DomainObjects namespace. If I did not know their names, I'd have some awful naming.
ASP is not used as a language for quite some time.
@Ocramius was that in 2003?
No, 2012 :D
user924016
A arch is not splitting into layers.
@Ocramius that's like telling me 'the company I worked at (in 2012) used php 4.
08:58
Most probably, yes
not that they were much better (PHP-wise)
@Leri so use namespace. what that has to do with wrong naming conventions?
@Ocramius I hate VB so much, that I don't even mention it in resume. :D
user924016
Arch show intent. Like building a computer with ram, cooler, sddisk, processor does not tell anything about the architecture.
@Shog I missed the original question when I wrote the canonical. If you could merge one into the other it would be great. I don't mind which to which.
@BenjaminGruenbaum I should learn some C#, I just can't get myself to boot my windows PC anymore...
each time I do it, it feels like I'm torturing it
09:00
:P
@AlmaDo That other devs can easily find stuff in my code. :)
@Ocramius funny, that's how I feel when I run PHP :D
user924016
off to work cya
@Leri with that name? (:
I'm all for learning another language, I just hoped it was Ruby/Python/Java/LUA/C# !ASP.NET
09:01
my 7 month ruby experience was sad
@Fabien ASP.NET is not a language.
^ hehehe
It's as much of a language as the php SAPI is a language.
How does it work?
Guys, I run out of ideas and need help
for the given code:
var_dump(get_include_path());

require_once 'Zend/Application.php';

$reflector = new ReflectionClass('Zend_Application');
echo $reflector->getFileName();
09:03
@Fabien In a .NET language - for example I write asp.net code in C#.
how can we get the following output:
string(93) ".:/usr/share/php:/usr/share/pear:/<private path>/components/php" /<private path>/components-vendor/ZendFramework/1.12.0/library/Zend/Application.php
???
^ Mac OS?
nope
but even having Mac wouldn't explain it
how the hell it knows about components-vendor path?
@Fabien asp.net is just the web stack.
it may - because of some strange "private" prefix (or structure?) with some path there..
09:06
Ah I see.
it's just a normal path
I replaced it to not expose
treat /<private path>/ as some /real/fs/path
ah, got it
So when using the .NET framework, what languages are applicable?
@Fabien If you really want, you can use ASP.NET with C# like you'd use PHP in a page based model. It's rarely done that way in practice though.
any that are compiled to IL
09:07
Would probably not be done then if the target is more business
@Fabien anything that runs with .NET , you can use C# (I do) but also VB.NET, or F#, or Python, or even PHP if you really want.
You can even use C++ if you want.
So ASP.NET and .NET are the same?
ignore that
MS naming conventions dont seem to help
I hate the naming conventions too.
45
Q: Relationship between C#, .NET, ASP, ASP.NET etc

Samuel WalkerI'm really unclear on the difference between C#, C#.NET and the same for ASP and other '.NET' languages. From what I understand, .NET is a library/framework of... things. I think they're essentially access to Windows data such as form elements etc, but that doesn't seem to apply for ASP.NET. In...

@Fabien Any language that compiles down to IL
Even your custom one.
Your compiler should follow CLS, though.
09:12
@Ocramius is it possible to add a fields from other tables to an entity with doctrine? I have t_article and t_article_information but I want fields from both tables in my Article object
@Ocramius try mono
Ooh cheers @Leri
People always underestimate the importance of tooling. Mono has inferior tooling.
Hey @salathe
09:13
@andho that's exactly why I don't try C#
@Patrick is it a joined table table inheritance?
I should wake up and stop sounding like doge. "much tooling, very wow"
heh
@zerkms it knows where it loaded the class from
btw found how it works
@andho ?
what "it" ?
php
:14485256
09:15
"it knows" is a bit non techy
@AlmaDo we finally agree on something
Mornings
with "god help" would sound the same for me
hi, @DaveRandom
@Ocramius in this case yes, but I'll have to work with worse things too. Ideally I would be able to write the joins myself that are required to get the fields. I am working with one big mess of a legacy database here :(
09:16
@Ocramius actually C# is reeeeeeeeeeeeeally cool
@zerkms if php needs to load a class, php will need to know where this class is stored (in a file somewhere). So it already knows where the class is loaded from
@andho there is nothing about classes in my code
@zerkms yes, but I can't use it reliably on a non-windows box
Morning @DaveRandom
@andho I was just requiring an arbitrary file
09:17
so the entire C# thing is moot
@zerkms what's that ReflectionClass
@Patrick wait... you're adapting a legacy DB to D2?
@andho it's to determine if the class was defined and if it was - where
@Patrick willingly?
09:18
@andho in this case it was used to demonstrate that the path used isn't in the include_path
components-vendor is not in "."?
nope
@Ocramius semi-willingly. I would prefer to write my own repo/mapper solution but that doesn't seem to be an option right now unless the existing solutions can all be shown to be incompatible :(
it was one of my guesses :-)
@Patrick doctrine's JTI works only if you have the PK column shared among all tables, and a discriminator column
09:20
@andho anyway, it was a symlink :-)
@zerkms hehe
/<private path>/components/php has Zend directory
which symlinks to a corresponding dir in components-vendor
@Ocramius I am a bit confused. I'll guess I'll dig around in the docs some more...
@Patrick try generating a DB from a JTI, then you'll see how it should look like for yourself
Changing the db is not an option though, we have a lot of legacy code running that will be replaced part by part in the future, but until we have moved everything changing things is not really a viable option. We are lucky that everything runs right now ;)
Hey @Jimbo
@Patrick the art of making art from crap
^ totally irrelevant to sentence above
@AlmaDo still a terrible movie :P
@Patrick yeah, so it won't work, most probably. You'd likely build an association and keep the fact that it's an association hidden by the entity public API
rhetorical question: why it's debug_print_backtrace not print_debug_backtrace ?
09:32
Goedemorgen room
1 message moved to /bin/gif
well, if I change it to not rhetorical will anyone answer?
@zerkms runkit_redefine_function() :-)
... or modify and recompile sources, yes
but it's about the original aim. Isn't it convenient to put the action at the first place
@Jimbo lulz
hi guys, sorry to interrupt, I got an open bounty on a PHP memory question that's going to expire soon, but haven't found a satisfactory explanation yet, anyone care to give it a go? stackoverflow.com/questions/21353706/…
09:42
@zerkms why str_rot13 and md5? (not str_md5, for example)? Why array_map and array_filter have different callback order? Why .. (it's PHP, so it's about legacy in 99% cases)
array_map and array_filter bite me back every time :|
@zerkms kind of psuedo namespacing debug_
@Ocramius and I hate PHP's sort() and Co (which are impossible to use in expressions because of sh*t return-by-reference)
@zerkms action - debug; sub-action - print (?)
There's not such thing as debug backtrace afaik.
@Ocramius That guy who posted the Wordpress article. What a nob.
09:50
halo
hey guys
going a bit nuts over a laravel issue i'm having with LessPHP - anyone had any experience with this?

« first day (1207 days earlier)      last day (3967 days later) »