Welcome, guest | Sign In | My Account | Store | Cart

Notice! PyPM is being replaced with the ActiveState Platform, which enhances PyPM’s build and deploy capabilities. Create your free Platform account to download ActivePython or customize Python with the packages you require and get automatic updates.

Download
ActivePython
INSTALL>
pypm install pycom

How to install pycom

  1. Download and install ActivePython
  2. Open Command Prompt
  3. Type pypm install pycom
 Python 2.7Python 3.2Python 3.3
Windows (32-bit)
0.6.0 Available View build log
0.4.2 Available View build log
0.4.0 Available View build log
0.3.2 Failed View build log
0.3.1 Failed View build log
0.3.0 Failed View build log
0.2 Available View build log
0.1.1 Failed View build log
0.1 Failed View build log
0.6.0 Available View build log
0.4.2 Available View build log
0.4.0 Available View build log
0.3.2 Available View build log
0.3.1 Available View build log
0.3.0 Available View build log
0.2 Available View build log
0.1.1 Failed View build log
0.1 Failed View build log
Windows (64-bit)
0.6.0 Available View build log
0.4.2 Available View build log
0.4.0 Available View build log
0.3.2 Failed View build log
0.3.1 Failed View build log
0.3.0 Failed View build log
0.2 Available View build log
0.1.1 Failed View build log
0.1 Failed View build log
0.6.0 Available View build log
0.4.2 Available View build log
0.4.0 Available View build log
0.3.2 Available View build log
0.3.1 Available View build log
0.3.0 Available View build log
0.2 Available View build log
0.1.1 Failed View build log
0.1 Failed View build log
Mac OS X (10.5+)
0.6.0 Available View build log
0.4.2 Available View build log
0.4.0 Available View build log
0.3.2 Failed View build log
0.3.1 Failed View build log
0.3.0 Failed View build log
0.2 Available View build log
0.1.1 Failed View build log
0.1 Failed View build log
0.6.0 Available View build log
0.4.2 Available View build log
0.4.1 Failed View build log
0.4.0 Available View build log
0.3.2 Available View build log
0.3.1 Available View build log
0.3.0 Available View build log
0.2 Available View build log
0.1.1 Failed View build log
0.1 Failed View build log
Linux (32-bit)
0.6.0 Available View build log
0.4.2 Available View build log
0.4.1 Available View build log
0.4.0 Available View build log
0.3.2 Failed View build log
0.3.1 Failed View build log
0.3.0 Failed View build log
0.2 Available View build log
0.1.1 Failed View build log
0.1 Failed View build log
0.6.0 Available View build log
0.4.2 Available View build log
0.4.1 Failed View build log
0.4.0 Available View build log
0.3.2 Available View build log
0.3.1 Available View build log
0.3.0 Available View build log
0.2 Available View build log
0.1.1 Failed View build log
0.1 Failed View build log
Linux (64-bit)
0.6.0 Available View build log
0.4.2 Available View build log
0.4.1 Available View build log
0.4.0 Available View build log
0.3.2 Failed View build log
0.3.1 Failed View build log
0.3.0 Failed View build log
0.2 Available View build log
0.1.1 Failed View build log
0.1 Failed View build log
0.6.0 Available View build log
0.4.2 Available View build log
0.4.1 Failed View build log
0.4.0 Available View build log
0.3.2 Available View build log
0.3.1 Available View build log
0.3.0 Available View build log
0.2 Available View build log
0.1.1 Failed View build log
0.1 Failed View build log
0.6.0 Available View build log
 
License
BSD
Lastest release
version 0.6.0 on May 23rd, 2012

PyCOM is simple and easy-to-use distributed component model written in Python. PyCOM makes different parts of your network application isolated and independent, while allowing easy and straightforward interaction between them. PyCOM may be seen as an easy and lightweight web services replacement.

Ideology highlights:

  • Non-intrusive design without black magic and lots of auto-generated code
  • Easily adapts to a rapidly changing environment
  • ... and matches pythonic EAFP approach
  • Effective, easy-to-implement and portable protocol
  • Support for binary attachments
  • Support for stateful services via HTTP-alike sessions
  • Low level enough to build your own frameworks
  • ... and still simple enough to be used as is
  • Free software (new BSD license)

Technical highlights:

  • Separate (potentially replaceable) ZeroJSON protocol implementation
  • Easily extensible core library
  • Does not required special "container" software
  • Introspection support for services
  • Load balancing over several services with the same interface
  • Comprehensive test suite and documentation
  • Python 2 and Python 3 support out-of-box

There is ongoing effort to create a C++ client library for PyCOM: https://bitbucket.org/divius/libpycom

Main concepts

With PyCOM you build your application as a number of services, each running in it's own process (or even on it's own computer). You maintain a PyCOM nameserver for finding services by their names (by the way, nameserver itself is a service).

Services provide interfaces, i.e. a named way of interacting with service. They are somewhat similar to interfaces in e.g. Java, but note that PyCOM does not perform any checks on interfaces. Interface usually has some amount of methods.

Services are identified by path with parts separated by slashes, e.g. /com/foo/group/service.

Interfaces are identified by name with parts separated by dots, e.g. com.foo.my-interface.

Examples

Service example (module package1.module1):

import pycom

@pycom.interface("com.foo.example")
class MyService(pycom.Service):

    @pycom.method
    def bar(self, request, name, value=None):
        return {name : value}

Example command line for running this service (provided nameserver is running on 192.168.10.1:2012):

python -m pycom -a tcp://192.168.10.2:2013 -n tcp://192.168.10.1:2012 package1.module1

Example client code for this service:

import pycom

context = pycom.ProxyContext(nameserver="tcp://192.168.10.1:2012")
with context.locate("com.foo.example") as component:
    print component.bar(name="field1", value=42)
    # Prints {"field1" : 42}
    print component.bar("field1", value=42)
    # Prints {"field1" : 42}
    print component.bar("field1")
    # Prints {"field1" : None}
    print component.introspect()
    # Prints a lot of introspection information

Quick start

Our requirements are:

  • POSIX-compatible OS (other may work)
  • Python 2.6, 2.7 or >= 3.1
  • 0MQ Python bindings >= 2.1.11
  • six for Python 3 compatibility (maybe we'll drop it later)

To run test suite you'll also need:

To test (logs will be saved in test.log):

$ python test.py

To build HTML documentation (requires Sphinx):

$ python setup.py build_sphinx
$ <your-browser> build/sphinx/html/index.html

To install from sources:

$ python setup.py install

or via pip:

$ pip install pycom

To start nameserver use script:

$ /usr/local/bin/pycom-nameserver

You may need to adjust nameserver configuration.

Do not forget to read about known issues in the current version: http://packages.python.org/pycom/status.html#known-issues

Support

PyCOM repository and issue tracker are hosted on BitBucket.

Download releases: http://pypi.python.org/pypi/pycom#downloads

Latest source code: https://bitbucket.org/divius/pycom/overview

Report bugs: https://bitbucket.org/divius/pycom/issues

Read documentation: http://www.pycom.org

Enjoy =)

Subscribe to package updates

Last updated May 23rd, 2012

Download Stats

Last month:1

What does the lock icon mean?

Builds marked with a lock icon are only available via PyPM to users with a current ActivePython Business Edition subscription.

Need custom builds or support?

ActivePython Enterprise Edition guarantees priority access to technical support, indemnification, expert consulting and quality-assured language builds.

Plan on re-distributing ActivePython?

Get re-distribution rights and eliminate legal risks with ActivePython OEM Edition.