GithubHelp home page GithubHelp logo

tomas-abrahamsson / py_interface Goto Github PK

View Code? Open in Web Editor NEW
54.0 54.0 9.0 223 KB

An Erlang to Python integration: a Python program can appear as an Erlang node

License: Other

Emacs Lisp 0.28% Shell 2.82% Python 82.05% Erlang 12.28% Makefile 2.56%

py_interface's People

Contributors

dimadio avatar tbble avatar tomas-abrahamsson avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

py_interface's Issues

pip install py_interface crash

Steps to reproduce:

pip3 install py_interface

Crash trying to run example:

--- py_interface/test ‹master› » ./pingpong_slave.py -d -n [email protected] -c x
Traceback (most recent call last):
  File "./pingpong_slave.py", line 23, in <module>
    from py_interface import erl_term
  File "/usr/local/lib/python3.6/site-packages/py_interface/__init__.py", line 16, in <module>
    __import__('py_interface',globals(),locals(),__all__,-1)
ValueError: level must be >= 0
--- py_interface/test ‹master› »

quick fixed it, by changing : /usr/local/lib/python3.6/site-packages/py_interface/init.py

--- __import__('py_interface',globals(),locals(),__all__,-1)
+++ __import__('py_interface',globals(),locals(),__all__)

Is this a known issue?

Trying to serialize a term may have found a bug

Hi,
I'm trying to generate the equivalent of the following Erlang data structure, convert to bytes and feed into the sha1 function.

erlang:term_to_binary({{<<"fodddo">>,<<"foo">>},<<"bar">>} ).

While attempting to construct it in Python I got to this point and could get no further.

In [45]: erl_term.ErlTuple( ( erl_term.ErlBinary("foo"  ) ))
---------------------------------------------------------------------------
TypeError                                 Traceback (most recent call last)
<ipython-input-45-58ffc74dc16e> in <module>()
----> 1 erl_term.ErlTuple( ( erl_term.ErlBinary("foo"  ) ))

/usr/local/lib/python2.7/site-packages/py_interface/erl_term.pyc in ErlTuple(elementsAsList)
    157 def ErlTuple(elementsAsList):
    158     """An Erlang tuple. This maps to a python tuple."""
--> 159     return tuple(elementsAsList)
    160
    161 def ErlList(elements):

TypeError: iteration over non-sequence

Is this coding error, or a bug ?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.