github nats-io/nats.py v0.8.2
Release v0.8.2

latest releases: v2.9.0, v2.8.0, v2.7.2...
6 years ago

Added

  • Support using tls scheme to setup default context to connect securely (#88)
    await nc.connect("tls://demo.nats.io:4443")
    await nc.connect(servers=["tls://demo.nats.io:4443"])

Example using nats-pub & nats-sub:

$ python3.7 examples/nats-pub -s tls://demo.nats.io:4443 hello -d world
...

$ python3.7 examples/nats-sub -s tls://demo.nats.io:4443 hello 
Connected to NATS at demo.nats.io:4443...
Received a message on 'hello ': world

If using Python 3.7 in OS X and getting SSL errors, run first the following to install the certifi default certs:

/Applications/Python\ 3.7/Install\ Certificates.command

Don't miss a new nats.py release

NewReleases is sending notifications on new releases.