CherryPy goes down after start

Open
#244 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
25/100
Issue type
Bug
Clarity
Needs clarification
Activity status
Stale
Tech stack
python
Domain
networking

Research direction

Start from WebSocketPlugin(cherrypy.engine).subscribe() and the CherryPy engine startup path, using the reported log and the case where the subscription is removed as a comparison. Reproduce the immediate shutdown and identify why the bus exits; done means the WebSocket plugin remains enabled while CherryPy stays running.

Written by the indexing model from the issue text.

Description

Hello.

I've arranged test project to learn ws4py and it worked perfect. But when I moved code to development env CherryPy start to go down right after start:

[28/Jun/2018:14:50:39] ENGINE Bus STARTING
[28/Jun/2018:14:50:39] ENGINE Starting WebSocket processing
[28/Jun/2018:14:50:39] ENGINE SA plugin started
[28/Jun/2018:14:50:39] ENGINE Setting up Mako resources
[28/Jun/2018:14:50:39] ENGINE VideoGenerator plugin started.
[28/Jun/2018:14:50:39] ENGINE Serving on http://192.168.51.74:8080
[28/Jun/2018:14:50:39] ENGINE Bus STARTED
[...]\Python\Python36\lib\site-packages\cherrypy\process\wspbus.py:258: RuntimeWarning: The main thread is exiting, but the Bus is in the states.STARTED state; shutting it down automatically now. You must either call bus.block() after start(), or call bus.exit() before the main thread exits.
  'main thread exits.' % self.state, RuntimeWarning)
[28/Jun/2018:14:50:39] ENGINE Bus STOPPING
[28/Jun/2018:14:50:40] ENGINE HTTP Server cherrypy._cpwsgi_server.CPWSGIServer(('192.168.51.74', 8080)) shut down
[28/Jun/2018:14:50:40] ENGINE Terminating WebSocket processing
[28/Jun/2018:14:50:40] ENGINE VideoGenerator plugin stopped.
[28/Jun/2018:14:50:40] ENGINE Freeing up Mako resources
[28/Jun/2018:14:50:40] ENGINE SA plugin stopped.
[28/Jun/2018:14:50:40] ENGINE Bus STOPPED
[28/Jun/2018:14:50:40] ENGINE Bus EXITING
[28/Jun/2018:14:50:40] ENGINE Bus EXITED

Process finished with exit code 0

If I remove WebSocketPlugin(cherrypy.engine).subscribe() it starts okay but i need this plugin :-) Any suggestions how to force it work?

Dominant language
Python
Stars
1.1k
Forks
285
PR merge metrics
No merged PRs in 30d

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from Lawouach/WebSocket-for-Python

All issues in Lawouach/WebSocket-for-Python

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.