crossbario / crossbar

Crossbar.io - WAMP application router
https://crossbar.io/
Other
2.05k stars 274 forks source link

Crossbar on Linux 4.6.4 / Python 2 does not work #839

Closed Lechindianer closed 8 years ago

Lechindianer commented 8 years ago

Installed crossbar in a new virtualenv via pip and tried to run the python/html5 template

crossbar init --template hello:python --appdir hello

However the only output I see is. Opening the JavaScript console doesn't show any output. I did run the "crossbar start" command via strace - see strace's output. When I run the same commands on Ubuntu 16.04 the behaviour is as expected - crossbar writes log messages on stdout and there's some output on the JavaScript console as well.

 Crossbar.io        : 0.14.0
   Autobahn         : 0.15.0 (with JSON, MessagePack, CBOR, UBJSON)
   Twisted          : 16.3.0-EPollReactor
   LMDB             : 0.89/lmdb-0.9.18
   Python           : 2.7.12/CPython
 OS                 : Linux-4.6.4-1-ck-x86_64-with-glibc2.2.5
 Machine            : x86_64

Installed dependency version via pip:

argh (0.26.2)
attrs (16.0.0)
autobahn (0.15.0)
cbor (1.0.0)
cffi (1.7.0)
click (6.6)
crossbar (0.14.0)
cryptography (1.4)
enum34 (1.1.6)
idna (2.1)
ipaddress (1.0.16)
Jinja2 (2.8)
lmdb (0.89)
MarkupSafe (0.23)
mistune (0.7.3)
netaddr (0.7.18)
pathtools (0.1.2)
pip (8.1.2)
psutil (4.3.0)
py-ubjson (0.8.5)
pyasn1 (0.1.9)
pyasn1-modules (0.0.8)
pycparser (2.14)
Pygments (2.1.3)
PyNaCl (1.0.1)
pyOpenSSL (16.0.0)
PyTrie (0.2)
PyYAML (3.11)
requests (2.10.0)
sdnotify (0.3.1)
service-identity (16.0.0)
setproctitle (1.1.10)
setuptools (24.0.3)
shutilwhich (1.1.0)
six (1.10.0)
treq (15.1.0)
Twisted (16.3.0)
txaio (2.5.1)
u-msgpack-python (2.1)
watchdog (0.8.3)
wheel (0.29.0)
zope.interface (4.2.0
oberstet commented 8 years ago

Sorry, no clue. Linux-4.6.4 seems quite new. Xenial is 4.4. Mmh.

Lechindianer commented 8 years ago

Apparently there's a problem with newer kernels exactly as you've foreseen. The following config works fine:

 Crossbar.io        : 0.14.0
   Autobahn         : 0.15.0 (with JSON, MessagePack, CBOR, UBJSON)
   Twisted          : 16.3.0-EPollReactor
   LMDB             : 0.89/lmdb-0.9.18
   Python           : 2.7.12/CPython
 OS                 : Linux-4.4.15-1-lts-x86_64-with-glibc2.2.5
 Machine            : x86_64
FirefighterBlu3 commented 8 years ago

I'll test it shortly as I'm using Arch Linux, but I had to downgrade twisted to 16.2.0 as incoming connections made the http upgrade for the websocket but crossbar never answers the realm join request.

FirefighterBlu3 commented 8 years ago
 Crossbar.io        : 0.14.0
   Autobahn         : 0.15.0 (with JSON, MessagePack, CBOR, UBJSON)
   Twisted          : 16.3.0-EPollReactor
   LMDB             : 0.89/lmdb-0.9.18
   Python           : 3.5.2/CPython
 OS                 : Linux-4.6.4-1-ARCH-x86_64-with-arch
 Machine            : x86_64

crossbar starts up and runs fine with my dynamic authenticator and my asyncio based provider.py starts up and runs fine. all interaction between the web client and the provider is normal. AFACT, kernel 4.6.4 on Arch Linux is a-ok.

Lechindianer commented 8 years ago

Hmm... If I use python3 for crossbar like @FirefighterBlu3 did crossbar starts up fine on kernel 4.6.4

EDIT: Maybe the title "crossbar doesn't work with newer Linux kernels" would be more appropriate?

oberstet commented 8 years ago

So, it works on 4.6.4 using Python 3, but not Python 2? If this is the case, then it might even be a Python 2 issue (or a Twisted one).

@Lechindianer could you please post the output of crossbar start --loglevel=debug when running on Python 2 (where it fails)?

Lechindianer commented 8 years ago

Hmm, something on my laptop must've changed since. If I start crossbar==0.14.0 in a virtualenv I cannot reproduce the behavior anymore

oberstet commented 8 years ago

Ok, so closing as invalid