Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

uvloop crashed and core dumped #41

Closed
cwt opened this issue Jul 12, 2016 · 11 comments
Closed

uvloop crashed and core dumped #41

cwt opened this issue Jul 12, 2016 · 11 comments
Labels

Comments

@cwt
Copy link

cwt commented Jul 12, 2016

  • uvloop version: 0.4.33
  • python version: 3.5.1
  • platform: VMware Photon Linux 1.0

I just rebuild my wormhole proxy docker image today (Dockerfile). After I use it for a few minutes, it crashed and show error messages like these (randomly on each time it crashed).

python3.5: src/unix/core.c:236: uv__finish_close: Assertion `handle->flags & UV_CLOSING' failed.

or

python3.5: src/unix/core.c:264: uv__finish_close: Assertion `0' failed.

or

python3.5: src/unix/stream.c:444: uv__stream_destroy: Assertion `(((const QUEUE ) (&(stream->loop)->active_reqs) == (const QUEUE *) ((QUEUE *) &(((&(stream->loop)->active_reqs))[0]))) == 0)' failed.

I also tried to build it on Alpine Linux image (Dockerfile) the result is also the same.

BTW, I have no problem with the previous image that was built around 2 weeks ago, the uvloop version on that image was 0.4.30.

@1st1
Copy link
Member

1st1 commented Jul 12, 2016

Could you please tell how to run your proxy without docker? I.e. should I just clone the repo and run some script? How to enable uvloop in it?

@1st1
Copy link
Member

1st1 commented Jul 12, 2016

I've just committed a small change - 2b060e1 - please check if it fixes the problem.

@cwt
Copy link
Author

cwt commented Jul 12, 2016

to run it without docker:

$ pyvenv-3.5 wormhole
$ source wormhole/bin/activate
(wormhole) $ pip install Cython
(wormhole) $ pip install uvloop
(wormhole) $ pip install wormhole-proxy
(wormhole) $ wormhole

I'm cloning and building uvloop from git now. Will post the results again after finish.

@cwt
Copy link
Author

cwt commented Jul 12, 2016

unfortunately, it still crashed with the same error messages.

@1st1
Copy link
Member

1st1 commented Jul 12, 2016

to run it without docker:

Thanks! And what should I do to crash it?

@1st1
Copy link
Member

1st1 commented Jul 12, 2016

OK, I got it. Once I set up Firefox to use it, it crashed almost instantly.

@1st1 1st1 mentioned this issue Jul 12, 2016
@1st1
Copy link
Member

1st1 commented Jul 12, 2016

Should be fixed by 7b0b195. Will issue a new release soon.

@1st1
Copy link
Member

1st1 commented Jul 12, 2016

Please try uvloop v0.4.34.

@1st1 1st1 added the resolved label Jul 12, 2016
@cwt
Copy link
Author

cwt commented Jul 13, 2016

Yeah! my proxy work pretty well with v0.4.34. Thank you.

@cwt cwt closed this as completed Jul 13, 2016
@1st1
Copy link
Member

1st1 commented Jul 13, 2016

Thanks! See also #37 (comment).

@Mark90
Copy link

Mark90 commented Aug 10, 2023

Sorry to bump an ancient thread. I just noticed an almost identical error in our application (running in k8s but that's probably not relevant)

The exact error has a slightly different line version than in OP (but it's 7 years later so 🤷 )

python: src/unix/core.c:259: uv__finish_close: Assertion `!(handle->flags & UV_HANDLE_CLOSED)' failed.

I just see 1 occurrence of it from 2 weeks back, all other k8s pods have been running fine. So there doesn't seem to be a permanent problem, but I'll just leave some breadcrumbs here.

Software versions:

Uvloop: 0.17.0
Docker base image: python:3.11-slim
Python version: 3.11.3

Not sure if any of the other python package versions matter, but just in case:

anyio 3.7.0
hypercorn 0.14.3
starlette 0.27.0

Output of several commands ran from the k8s pod, i.e. about the host OS:

www-data@production-ims-fbcfff76-jt84d:/usr/src/app$ uname -a
Linux production-ims-fbcfff76-jt84d 5.15.0-1039-azure #46-Ubuntu SMP Mon May 22 15:18:07 UTC 2023 x86_64 GNU/Linux
www-data@production-ims-fbcfff76-jt84d:/usr/src/app$
www-data@production-ims-fbcfff76-jt84d:/usr/src/app$ source /etc/os-release && echo $PRETTY_NAME
Debian GNU/Linux 11 (bullseye)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants