Permalink
Browse files

Merge branch 'master' of github.com:kmatzen/crosstalk

  • Loading branch information...
2 parents edd22b8 + 34aa3ce commit fb5b52a9f731f01c694fa6ab73f9ba62949e7775 @kmatzen committed Aug 31, 2012
Showing with 12 additions and 1 deletion.
  1. +12 −1 README.md
View
@@ -1,8 +1,19 @@
crosstalk
=========
-To install, you must install the module in both your python 2 and python 3 interpreter search paths. Only tested on CPython. Probably will not work on others due to the use of inspect to figure out the module's search path.
+Purpose
+-------
+Annotate a python 3 module such that it will be called directly from the python 3 interpreter or will be called via IPC from the python 2 interpreter.
+Installation
+------------
+ python2 setup.py install
+ python3 setup.py install
+
+To install, you must install the module in both your python 2 and python 3 interpreter search paths. Only tested on CPython. Probably will not work on others due to the use of inspect to figure out the module's path.
+
+Example
+-------
See add.py for an example module that has been annotated for crosstalk. In particular, note how to construct the object with your python 3 interpreter path, how to annotate a function with the expose declaration, and how to register custom handlers for data types that don't work well with repr and eval. Note, python's pickle module is not used here. Despite identical protocol versions, unicode makes it difficult for pickle to successfully work here.
test.py can be executed in either your python 2 or python 3 interpreter. If executed in python 3, it will call add in the same interpreter. If called in your python 2 interpreter, it will spawn a python 3 interpreter and send the values back and forth.

0 comments on commit fb5b52a

Please sign in to comment.