« first day (2244 days earlier)      last day (2704 days later) » 

8:00 PM
@kelunik "Returns an arbitrary value"
and Promises are obviously included in arbitrary value
 
@bwoebi Promises aren't a value. They're a placeholder.
 
@kelunik Promises are an object like any other
 
user895378
So what's wrong with "always return a Promise" and return new Success($cb())?
 
@rdlowrey You can just return $cb() then.
 
user895378
Maybe I just don't have enough context on what the actual question is ...
 
8:02 PM
Hey guys, is anyone handy with elasticsearch / is there a better chatroom to ask about es?
 
@rdlowrey exampli gratia \Amp\pipe(). Functor accepts any value, promises are resolved. That makes it easy to chain waiting for promises (if they need to happen sequentially), without a coroutine.
 
user895378
Ah, yeah
 
oh fucking hell I hate SOAP so fucking much
Sorry needed to get it out
 
@rdlowrey But at the same time it easily permits to just quickly postprocess the value
 
@bwoebi Maybe we should add pipe to the interface, maybe instead just call it then.
 
8:04 PM
.... why?!
you do not need pipe to operate on promises
pipe is just a helper function
 
Well, actually we just need async function support so we have easier coroutines and don't need pipe.
@bwoebi Pipe generally makes code harder to read.
 
@kelunik so does then() and when()
 
We should have linting tools that forbid when and pipe in application code. :P
 
user895378
@kelunik agree
 
user895378
@kelunik agree
 
8:07 PM
@kelunik haha
 
user895378
pipe() is just a helper utility to make things easier if you're not using a generator ... which may not be something we should encourage ...
 
user895378
@kelunik agree
 
user895378
@kelunik is on fire :)
 
user895378
We should possibly be opinionated and not even give people the ability to subvert generator coroutines :)
 
@rdlowrey dunno, I find using an extra level of \Amp\resolve() if a single pipe() does it too a bit clumsy
i.e. compare
return \Amp\pipe($promise, function() {
    return $this->doAction();
});
// vs
return \Amp\resolve(function() use ($promise) {
    yield $promise;
    return $this->doAction();
});
 
user895378
8:10 PM
^ yeah it's nice in that case ...
 
Anonymous
A couple of things to remember here: (A) the OP's question is contextually based in PHP and an "MVC pattern" - even if you wish to argue semantics, it doesn't matter; and (B) nowhere in my answer did I mention any personal favorability of one framework over another, but simply posted a popular framework among the PHP community for others to learn from. Everything else in these comments are unrelated or opinion based. I see no harm in pointing users in a direction of seeing the underlying structure of a framework, any framework, to help broaden their understanding of PHP. — Half Crazed 4 hours ago
 
user895378
You lost me at "MVC"
 
@bwoebi Only, because we need that stupid resolve. See github.com/async-interop/event-loop/issues/115
 
@bwoebi See I am useful for something
 
@kelunik agree … but that doesn't change anything on the current situation.
 
8:12 PM
URL accessible when script ran via PHP interactive mode on terminal but same URL was not accessible when script ran via apache and throws error "fopen(): php_network_getaddresses: getaddrinfo failed: No address associated with hostname"
 
> HTTP/1.1 200 OK
\o/
@Jeeves is officially a human now
@mSatyam I call lies
 
which bot did you implement?
 
@kelunik I TBH do not particularly like the asnyc/await system … The current way with yielding/yield from'ing Generators and Promises on every level is more out of necessity than elegance…
 
didn't get you @PeeHaa
 
I have cleverbot now, but will add pandora support too
 
8:14 PM
oh nice
 
@bwoebi Uhm, why do you not like it?
 
@kelunik language support only would spare us of having to use resolve() with a function wrapper
 
@mSatyam The only thing I can think of is allow_url_fopen, but that gives a different error message AFAIK. So I assume you messed up the url somehow :)
 
@kelunik It still requires us to acknowledge what's async (i.e. Promise) and what isn't.
 
PeeHaa: making wild guesses about code that hasn't been shared since 1984
 
Anonymous
8:16 PM
God you're old
 
@bwoebi Sure, but that's a non-issue?
 
I just saw that number and thought the exact same thing
 
Anonymous
:P
 
/me bows
 
o/ @Farkie
 
8:16 PM
@bwoebi It removes a function call + a lot of boilerplate.
 
@kelunik well, we still have to yield every damn awaitable
@kelunik a bit of boilerplate.
 
How's it going, drunkard?
bwaha
 
@bwoebi You always have to do that. There's no real way around that.
 
No idea who you are talking about :P
 
@bwoebi A lot.
 
8:17 PM
@kelunik That's my point … there is.
 
you wish, last time I saw you, you were smashed
 
@bwoebi How so?
 
:D
 
btw, Rainbow Elephpant just got fully funded :D
 
Oh nice
 
Anonymous
8:18 PM
Eh
 
Someone put in a 3k order in apparently
 
And just in time
 
Anonymous
Dec 1 at 15:23, by Leigh
I have a good idea for a plan B. Support diversity without needing a prop.
 
@PeeHaa allow_url_fopen is On already is there something I should check in apache config
 
3 mins ago, by PeeHaa
@mSatyam The only thing I can think of is allow_url_fopen, but that gives a different error message AFAIK. So I assume you messed up the url somehow :)
Can you share your code?
 
8:19 PM
@kelunik you create contexts, a bit like Go, but only one context is running simultaneously, each time until it hits an I/O task. When the I/O task is hit, another context is run where the last task is already done.
And then you only have to acknowledge async contexts very locally
 
@bwoebi Tcl does that as well. But I don't know whether that's really good.
 
// open connection to Yahoo
$handle = fopen("http://download.finance.yahoo.com/d/quotes.csv?f=snl1&s=A", "r");
if ($handle === false)
{
// trigger (big, orange) error
trigger_error("Could not connect to Yahoo!", E_USER_ERROR);
exit;
}
 
and can have sync code persist alongside with async code, because sync code is ultimately only a single async context
@kelunik What are the issues?
 
@bwoebi What if you don't want to wait for something?
 
@kelunik then you create a new async context and let that run there?
 
8:22 PM
@bwoebi A new context if I want to run 3 requests concurrently?
 
i.e. async doJob();
@kelunik sure:
$jobs[] = async do1();
$jobs[] = async do2();
$jobs[] = async do3();
await any($jobs);
 
It's a lot more work. Not probably not as likely to be accepted by internals.
 
What does gethostbyname() give you @mSatyam
 
@kelunik That's the only issue. (the work; I do not think getting it accepted will be a big issue)
 
I have a nifty Log Parser program, and I break it within the first minute of using it. Yay me!
 
ThW
8:24 PM
@kelunik I implemented two options for the loaders ALLOW_FILE and IS_FILE.
 
@mSatyam can you ping the host manually on the server?
 
@kelunik The main question I have: what would the issues be, given that someone would implement that?
 
yes @Farkie I can ping even the same fopen is working when i do it from php interactive mode
 
Which OS?
 
@PeeHaa gethostbyname() returns me the same string I passed in the hostname string
 
8:27 PM
@bwoebi Dunno. Does it just wait on assignments?
 
@kelunik assignments? how are these related?
 
it passes you the domain?
not the ip?
or are you passing in an IP?
 
@bwoebi Where does it wait for I/O?
 
@kelunik inside the internal I/O functions in PHP
 
@Farkie I am not passing IP I am passing hostname and the OS is Fedora linux
 
8:29 PM
@Farkie It does that when it fails because PHP doesn't know how to design anything
> Returns the IPv4 address or a string containing the unmodified hostname on failure.
 
ahh
good job PHP
 
So stupid...
 
huh, wonder if it's SELinux?
 
@bwoebi I guess that's too much work. And more magic.
 
I've had that problem before
 
8:30 PM
SELinux is messing I also think
 
You should see that in the log :)
 
Which one?
 
@kelunik not sure how there's magic. It's just synchronous; and if you explicitly opt in, other things may run too
@Shafizadeh 5 obviously.
 
Check the audit log @mSatyam
 
@bwoebi Adding async somewhere up in the callstack does magic and makes things concurrent.
How are userland things implemented?
 
8:32 PM
@kelunik on top of PHP functions in any case, just like right now.
 
@bwoebi proof
 
@PeeHaa ok let me see if I find something there
 
@bwoebi Buffering is implemented in userland. There's no waiting on more I/O currently.
 
@kelunik ?
 
How do I implement a redis command? I have to send it and wait for I/O until the response is complete
 
8:34 PM
@PeeHaa nothing there in audit log
 
@kelunik You'd just fwrite() and then somewhere have a fread() in a while(true) loop (and setting the socket to non-blocking would make fread() return immediately when data is available instead of waiting for the whole length)
the waiting as said would be handled internally in fwrite/fread
 
@mSatyam ¯\_(ツ)_/¯ sounds like you need to burn it all and start over from scratch :P
 
@PeeHaa hmm will try re-installing LAMP
 
I doubt that will really help :D
Something cannot properly resolve the domain name
 
:(
But the the same gethostbyname is working from terminal
 
8:38 PM
@bwoebi and if it reads too much? then I can't have that in the function doing the request only.
 
@Tiffany The song you shared with me is pretty good, I am going to look into his other stuff
 
@kelunik I said, in a loop. You'd obviously still buffer there
 
What other music can you recommend? Haha I am always looking for new stuff
 
@Alesana Hello Always looking for new stuff. I am Jeeves. Do you mind if I just call you Always?
2
 
@Alesana which one?
 
8:38 PM
@PeeHaa should i post in fedora forum will that help
 
@Tiffany read the whole conversation…
 
(sorry @bwoebi)
 
@bwoebi I said too much, not too few bytes read.
 
Age of Shadows
 
@bwoebi wrong chat transcript :P
 
8:39 PM
@kelunik ? Not sure where the issue is. You feed the parser with all data and the parser stops there where he currently is?!
 
Anonymous
Hi. I'm the "Leave Britney Alone guy". I was a meme & laughing stock for 10 years. I delt it. You're the Presiden… https://twitter.com/i/web/status/806149539195420676
 
@JayIsTooCommon Savage.
 
@bwoebi General thought was that if you had a promise, you should just be returning that, but I see your point.
 
@JayIsTooCommon I still think you need to do a video
 
@kelunik If you read too much, the parser should just continue the parsing and return when he's done?
 
8:42 PM
@Alesana this is stuck in my head: Set Your Controls (based on Doctor Who)
 
Most of the time functions should be either returning a value or a promise, not either one.
 
@Trowski Most of the time, yes, agree.
but that's TBH not our job to ensure inside Success ctor
 
The restriction is somewhat arbitrary though, so I'd have no problem with removing it.
 
Anonymous
@PeeHaa I am more than tempted
 
Anonymous
Ty mobile
 
8:44 PM
Yeah thanks mobile
 
ThW
@kelunik I still need to add some tests, but I think the problem you reported is solved. Thanks again.
 
Which one is correct?
- Who comes which me {somewhere} ?
- Who come with me {somewhere} ?
 
The latter
Who comes with me {somewhere}?
well, with the s at the end of come.
 
the latter doesn't have "s" .. So finally which one?
 
Who comes with me {somewhere}?
 
8:46 PM
thx
 
with means "accompanying" which is a preposition. which is a called a "determiner," it's used to clarify information.
 
The correct sentence is: COME AT ME BRO
 
@Tiffany I see
@PeeHaa I never get you BRO ..! :-) What do you mean exactly ..
 
@Shafizadeh It's a meme.
 
!!urban come at me bro
 
8:49 PM
[ COME AT ME BRO ] A phrase popularized by Ronnie from MTV's latest train wreck of a reality show, [Jersey Shore].
 
oh .. I see
interesting
 
US TV is silly.
@Shafizadeh does Iran have reality TV shows?
 
are shows and series the same?
 
"Series" usually is a collection of shows
 
I see
 
8:51 PM
@PeeHaa there is some news I would like to give
 
and yes .. TV has lots of shows in here -)
 
@mSatyam It better be good ;-)
 
@ThW I'm happy to review the patch.
 
@Tiffany That one says "This video is not available."
 
Reality TV is something specific, where TV crew follows "real life" people and is supposed to be "unscripted"
 
ThW
8:52 PM
@kelunik Not a patch, I have it in the master branch :-)
 
Series can mean the same thing as TV Show, however it can also be a collection of movies or shows. ie. The Star Wars series
 
@PeeHaa Actually I had made virtual host for my site on my local server as I have hosted many sites, I removed all of the virtual hosts and accessed the site using localhost URL and now everything works fine.
 
Odd
 
ThW
I should reverse the order of the BC breaks in the readme ...
 
@kelunik and btw. it won't be that much work; we'd basically need green threads, aka stacks we can back up.
 
8:57 PM
I hate when things starts working but i dont know the reason, anyway atleast it works
 
@Tiffany Ah okay.. I like it but not as much as the other one
 
@rdlowrey Do you know roughly why he left?
 

« first day (2244 days earlier)      last day (2704 days later) »