Skip to main content

Python client for Janus.

dev

Setup a venv:

$ mkvirtualenv janus
(janus)$ pip install -e .[test]

and test it:

(janus)$ py.test test/ --cov janus --cov-report term-missing --pep8

usage

Typical usage is to create a representation of your Janus Plugin:

class MyPlugin(janus.Plugin):

    name = 'janus.plugin.krazyeyezkilla'

    def sup(self, greets)
        self.send_message({'wat': greets})


my_plugin = MyPlugin()

setup a Session:

session = janus.Session('ws://127.0.0.1', secret='janusrocks')
session.register_plugin(my_plugin)

keep it alive:

session_ka = janus.KeepAlive(session)
session_ka.daemon = True
session_ka.start()

and then use your plugin:

my_plugin.sup('dawg')

release

Tests pass:

py.test test/ --cov janus --cov-report term-missing --pep8

so update __version__ in janus.py. Commit and tag it:

git commit -am "release v{version}"
git tag -a v{version} -m "release v{version}"
git push --tags

and travis will publish it to pypi.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

janus-gateway-0.1.2.tar.gz (8.9 kB view details)

Uploaded Source

File details

Details for the file janus-gateway-0.1.2.tar.gz.

File metadata

  • Download URL: janus-gateway-0.1.2.tar.gz
  • Upload date:
  • Size: 8.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for janus-gateway-0.1.2.tar.gz
Algorithm Hash digest
SHA256 3cc81913e661a25c0f909ff44be33ad771b871c995b660bc2b55bc843b51810f
MD5 3c5bf952098f248a2394f8adbcbdfec7
BLAKE2b-256 47956801df88dfb5bb3379936ba08117ec687d83667e00560a632ace556196f3

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

0.1.2 This release

1 file

0.1.1

1 file

0.1.0

1 file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page