Skip to main content

nameko-pony

Pony dependency for nameko services

Installation

pip install nameko-pony

Usage

app.py

from nameko.rpc import rpc
from pony.orm import Database, Required
from nameko_pony import PonySession

db = Database()


class Person(db.Entity):
    name = Required(str)


class FooService(object):
    name = 'foo_service'

    db_session = PonySession(db)

    @rpc
    @db_session
    def hello(self):
        Person(name='hello')
        Person(name='world')

    @rpc
    def world(self):
        with self.db_session:
            return [p.name for p in Person.select()]

config.yml

AMQP_URI: 'pyamqp://guest:guest@localhost'
DATABASE_URI: 'sqlite:///:memory:'
# DATABASE_URI: 'mysql://usr:pwd@localhost/db_name'

Metadata

Release files for nameko-pony 1.3.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for nameko-pony 1.3.1
File Size Uploaded Provenance Actions
nameko-pony-1.3.1.win32.zip 4.3 kB Without provenance Details for nameko-pony-1.3.1.win32.zip

Built distribution (wheel)

Table of built distributions (wheels) for nameko-pony 1.3.1
File Interpreter ABI Platform Actions
nameko_pony-1.3.1-py2-none-any.whl Python 2 none any Details for nameko_pony-1.3.1-py2-none-any.whl

Total release size: 6.9 kB

Release files / nameko-pony-1.3.1.win32.zip

Download URL nameko-pony-1.3.1.win32.zip
Size 4.3 kB
Tags Source
SHA-256 checksum
How to use checksums
cb78dcde95a3e3792b43da0645da2b440dcb516723f74d480e29dc78a49d256c
BLAKE2b-256 checksum
How to use checksums
443fd30dfd6b406eefe652b78465f79f17c84aa54bb4aaa80cbde6cf42414f24
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release files / nameko_pony-1.3.1-py2-none-any.whl

Download URL nameko_pony-1.3.1-py2-none-any.whl
Size 2.5 kB
Tags Python 2
SHA-256 checksum
How to use checksums
946bfe21ca8c2cab7476d7526fa9579df610e4fbe610956d828e8c280f707646
BLAKE2b-256 checksum
How to use checksums
e2c64f7caa04ffe4283c4865470cce1448a6294bd989c43090c12e38bd224e98
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Security for nameko-pony 1.3.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

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