by

Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Sep 21 2018 04:00
    sagebind closed #8
  • Sep 21 2018 04:00
    sagebind closed #7
  • Mar 20 2018 13:46
    henrywood edited #25
  • Mar 20 2018 13:45
    henrywood edited #25
  • Mar 20 2018 13:44
    henrywood opened #25
  • May 17 2017 09:57
    pentatonicfunk commented #21
  • May 17 2017 09:56
    pentatonicfunk commented #21
  • May 17 2017 08:11
    pentatonicfunk edited #21
  • May 17 2017 08:10
    pentatonicfunk opened #21
  • May 06 2017 13:13
    pentatonicfunk opened #14
  • Mar 17 2017 01:54
    trowski closed #17
  • Mar 17 2017 01:53

    trowski on master

    Deprecation notice (compare)

  • Feb 24 2017 21:17

    trowski on master

    Deprecation notice (compare)

  • Feb 24 2017 21:07

    trowski on master

    Deprecation notice (compare)

  • Dec 10 2016 00:53
    tak3r opened #5
  • Nov 29 2016 08:28
    lhfeng edited #6
  • Nov 29 2016 08:26
    lhfeng opened #6
  • Nov 23 2016 21:58
    lukaszwit commented #23
  • Nov 23 2016 21:58
    lukaszwit commented #23
  • Nov 23 2016 21:54
    lukaszwit commented #23
Aaron Piotrowski
@trowski
Right, it's just to show that the main thread isn't blocked.
Douglas Reith
@redthor
ok, thanks
Aaron Piotrowski
@trowski
unreference() removes the reference to the timer from the loop, so the loop automatically exists even though the timer is running.
Douglas Reith
@redthor
ah right
In my use case I don't mind if the main process is blocking because I need to get back both sets of results - should I change anything?
btw I have my test running :)
Aaron Piotrowski
@trowski
The main process will wait within the coroutine on the call to Awaitable\all($coroutines) but it doesn't block the process. You probably don't have to change anything though.
Douglas Reith
@redthor
great, thanks
Douglas Reith
@redthor
Ah the service that retrieves the results is not serializable - Serialization of 'Closure' is not allowed - I'll have to look at doing this another way
Honza Machala
@HonzaMac
@trowski I’m there. I’v pushed that into github
Honza Machala
@HonzaMac
So, when I put sendStatus()(aka fetchInit()) into Coroutine (to start them at once) it stopped working and I’receive in websocket opcode -1
Pavel Chebotarev
@nexor
@trowski I've tested postgres package at dev-master branch and it works perfectly at first sight.
Honza Machala
@HonzaMac
Hi @nexor . What kind of operations are you using with pg?
Pavel Chebotarev
@nexor
Simple insert for now
Honza Machala
@HonzaMac
I’m goingo to use this pg library to change our architecture ans speed up it. So I want know if its ready fro production :)
Pavel Chebotarev
@nexor
Not sure, in my opinion it is ready for production when it has version 1.x.x ;)
I'm using Icicle in my pet projects only, so I can afford any errors.
Honza Machala
@HonzaMac
Did you experienced some real bad errors?
Honza Machala
@HonzaMac

Hi all, how could i catch exception throwen from ->timeout() and not cancell all awaitables, but just few? @trowski
i’ve similar code to this:

                $coroutine = new Coroutine($generator);
                $coroutine->then(null, function (){
                    return 'aaaa';
                });
                yield $coroutine;

but it still keeps cancelling all the rest of code.

Pavel Chebotarev
@nexor

Did you experienced some real bad errors?

No. There is very basic functional and it works very good.

Honza Machala
@HonzaMac
Anybody here? :)
Aaron Piotrowski
@trowski
@HonzaMac $coroutine->then() returns another awaitable, so you should be yielding to that awaitable instead.
$coroutine = new Coroutine($generator);
$awaitable = $coroutine->then(null, function (){
    return 'aaaa';
});
yield $awaitable;
Honza Machala
@HonzaMac
Ah! I missed that @trowski thanks :]
Honza Machala
@HonzaMac
Hi all! I’ve question. Is it possible to detect in websocket app, that client closed browser/disconnected? I could’nt find it in doc.
Romain Laneuville
@ZiperRom1
yes, when the client close the browser the websocket session just end and resolve the coroutine. You can also monitor a "disconnected" action by sending data on disconnected event and manage the action in back-end.
while (yield $iterator->isValid()) {
        yield $this->serviceSelector(
            json_decode($iterator->getCurrent()->getData(), true),
            $client
        );
    }

    $this->onDisconnection($client);
Aaron Piotrowski
@trowski
The close status is also available through $iterator->getReturn(), so the last line could send the status to the method as well: $this->onDisconnection($client, $iterator->getReturn());
Honza Machala
@HonzaMac
Hi all, does anybody know, how to handle files in http server? Is there any documentation/branch for this?
Pavel Chebotarev
@nexor
@HonzaMac Hi! What do you mean? There is package for that purposes https://github.com/icicleio/filesystem
prdp
@prdp
Hello Anybody there?
DIR .
PHP Fatal error: Uncaught Error: Class 'Illuminate\Database\Capsule\Manager' not found
On laravel framework
prdp
@prdp
Uncaught Error: Call to undefined function Icicle\Coroutine\create()
Gayan Handapangoda
@gahalk
@trowski : Newbie here! First, thanks for the wonderful library. I need to create a client to subscribe to a websocket server (just by specifying the wss URI) and read through the messages using the Icicle\Loop. Just wondering if there's an already written one for that purpose?
chris
@parweb
hello everyone
i try since 2 day to understand correctly promise
pff ^^
my goal it's to "refactor" the javascript librairie https://github.com/facebook/dataloader in PHP
i have done allmost all the work but now i try execute againts the test suite provided by facebook for the JS but nothing seems to work accordingly :'(
chris
@parweb
so first question do you now a PHP librairie who works good with icicle if it's possible (2 day of hard work but love it ;)
Pavel Chebotarev
@nexor

a PHP librairie who works good with icicle if it's possible

Hi! Please explain, what kind of library are you looking for?

chris
@parweb
@nexor like this one https://github.com/facebook/dataloader in PHP with icicle
Pavel Chebotarev
@nexor
Not sure if it exists in PHP
chris
@parweb
@nexor soon it will, i almost finish
angel herrera sara
@gelsher_twitter
Hi all! I have a question. Why do I get this error "syntax error, unexpected '{', expecting identifier (T_STRING)" on this script "use Icicle\Http\Message{BasicResponse, Request, Response};"? Moreover I am using php v5.5.12, "icicleio/icicle": "^0.9.6",
"icicleio/http": "^0.3.0".
angel herrera sara
@gelsher_twitter
The example is from https://github.com/icicleio/http
Pavel Chebotarev
@nexor
use Icicle\Http\Message{BasicResponse, Request, Response}; does not work on php 5.5, only on 7. You need to checkout icicle for php 5.5
lukaszwit
@lukaszwit
Quick question: is there any way to use icicleio/http with HTTP2 ?