« first day (2737 days earlier)      last day (2211 days later) » 

Wes
12:05 AM
should accept doing some google maps work or it's going to be a pain in the neck
 
@Wes hey, don't deride gotos like that - at least they're not generating stack traces
 
Wes
the js api looks scary
all i did with google maps so far is copypasta snippets that happened to just work
now i am asked to set paths, colors, stuff. seems scary :B
also btw, something nobody will ever use. they are trying to optimize visits of sale agents to regular clients
i said it's not going to work, they didn't listen
firstly the sales agents can do well their own and they organize themselves good already
secondly, too many variables
traffic, absence of the clients
so basically it's going to be a big work for no real gain
 
ignore all that shit, "optimize" just means "a computer said so" to them
 
Wes
the "computer said so" program is what i am supposed to write
 
yes, I know
 
Wes
12:19 AM
basically they want predetermined paths like the ones that mail delivery services have
i said it's different, selling stuff is not like dropping a box and asking for a signature
 
my point is they'll never know the difference if you take all those variables into account or not, they just want a computer to say what to do
 
Wes
the agents have covered their zone for 20 years... i don't know why they think they need more help
i think the only advantage would be the list of all potential clients. some agents have 200+ clients and i imagine it's hard to keeping track of them all
 
hell, ask the agents what the paths should look like and hardcode that
 
Wes
lol
 
"hey, I've got this bad-idea project I'm tasked with. how can I make it not fuck you over?" - they'll be happy to help
 
Wes
12:26 AM
i'm sure nobody will follow the program anyway. young agents are just a few and old agents don't even use the program
the program might be useful to them, but it's redundant with the information they likely have on paper
the path is just too stupid. i think i'm just going to show a map based on their current location
i have information like "last time the client was visited" and i can display that on the map
that's going to be good enough i guess
also the agents visit only like 2-3 clients per day... they don't need a path for that
 
 
1 hour later…
1:34 AM
@Wes aside with an aria role of note may be appropriate
 
Wes
not sure about aside
but role note might be ok
looks like that is it
 
2:26 AM
I'm a quarter way through a 2,500 mile exodus in a car and Trump decides to start WW3. Awesome.
 
his lawyer got raided, he had to do something
 
I feel like I've got a head start on today ...
 
Wes
2:55 AM
you watching formula 1 too? :B
 
Wes
3:28 AM
so i can smoke cigs now?
 
3:45 AM
good morning room.
Happy saturday o/
 
Wes
4:10 AM
Is everyone seeing how incompetently our country is being run by watching the mess with Syria? Our leaders don't know what they are doing!
there's always a tweet
 
@Wes it's the flanderization of the GOP tradition of saying the government doesn't work then getting elected to prove it
 
Wes
lol
also til "flanderization"
a big war could easily start and the world is in the worst shape ever
i mean, we don't even have a government
also i have no idea why macron followed trump in this shit
 
@Wes as it turns out they're largely overrated
 
Wes
4:28 AM
i have lost all hopes
 
congratulations, you've reached adulthood
why do you think they let us drink?
 
Wes
the only positive thing about trump is that he clearly crazy and maybe putin is a sensible person enough to not wage war on the crazy dude with stupid hair and nuclear weapons
who would've thought we would rely on putin's (or even kim jong li)'s rationality to avoid big wars
also cc @JoeWatkins
 
sure, why not
 
Wes
and if you really want to prevent override, you should do that with final
btw final was proposed on the ml already, i think scott but maybe was davey
 
you digging in to write the patch yourself?
 
Wes
4:37 AM
i think pmmaga already did it
 
that's no fun
 
Wes
i am an inept, remember
 
when has that ever stopped you?
 
Wes
always stops me
should i propose final alongside that rfc?
 
nah, keep things simple
if you wanna do final, do it after
 
Wes
4:42 AM
ok
do you think i should explain with more details why the "feature" it's completely nonsense right now?
 
Wes
i've been criticized for providing not enough details in rfcs :B
i think they wanted to prevent override but it didn't work out
in practice people did override... i'm sure of that lol. so it should be allowed without limitations
 
"consistency pls" (and bc) is sufficient here. don't give people something to bite at.
 
Wes
okay
though, need to write for @pmmaga because it's his rfc. i just wrote it
all i can do is asking around what they think about it :B
btw, i should ask @Ocramius
 
btw "This doesn't work too" should be "This doesn't work either"
 
Wes
4:49 AM
thanks, fixing it
just thought of an issue
 
stop that
 
Wes
no, actually an issue
 
no, actually thinking
 
Wes
interface A{ const X = 1; }
class B implements A{ const X = 2; }
// this is fine. it's clear that the constant in the class overrides the one in the interface

interface A{ const X = 1; }
interface B{ const X = 2; }
class C implements A, B{} // what about this, though?
that explains why there is this limitation
 
flip a coin
or keep that as-is. whatever.
 
Wes
4:59 AM
must be cleaned up a bit. the restriction is applied also where there are no conflicts
everything's a mess
 
nowhere to go but up!
 
Wes
or to the center of the earth, crushed by the extreme pressure
 
potayto potahto
 
Wes
:B
 
5:41 AM
morns
 
5:55 AM
I know the user ID and password a large dataset. Instead of manually logging in to get each data separately, is there any way to collect all the data together ?
 
hello, how would you explain this? php.net/manual/en/iteratoraggregate.getiterator.php ; Return Values - An instance of an object implementing Iterator or Traversable
php.net/manual/en/class.iteratoraggregate.php ; "IteratorAggregate extends Traversable"
and by the description - IteratorAggregate::getIterator — Retrieve an external iterator
public function getIterator() {
return new ArrayIterator($this);
}
}
this is within a class - "class myData implements IteratorAggregate"
so getIterator which "descends" from IteratorAggregate will "retrieve an external iterator" (here the ArrayIterator) - and something like this will always be (return) an instance of an object implementing "Iterator or Traversable"?
it seems like the Traversable is always part of this
Interface synopsis:
 
Wes
Iterator extends Traversable
IteratorAggregate extends Traversable
 
IteratorAggregate extends Traversable {
/* Methods */
abstract public Traversable getIterator ( void )
}
 
Wes
not sure what the question is
but traversable should not be used, especially now that we have iterable
 
so anything within the getIterator {} will be an instance of an object, correct?
ok
I just dont fully understand
 
Wes
6:05 AM
what do you mean anything within getiterator
 
and I've been stuck on this for a while, since yesterday evening, lets say
 
Wes
getIterator returns an iterator
 
Wes
so?
 
IteratorAggregate:getIterator - Return Values - An instance of an object implementing Iterator or Traversable
this is what I am wondering about
 
Wes
6:07 AM
no, an instance of an object implementing Iterator
 
so anything that the getIterator gets() will be an instance of an object?
I am assuming yes
so getIterator always gets what is an instance of an object
and this object always implements Iterator or Traversable
but IteratorAggregate always extends the Traversable - php.net/manual/en/class.iteratoraggregate.php
so lets say the OR part "An instance of an object implementing Iterator OR Traversable" - so this is correct?
is it not the Traversable 100% of the time?
 
Wes
getIterator must return Iterator
the fact that might return traversable is only for internal use
 
and the Iterator I am familar with, this is the current, key, next, rewind, valid
yes because the Traversable is internal, like written in C
 
Wes
3v4l.org/Kci1f this is still an error
 
so no direct access to that
 
Wes
6:11 AM
even if $this is traversable
it's classic php weird stuff
 
so basically this could be worded differently, I guess - "An instance of an object implementing Iterator OR Traversable"
not 100% good description, it would be / could be?
on the php.net
ok, I think I get that
thanks
and what it will get will always be an instance of an object
and objects are created from classes...
so there is a class, somebody created and object from it and what the getIterator gets is an instance of this object...
 
6:27 AM
so what IteratorAggregate:getIterator returns is always an instance of an object and it can be implementing the Iterator but if it does not implement that (as there may be such cases) it will be implementing the Traversable? And also, if it implements the Iterator it does not implement the Traversable at the same time?
Iterator extends Traversable
IteratorAggregate extends Traversable
 
Wes
7:10 AM
the documentation should say "an object implementing Iterator" - the end
the fact that it can return traversable is solely for php's internal usage
 
ok, thanks again
Traversable - Internal (built-in) classes that implement this interface can be used in a foreach construct and do not need to implement IteratorAggregate or Iterator.
so maybe this would be it
maybe the IteratorAggregate can work with these, and they use the Traversable but not the Iterator...
I am still researching this, I will post what I came up with
 
Hello Team
How to save X and Y coordinates using javascript?
Can anyone help me?
 
google.com -> "how to save x and y coordinates javascript" is a good start
 
Do you know @ten5?
 
7:54 AM
@RuchiPatel If you are asking about coordinates of mouse pointer then look at this: developer.mozilla.org/en-US/docs/Web/API/MouseEvent/clientX
 
But how can I save it's values?
 
carking Archaic. distressful.
 
!!dad
 
Why did Google Car switch from MD5 to SHA512? They wanted to reduce collisions.
 
@RuchiPatel save where?
 
8:02 AM
in local browser
 
like what? A cookie?
 
Wes
8:32 AM
@PeeHaa looks like i broke the alternator :( flat battery
doesn't charge.
pffffffffffffffffffffffffffffffffffffffff
 
8:56 AM
mornin
 
@mega6382
No in localstorage
 
then just google how to store data in localstorage
 
morning
 
@RuchiPatel Also, go to the JS room, cause this is not a php problem.
 
@mega6382
I have posted my question in that room also
But no one is reply my message
 
9:05 AM
@RuchiPatel what do you want to ask?
 
I am stuck in how to store X and Y coordinate values in localbrowser?
 
mornings
 
Actually my requirement is what,
When users of my site drag the items around, and then refresh or leave and return to the page, i would like those items to remain in the same place.
 
Wes
a blast from the past
hakre and nullpointer
what's that preg_ flag that includes empty capturing groups in $matches? e.g.
(?: xxx (this is not included, want it to be null if possible) )?
found it PREG_UNMATCHED_AS_NULL
 
9:22 AM
@Wes oh yaa man :D how you doin'?
@hakre hola buddy
 
Wes
pretty bad, i'm fighting with pcre
regexp that works on regex101 doesn't work in php
likely because escaping
 
But what if you’re defining an interface that’s iterable as part of its contract? Should your interface extend Iterator or IteratorAggregate?
 
i have no idea about that now :D however i am trying to learn JS (Angular, nodeJS)
 
Neither. Instead interfaces should extend Traversable directly.
 
On first sight I might jump to the conclusion that w/ any more context this is bad advice.
 
Wes
9:27 AM
found the problem
@ten5 i'd say no
everything should use iteratoraggregate, because if you extend iterator well, you are doing it really wrong (spl level wrong)
 
ok, thanks, I thought I found the answer but I am tired
but I am still looking for an answer to this...
 
@Wes Iterator is an interface ...
 
ok, thanks again
 
@ten5 To what?
 
like I said, I am tired and I wont be bothering here
 
9:30 AM
?
 
This confuses me
 
Wes
@hakre do you usually add methods to iterator, other than the ones in iterator?
 
php.net/manual/en/iteratoraggregate.getiterator.php - Return Values - "An instance of an object implementing Iterator or Traversable"
the quoted part
 
@ten5 With PHP 7 choose the iterable pseudo type for type hinting.
 
Wes
it's php bullshit, ignore it @ten5 told you already, getIterator() should return Iterator
 
9:32 AM
ok
 
Wes
iterators should be iterators only
class MyArray implements Iterator{} that's a bad idea
 
@Wes Depends on what I'd like to decorate as an Iterator.
 
Wes
iterators are views over the storage
separation of concerns @hakre
iterator is one thing, storage is another
 
@Wes class MyArrayIterator implements Iterator however might not. MyArray::getIterator() : MyArrayIterator then.
 
Wes
correct
that's basically spl main error, the primary reason it sucks
 
9:34 AM
Iterator is Traversable based so "Iterator OR Traversable"?
 
Well SPL offers iterator aggregation ... .
 
when i started writing php i always thought why do i even need this billions of functions shit when all i need to do is data processing and some other subtle things like login and encryption, however i still do :s
 
Wes
iterator implies traversable
 
what would be the "Traversable" things that dont come with using the "Iterator" part?
 
Wes
omg
 
9:36 AM
ok, I kind of had this point of view earlier, like I understand the sentence wrong
as an aside, I think that the php.net was written by not a native English speaker
 
Wes
docuentation is wrong @ten5 kinda
 
I am not a native English speaker too
 
Wes
it does allow any traversable, but in practice it doesn't
 
but I come across quite a lot of things that I dont understand and they could be written in a better way English-wise
 
Traversable is an internal interface. You don't use it in PHP userland for most of your life.
 
Wes
9:37 AM
if you have getIterator() returning an iteratoraggregate it will throw
which means the only type you are allowed to return from getIterator() is Iterator
 
@hekre - not most of the time, never I think, but I dont want to argue or anything
this is like something that is written in C, it is "under the hood"
getIterator "originates" from IteratorAggregate, it descends from it
 
Wes
getiterator is a method in iteratoraggregate
how can it descend from it?
 
I mean IteratorAggregate::getIterator
 
Wes
it's a method.
 
like I said, I want be bothering here and causing confusion, I need to take a rest and research it further
ok
 
Wes
9:40 AM
$iteratorAggregate->getIterator()
iterator instead is:
$iterator->valid();
$iterator->rewind();
$iterator->key();
etc
$iteratorAggregate->getIterator()->rewind()
makes sense?
 
No, IteratorAggregate::getIterator() can return any Traversable.
This includes IteratorAggregate.
 
"returns an external iterator" - so it can be THE Iterator - php.net/manual/en/class.iterator.php or some other one that does not incorporate that?
and that could be that OR Traversable part?
 
I mean not external iterators have to be THE Iterator - php.net/manual/en/class.iterator.php - so the Traversable is "under" THE Iterator but there can be other objects like this and they also would be Traversable based, but not The Iterator based
THE Iterator - current, key, next, rewind, valid - this thing
IteratorAggregate:getIterator - Return Values - An instance of an object implementing Iterator or Traversable
 
IteratorAggregate is a Traversable
 
9:45 AM
so it can be THE Iterator (current, key, next, rewind, valid), but it does not have to be. And the things that would not be THE Iterator would always be the Traversable based, and THE Iterator is also Traversable based
this is correct, if yes, what are these other things?
again, like I said, I am tired
so I am not at 100% of wrapping my head around all this, but like 80%
 
Wes
@hakre have you tried.
 
Fatal error: Uncaught Exception: Objects returned by Foo::getIterator() must be traversable or implement interface Iterator in /in/Kci1f:10
"traversable or implement interface Iterator" - so what are the things that are traversable and dont implement the interface Iterator?
we have it must be A or B
B is THE Iterator, what is the A, "Traversable"
the error sounds like the manual page
so it shows that the meaning is there
 
Wes
@hakre wrong question: would you do that?
 
@Wes That is how iterataion aggregation works I suppose.
For my taste the example given is sort of indirect, and I'd say it requires some reasoning why to do that, so out of nothing, I perhaps just would foreach an array to begin with?
 
9:51 AM
Look Mum, IteratorAggregate! - is this complete example?
but my point is clear or clearer now - "Objects returned by Foo::getIterator() must be traversable or implement interface Iterator"
 
@ten5 Sort of it is, however an iteration example normally shows the iteration, which it does, however as it is empty it could be argued it does not show the iteration in an easy manner.
 
so we have two separate things, just like the man page says
it must be 1) Traversable or 2) implement interface iterator
 
@ten5 To tell you the truth, any Iterator actually also is a Traversable.
 
yes, the #2, THE Iterator is Traversable based
but what is the "traversable" that is not THE Iterator in this error?
or what are the traversables?
must be traversable so this may be an adjective
 
That error only gives you two options, these may overlap, there is nothing said that those two are exclusive to each other.
 
9:54 AM
but still a separate thing
yes, but this is strictly what I dont undersand
I know THE Iterator
what would be a code example that does not produce an error and is not THE Iterator based?
 
(don't write / caps all the time "the", just give it a large I for the "Iterator" and if you like to make clear you mean the interface, set it in italics, and if it is a class implementing that interface, write it bold)
 
Wes
@bwoebi @NikiC this is a bug imho
https://3v4l.org/1ulVZ
https://3v4l.org/WiDVj
the last one is not included despite PREG_UNMATCHED_AS_NULL
 
like I said, I will go over your info again, I am tired
 
@Wes Which of those two do you think is wrong? Both?
 
Wes
the first one
the (x) capturing group is not included in $matches, should be NULL
 
10:01 AM
if I can ask, how would you reword "An instance of an object implementing Iterator or Traversable", based on your "comprehenshion" of this?
 
@Wes The pattern of which it is part of does not match at all, it will never match, not even for NULL.
AFAIK that is always the case with numbered patterns.
You could try with named ones, but I dunno if that makes a difference.
 
thanks a lot, this is a lot of help
I could be stuck on this for days
I am still are actually
but there is a meaning to this
 
Wes
@hakre it should be included as NULL, given PREG_UNMATCHED_AS_NULL
but i don't understand regexps, so it's probably not wrong
 
@Wes Dunno, at least it does not even for named groups not matching: 3v4l.org/em6fi
 
ThW
10:05 AM
@ten5 Some of the classes in the extensions implement only Traversable, not Iterator
 
can you give me more info, and url or urls where to read
 
@Wes Hmm, regex are at least not really that easy to grasp - 3v4l.org/bn4fN
 
Wes
don't like named ones... too verbose
 
ok and "some of the classes" would be "the rest" of what is meant
they are not in just one place at php.net, not just one category, spread out in various places
anything in common, they would have?
this is the thinking that I've been looking for
We have A and B, A is xyz, B is B (The Iterator lets say) and I do undersant!!! and this would be great
for regex you can use the online regex tool, but you probably mean something more advanced
I read the whole regular-expressions.info
not the whole but the regex part, it took some time, I was getting stuck sometimes
but I have that done
 
@ten5 These vary, I once wrote a list, you can find it here: github.com/hakre/Iterator-Garden/blob/master/TRAVERSABLES.md
 
10:09 AM
ok, thanks a lot
so there was a meaning to this, and we found it!!!
thanks again
 
10:29 AM
.............................so. That's totally not yet another account for the person who is working their way through the manual rather than trying to make something.
 
Wes
hm, dunno
 
Not that many people
Write each new line
as it pops into their head.
Not that many people get stuck on trying to read and understand something from the manual. People get stuck on solving actual problems, which can then be explained with something from the manual.
 
Punctuation is for losers
 
@JayIsTooCommon you were asking about validation libraries the other day. What framework are you using? or at least what are you using to represent HTTP requests? e.g. psr7, symfony request bollocks?
 
Wes
oh madara is here and can check
but imho he's not that guy
that guy was impossible
 
10:42 AM
meh
wait till it becomes a problem.
Having dupe accounts by itself isn't necessarily bad - some people have legitimate reasons to not associate their work stuff with their own stuff. It's only when they're being used to dodge the site rules (like the ignore button) that it becomes a problem.
 
Wes
the guy i asked you to check the other day @MadaraUchiha we were wondering if the magenta guy above was the same guy
 
No. At least, doesn't looks like it.
 
Wes
but imo no
 
Wes
11:22 AM
someone has context for this twitter.com/balpha/status/984839394829000706
 
12:00 PM
last optional capturing group is not included when using PREG_UNMATCHED_AS_NULL – #76221
 
@Wes ugh
 
Wes
i actually can see it is broken
i hit it and started spinning and charged the battery a bit hopefully, i am looking for a replacement on ebay but no luck... gotta go mazda. hope it's not expensive
 
How?
ah
 
Wes
there is rust
.... for some reason
 
You can get a refurbished one
 
Wes
12:05 PM
or actually, oxidation
 
9/10 it's just the brushes
Is that correct english for it?
 
Wes
yes i think
i don't get how it works, but it doesn't look right. the case is all rusty underneath
but the copper inside looks ok
maybe the bearings
@PeeHaa if the alternator is stuck, shouldn't the transmission slip over the bearing?
because it wasn't spinning
 
Dunno
 
12:36 PM
@Wes I don't know, but if I may guess: Genda.
 
Wes
what's that
 
In this particular case, the born sex.
 
Wes
ah lol
 
I mean, that guy doesn't know that @tereško offers dedicated argumentation training for tech websites.
Otherwise he might have taken a look into the ratio of sexes in room 11.
Oh all these tweets.
 
Wes
you are being too cryptic i'm not understanding what you are saying
 
12:50 PM
Was just reading twitter, based on the link you posted.
The one guy that is self-said employee number 11 on SO.
And who started the job albeit he didn't found the team he works in inclusive enough.
There would have been something where he could have made a change for real in his life, but instead he comes out years later and lamenting that SO is not inclusive.
I mean how can the product of a non-inclusive team be inclusive after all?
 

« first day (2737 days earlier)      last day (2211 days later) »