Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Nov 26 2017 18:36
    @jpitts banned @Musk001
  • Nov 17 2017 21:10
    @jpitts banned @Musk55
  • Nov 17 2017 21:10
    @jpitts banned @Muskyyyy
cseberino
@cseberino
@chfast I was interested in that project myself..learning difference between raw contract code and deployment code in binaries....so serpent compile doesn't give you what you want?
urugang
@urugang
hi, i have a problem at test environment setup . when i run py.test, it reported as below.

(pyethapp) urugang@urugang-P65xHP:~/codes/pyethapp/serpent$ py.test
=============================================================================================== test session starts ===============================================================================================
platform linux2 -- Python 2.7.13, pytest-3.1.2, py-1.4.34, pluggy-0.4.0
rootdir: /home/urugang/codes/pyethapp/serpent, inifile:
plugins: timeout-1.0.0, catchlog-1.2.2
collected 0 items / 3 errors

===================================================================================================== ERRORS ======================================================================================================
__ ERROR collecting examples/cyberdyne/test/test_heap.py __
examples/cyberdyne/test/test_heap.py:1: in <module>
from ethereum import tester, utils
../local/lib/python2.7/site-packages/ethereum-1.4.0-py2.7.egg/ethereum/tester.py:47: in <module>
import serpent
../bin/serpent.py:4: in <module>
import('pkg_resources').run_script('ethereum-serpent==2.0.2', 'serpent.py')
../local/lib/python2.7/site-packages/pkg_resources/init.py:739: in run_script
self.require(requires)[0].run_script(script_name, ns)
../local/lib/python2.7/site-packages/pkg_resources/init.py:1495: in run_script
raise ResolutionError("No script named %r" % script_name)
E ResolutionError: No script named 'serpent.py'

urugang
@urugang
does anyone have some sugguestion?
urugang
@urugang
i have figured out the problem. there are two serpent executable, one is in /usr/local/bin, another is in ~/.local/bin/serpent. after remove latter, test can be run.
mathcrypto
@mathcrypto
Hello everyone, i am a beginner in serpent and i have tried a simple example of a contract and got different byte code from the one in tutorial and different opcodes
this is the one i should have got
604380600b600039604e567c01000000000000000000000000000000000000000000000000000000006000350463eee9720681141560415760043560405260026040510260605260206060f35b505b6000f3
yet i got this one,
6100448061000e600039610052567c010000000000000000000000000000000000000000000000000000000060003504636ffa1caa8114156100425760043560405260026040510260605260206060f35b505b6000f3
i should have got this opcode
[PUSH1, 67, DUP1, PUSH1, 11, PUSH1, 0, CODECOPY, PUSH1, 78, JUMP, PUSH29, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, PUSH1, 0, CALLDATALOAD, DIV, PUSH4, 238, 233, 114, 6, DUP2, EQ, ISZERO, PUSH1, 65, JUMPI, PUSH1, 4, CALLDATALOAD, PUSH1, 64, MSTORE, PUSH1, 2, PUSH1, 64, MLOAD, MUL, PUSH1, 96, MSTORE, PUSH1, 32, PUSH1, 96, RETURN, JUMPDEST, POP, JUMPDEST, PUSH1, 0, RETURN]
i got this one instead
[PUSH2, 0, 68, DUP1, PUSH2, 0, 14, PUSH1, 0, CODECOPY, PUSH2, 0, 82, JUMP, PUSH29, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, PUSH1, 0, CALLDATALOAD, DIV, PUSH4, 111, 250, 28, 170, DUP2, EQ, ISZERO, PUSH2, 0, 66, JUMPI, PUSH1, 4, CALLDATALOAD, PUSH1, 64, MSTORE, PUSH1, 2, PUSH1, 64, MLOAD, MUL, PUSH1, 96, MSTORE, PUSH1, 32, PUSH1, 96, RETURN, JUMPDEST, POP, JUMPDEST, PUSH1, 0, RETURN]
is it normal?
mathcrypto
@mathcrypto
Place 2-byte item on stack instead of 1
Seres István András
@Istvan_A_Seres_twitter
Hey guys! Are there fallback functions in Serpent contracts? Or more specifically what happens if a contract written in Serpent sends Ether to a contract which is written in Solidity? Does the fallback function of the Solidity one is executed? Thanks in advance
mathcrypto
@mathcrypto
Humm @Istvan_A_Seres_twitter try to test this, send ether from one serpent contract to solidity one
Use testnet ropsten or testrpc.
Martin Maurer
@empea-careercriminal
Are there any people here who moved from Serpent to Solidity for a particular reason? From what I can see thus far (being a noob) Serpent is well equipped to do most of the things that Solidity con do, but a whole lot of additional functionalities when it comes to low level operations. Please don´t hesitate to be harsh on me if my observations are wrong.
Martin Maurer
@empea-careercriminal
running the setup or running installation with pip on windows produces this error:
File "setup.py", line 8, in <module>
flag for flag in opt.split() if flag != '-Wstrict-prototypes'
AttributeError: 'NoneType' object has no attribute 'split'
Could anyone confirm a successful installation of Serpent on Windows?
mathcrypto
@mathcrypto
@empea-careercriminal i have installed serpent on both linux and mac os machines and it works. However, i have not tested it on a windows machine
Martin Maurer
@empea-careercriminal
@mathcrypto thanks ... I´m switching to a linux machine ... windows is not looking to good as of now ...
mathcrypto
@mathcrypto
you can use it from a virtual machine
thats what i am doing, i have a windows machine and using linux in virtual box
Martin Maurer
@empea-careercriminal
yeah .. that´s what i was trying to do next :)
mathcrypto
@mathcrypto
:)
Santiago Palladino
@spalladino
Hey folks! I'm trying to follow the example in https://github.com/ethereum/wiki/wiki/Serpent#including-files-and-calling-other-contracts to create a contract and invoke a function on it. I'm using the tester module in pyethereum, and when I try to invoke the returnten function from the console, I get a ethereum.tools.tester.TransactionFailed. Any ideas, or some way to get more info on what could have caused the transaction to fail?
Note that the contract does not fail if I just call create, and it actually returns an addess-like
postables
@postables
hey guys with serpent
where do i declare factors such as token name etc..
would i ininitialize the variable outside init() using "data token_name" etc..
and than within init() set the value of self.token_name to the name of the token?
postables
@postables
any help with this would be greatly appreciated
postables
@postables
So I "fixed" that issue i think
but now im getting this error: Input 0 has arity 0
sorry heres the full stacktrace
Cifer
@cifer-lee
hello
so cold a place compare to solidity :laugh :cry
Cifer
@cifer-lee
python is such a popular language, except for ethereum 🤣
it’s so sad… i wrote python
Ahmad Sofyan
@asofyan
I really want to build smart contract in serpent.. but the documentation is so few..
At least, web3.py exist.. I can connect my django app
Cifer
@cifer-lee
yeah, all freshes goes to solidity
Martin Maurer
@empea-careercriminal
Maybe interesting for people coming here, too: https://github.com/ethereum/viper
Musk440
@musk440_twitter
This message was deleted