Author

Topic: Eloipool AssertionError (Read 1003 times)

newbie
Activity: 9
Merit: 0
July 22, 2013, 10:45:46 AM
#11
is eloipool-litecoin still supported project?
i do some research and found that last git commit, that provides moving from standart bitcoin sha256 to litecoin scrypt brokes many things deep into eloipool.
newbie
Activity: 9
Merit: 0
July 03, 2013, 05:29:16 AM
#10
Problem is in python-bitcoinrpc.
look at authproxy.py, that is in python-bitcoinrpc/bitcoinrpc dir.

You can see smth like that:
Code:

131         return json.loads(http_response.read(),
132                           parse_float=decimal.Decimal)

but
Code:
return json.loads(http_response.read()
goes wrong, so i reccomend you to do some changes like:
Code:
131         return json.loads(http_response.read().decode('utf8'),
132                           parse_float=decimal.Decimal)

after that everything is ok. The reason is that there is no decode of auth string in python-bitcoinrpc.

And,  Sannin, can you tell me, what version of litecoin-eloipool did you use to get it work?
newbie
Activity: 14
Merit: 0
May 16, 2013, 05:55:45 PM
#9
Anyone agree?
newbie
Activity: 14
Merit: 0
May 16, 2013, 05:55:12 PM
#8
Hmm thats a very strange error.
newbie
Activity: 14
Merit: 0
May 16, 2013, 04:53:39 PM
#7
They look the same to me
newbie
Activity: 19
Merit: 0
May 16, 2013, 03:57:23 PM
#6
I found other version and problem disappear. But I have another problem:
Code:
013-05-16 22:48:18,858 merkleMaker CRITICAL Traceback (most recent call last):
  File "/usr/lib/python3.2/json/decoder.py", line 369, in raw_decode
    obj, end = self.scan_once(s, idx)
StopIteration

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/tmp/eloipool-litecoin-scrypt-new/merklemaker.py", line 692, in run
    self.merkleMaker_I()
  File "/tmp/eloipool-litecoin-scrypt-new/merklemaker.py", line 682, in merkleMaker_I
    self.merkleMaker_II()
  File "/tmp/eloipool-litecoin-scrypt-new/merklemaker.py", line 648, in merkleMaker_II
    return self._updateMerkleTree()
  File "/tmp/eloipool-litecoin-scrypt-new/merklemaker.py", line 548, in _updateMerkleTree
    self._updateMerkleTree_I()
  File "/tmp/eloipool-litecoin-scrypt-new/merklemaker.py", line 512, in _updateMerkleTree_I
    r = self._updateMerkleTree_fromTS(TS)
  File "/tmp/eloipool-litecoin-scrypt-new/merklemaker.py", line 477, in _updateMerkleTree_fromTS
    MP = self._CallGBT(TS)
  File "/tmp/eloipool-litecoin-scrypt-new/merklemaker.py", line 327, in _CallGBT
    MP = access.getblocktemplate(self.GBTReq)
  File "/usr/local/lib/python3.2/dist-packages/bitcoinrpc/authproxy.py", line 102, in __call__
    response = self._get_response()
  File "/usr/local/lib/python3.2/dist-packages/bitcoinrpc/authproxy.py", line 128, in _get_response
    parse_float=decimal.Decimal)
  File "/usr/lib/python3.2/json/__init__.py", line 322, in loads
    return cls(**kw).decode(s)
  File "/usr/lib/python3.2/json/decoder.py", line 353, in decode
    obj, end = self.raw_decode(s, idx=_w(s, 0).end())
  File "/usr/lib/python3.2/json/decoder.py", line 371, in raw_decode
    raise ValueError(s)
ValueError: No JSON object could be decoded

s value is:
Code:
"http://www.w3.org/TR/1999/REC-html401-19991224/loose.dtd">


Error


401 Unauthorized.



I think problem is wrong rpc connection settings:

Code:
TemplateSources = (
{
'name': 'primary',
'uri': 'http://rpcuser:rpcpass@localhost:9344',
'priority': 0,
'weight': 1,
},
)
Code:
UpstreamBitcoindNode = ('127.0.0.1', 9344)

Where is the difference?

bitbar.conf
Code:
rpcuser=rpcuser
rpcpassword=rpcpass
rpcallowip=*.*.*.*
rpcport=9344

server=1
daemon=1
gen=0

Sorry for my english.
newbie
Activity: 19
Merit: 0
May 16, 2013, 03:23:16 PM
#5
Ok, thanks for help
member
Activity: 101
Merit: 10
May 16, 2013, 03:16:10 PM
#4
This appears to be a common issue with this fork

Did anyone tried this:

https://github.com/Tydus/eloipool-litecoin

?

Works ?


I tried it, can't get it to work.

I'm currently hung up on the following error:

Traceback (most recent call last):
  File "./eloipool.py", line 80, in
    from bitcoin.txn import Txn
  File "/home/ltc/eloipool-litecoin/bitcoin/txn.py", line 146, in
    _test()
  File "/home/ltc/eloipool-litecoin/bitcoin/txn.py", line 124, in _test
    assert t.txid == b"C\xeczW\x9fUa\xa4*~\x967\xadAVg'5\xa6X\xbe'R\x18\x18\x01\xf7#\xba3\x16\xd2"
AssertionError


I can find in the original source Assertion Error: http://gitorious.org/bitcoin/eloipool/blobs/52dbd36b88482c4c675f8925eaa01c57c2a22b09/stratumserver.py#line161 in the stratumserver.py and it appears it is having an issue with the txid "keys" for litecoin. I guess try to contact the creator of litecoin fork at https://github.com/Tydus

Not sure of a quick fix at the moment
newbie
Activity: 19
Merit: 0
May 16, 2013, 02:33:36 PM
#3
Thanks for reply but error is before server running. My conf:

Code:
# Name of the server
ServerName = 'eloipool'

### Settings relating to server scaling/load

# Share hashes must be below this to be valid shares
# If dynamic targetting is enabled, this is a minimum
ShareTarget = 0x00000000ffffffffffffffffffffffffffffffffffffffffffffffffffffffff

# Automatically adjust targets per username
# 0 = disabled
# 1 = arbitrary targets
# 2 = power of two difficulties (zero bit counts)
DynamicTargetting = 0

# How many shares per minute to try to achieve on average
DynamicTargetGoal = 8

# Number of seconds hashrate is measured over
DynamicTargetWindow = 120

# Minimum and maximum of merkle roots to keep queued
WorkQueueSizeRegular = (0x100, 0x1000)

# Minimum and maximum of BLANK merkle roots to keep queued
# (used if we run out of populated ones)
WorkQueueSizeClear = (0x1000, 0x2000)

# Minimum and maximum of BLANK merkle roots to keep queued, one height up
# (used for longpolls)
WorkQueueSizeLongpoll = (0x1000, 0x2000)

# How long to wait between getmemorypool updates normally
MinimumTxnUpdateWait = 5

# How long to wait between retries if getmemorypool fails
TxnUpdateRetryWait = 1

# How long to sleep in idle loops (temporary!)
IdleSleepTime = 0.1

### Settings relating to reward generation

# Address to generate rewards to
TrackerAddr = 'B8qdqFcUAeSstHT9AWVyBv1KU4ysuaxHts'  # testnet

# Coinbaser command to control reward delegation
# NOTE: This example donates 1% of block rewards to Luke-Jr for Eloipool development
CoinbaserCmd = 'echo -e "1\\n$((%d / 100))\\n1579aXhdwvKZEMrAKoCZhzGuqMa8EonuXU"'

### Settings relating to upstream data providers

# JSON-RPC servers to get block templates from
# See https://en.bitcoin.it/wiki/BIP_0023#Logical_Services for key details
TemplateSources = (
{
'name': 'primary',
'uri': 'http://rpcuser:pass@localhost:9344',
'priority': 0,
'weight': 1,
},
)

# Templates will not be used unless they have an acceptance ratio above this
# Range: 0.00 - 1.00
MinimumTemplateAcceptanceRatio = 0

# No template with a combined total score below this will be used
MinimumTemplateScore = 1

# Set to True if you want shares meeting the upstream target to wait for a
# response from an upstream server before logging them. Otherwise, for such
# shares, upstreamResult will always be True and upstreamRejectReason will
# always be None. Note that enabling this may cause shares to be logged out of
# order, or with the wrong timestamp (if your share logger uses the log-time
# rather than share-time).
DelayLogForUpstream = True

# Bitcoin p2p server for announcing blocks found
#UpstreamBitcoindNode = ('127.0.0.1', 18333)  # testnet
UpstreamBitcoindNode = ('127.0.0.1', 9344)

# Network ID for the primary blockchain
# Other known network IDs can be found at:
#     https://en.bitcoin.it/wiki/Protocol_specification#Message_structure
UpstreamNetworkId = b'\xF9\xBE\xB4\xD9'  # testnet

# Secret username allowed to use setworkaux
#SecretUser = ""

# URI to send gotwork with info for every share submission
#GotWorkURI = ''

# Share hashes must be below this to be submitted to gotwork
GotWorkTarget = 0x00000000ffffffffffffffffffffffffffffffffffffffffffffffffffffffff

# Aim to produce blocks with transaction counts that are a power of two
# This helps avoid any chance of someone abusing CVE-2012-2459 with them
# 1 = cut out feeless transactions; 2 = cut out even fee-included transactions (if possible)
#POT = 2

# Avoid mining feeless transactions except to satisfy POT
# Note this only works if POT is in fact enabled in the first place
Greedy = False

### Settings relating to network services
# Note that Eloipool only supports IPv6 sockets, and if you want to bind to an
# IPv4 address you will need to prepend it with ::ffff: eg ::ffff:192.168.1.2

# Addresses to listen on for JSON-RPC GBT/getwork server
JSONRPCAddresses = (
('', 8337),
)

# Addresses to listen on for Stratum mining server
StratumAddresses = (
('', 3334),
)

# Addresses to listen on for Bitcoin node
# Note this will only be used to distribute blocks the pool finds, nothing else
BitcoinNodeAddresses = (
('', 8338),
)

# Addresses that are allowed to "spoof" from address with the X-Forwarded-For header
TrustedForwarders = ('::ffff:127.0.0.1',)


# Logging of shares:
ShareLogging = (
{
'type': 'logfile',
'filename': 'share-logfile',
'format': "{time} {Q(remoteHost)} {username} {YN(not(rejectReason))} {dash(YN(upstreamResult))} {dash(rejectReason)} {solution}\n",
},
)

### Settings related to poolserver logging

# By default, significant events will be printed to the interactive console
# You can customize your logging using either simple parameters, or Python's advanced logging framework
# Note that using Python's logging framework will override the default console logging!

# To simply log everything to the system log (syslog) as well:
# LogToSysLog = True

# To make a log file:
# LogFile = 'filename.log'

# For a rotating log file:
LogFile = {
'filename': 'filename.log',
'when': 'midnight',
'backupCount': 7,
}
# For details, see:
# http://docs.python.org/3/library/logging.handlers.html#logging.handlers.TimedRotatingFileHandler
member
Activity: 101
Merit: 10
May 16, 2013, 02:22:50 PM
#2
Make sure stratum is running correctly, and is available on the port you specified in the config.py
newbie
Activity: 19
Merit: 0
May 16, 2013, 02:11:53 PM
#1
Hi, I have problem with eloipool, my error:
Code:
Traceback (most recent call last):
  File "./eloipool.py", line 80, in
    from bitcoin.txn import Txn
  File "/tmp/eloipool-litecoin-scrypt/bitcoin/txn.py", line 146, in
    _test()
  File "/tmp/eloipool-litecoin-scrypt/bitcoin/txn.py", line 124, in _test
    assert t.txid == b"C\xeczW\x9fUa\xa4*~\x967\xadAVg'5\xa6X\xbe'R\x18\x18\x01\xf7#\xba3\x16\xd2"
AssertionError
Jump to: