skip to navigation
skip to content

Not Logged In

scrivener 0.2

Twisted Scribe Client/Server

scrivener: A twisted scribe client/server.

scrivener is a Scribe_ client/server framework for use with Twisted_ applications.

Client API

.. code-block:: python

    from twisted.internet import reactor
    from twisted.internet.endpoints import TCP4ClientEndpoint
    from scrivener import ScribeClient

    def main():
        client = ScribeClient(TCP4ClientEndpoint(reactor, '', 1234))
        client.log('category', 'message1')
        client.log('category', 'message2')

    if __name__ == '__main__':

Server API

.. code-block:: python

    import sys
    from twisted.internet import reactor
    from twisted.internet.endpoints import TCP4ServerEndpoint
    from twisted.python.log import startLogging

    from scrivener import ScribeServerService
    from scrivener.handlers import TwistedLogHandler

    def main():
        service = ScribeServerService(
            TCP4ServerEndpoint(reactor, 1234),

    if __name__ == '__main__':

Server Plugin


    > twistd -n scrivener --help
    Usage: twistd [options] scrivener [scrivener options]
      -p, --port=            Port to listen on for scribe service. [default: tcp:0]
      -H, --handlerFactory=  Fully Qualified Name of a callable that returns an
          --version          Display Twisted version and exit.
          --help             Display this help and exit.

    > twistd -n scrivener -p 1234 -H example.MyLogHandler


    Copyright (C) 2012 Rackspace Hosting, Inc

    Licensed under the Apache License, Version 2.0 (the "License");
    you may not use this file except in compliance with the License.
    You may obtain a copy of the License at

    Unless required by applicable law or agreed to in writing, software
    distributed under the License is distributed on an "AS IS" BASIS,
    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    See the License for the specific language governing permissions and
    limitations under the License.

.. _Scribe:
.. _Twisted:
File Type Py Version Uploaded on Size
scrivener-0.2.tar.gz (md5) Source 2012-09-07 13KB
  • Downloads (All Versions):
  • 5 downloads in the last day
  • 43 downloads in the last week
  • 223 downloads in the last month