Git Product home page Git Product logo

Comments (4)

vindimy avatar vindimy commented on July 22, 2024

One of the issues I see is that the 'unit' field was designed to be 3-letter-long and in your case it's 5 letters (unit: ldoge). The SQL table definition is such that anything longer than 3 letters will be cut short (so you see Warning: Data truncated for column 'coin' at row 1 cursor.execute(statement, parameters)). As a result, maybe the code ends up sending an invalid request to coin daemon and receives a bad response.

from altcointip.

josephdyland avatar josephdyland commented on July 22, 2024

Thank you for the quick response! I created a new table and imported the altcointip.sql source. changed the symbol and unit to LDG and Modified /src/conf/db.yml to point to the new table. Then ran python _addcoin LDG. I think I just get the same error with out the data truncated warning.

DEBUG:cointipbot:> CtbUser::__init__(thedoctor___)
DEBUG:cointipbot:< CtbUser::__init__(thedoctor___) DONE
DEBUG:cointipbot:> CtbUser::is_registered(thedoctor___)
DEBUG:cointipbot:< CtbUser::is_registered(thedoctor___) DONE (no)
DEBUG:cointipbot:> CtbUser::register(thedoctor___)
DEBUG:bitcoin:Starting "walletpassphrase" JSON-RPC request
DEBUG:bitcoin:Got 36 byte response from server in 131 ms
DEBUG:bitcoin:Starting "getnewaddress" JSON-RPC request
DEBUG:bitcoin:Got 68 byte response from server in 2 ms
DEBUG:bitcoin:Starting "walletlock" JSON-RPC request
DEBUG:bitcoin:Got 36 byte response from server in 1 ms
INFO:cointipbot:CtbUser::register(thedoctor___): got LDG address dGnSwTCyBa4YKvWuvzmEKg5TWb1m24PfGG
DEBUG:cointipbot:< CtbUser::register(thedoctor___) DONE
DEBUG:cointipbot:> CtbUser::balance(thedoctor___)
INFO:cointipbot:CtbUser::balance(thedoctor___): getting LDG givetip balance
DEBUG:cointipbot:CtbCoin::getbalance(thedoctor___, 10)
DEBUG:bitcoin:Starting "getbalance" JSON-RPC request
ERROR:bitcoin:500 (Internal Server Error) response from bitcoind
ERROR:cointipbot:CtbCoin.getbalance(): error getting Litedoge (minconf=10) balance for thedoctor___: 500 (Internal Server Error) response from bitcoind
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "cointipbot.py", line 533, in __init__
    self.self_checks()
  File "cointipbot.py", line 142, in self_checks
    ctb_balance = b.get_balance(coin=c, kind='givetip')
  File "ctb/ctb_user.py", line 91, in get_balance
    balance = self.ctb.coins[coin].getbalance(_user=self.name, _minconf=self.ctb.conf.coins[coin].minconf[kind])
  File "ctb/ctb_coin.py", line 70, in getbalance
    balance = self.conn.getbalance(user, minconf)
  File "ctb/pifkoin/bitcoind.py", line 69, in __call__
    return server._rpc_call(self.method, *args)
  File "ctb/pifkoin/bitcoind.py", line 216, in _rpc_call
    raise BitcoindException('%d (%s) response from bitcoind' % (response.status, response.reason))
ctb.pifkoin.bitcoind.BitcoindException: 500 (Internal Server Error) response from bitcoind

from altcointip.

josephdyland avatar josephdyland commented on July 22, 2024

I resolved this issue, by turning enableaccounts=1 in the wallets .conf.

I now have the bot connected to reddit and monitoring the subreddit. Users can register and get a address, They can also send coins to address and +info returns the proper amount.

My issue now is Tipping, I have tried dozens of differnt combinations and I keep getting a reddit message back asking to verify Syntax.

This is from the logs when it processes the tip.

INFO:cointipbot:CointipBot::check_inbox(): no match
DEBUG:cointipbot:> CtbUser::__init__(thedoctor___)
DEBUG:cointipbot:< CtbUser::__init__(thedoctor___) DONE
DEBUG:cointipbot:CointipBot::check_inbox(): Sorry thedoctor\_\_\_, I didn't understand your comment. Please verify syntax and try again.


*****
DEBUG:cointipbot:> eval_comment()
DEBUG:cointipbot:eval_comment(): match found
DEBUG:cointipbot:> reddit_get_parent_author()
DEBUG:cointipbot:< reddit_get_parent_author(ct0ai57) -> josephdyland
DEBUG:cointipbot:eval_comment(): creating action givetip: to_user=josephdyland, to_addr=None, amount=None, coin=None, fiat=None
DEBUG:cointipbot:> CtbAction::__init__({'fiat_val': None, 'fiat': None, 'msg_id': None, 'subr': Subreddit(subreddit_name='litedoge'), 'keyword': u'all', 'atype': 'givetip', 'self': <ctb.ctb_action.CtbAction object at 0x7fd6ff229610>, 'from_user': None, 'to_addr': None, 'to_user': u'josephdyland', 'ctb': <cointipbot.CointipBot object at 0x7fd700fc9ad0>, 'coin_val': None, 'msg': <praw.objects.Comment object at 0x7fd6ff695790>, 'coin': None})
DEBUG:cointipbot:> CtbUser::__init__(josephdyland)
DEBUG:cointipbot:< CtbUser::__init__(josephdyland) DONE
DEBUG:cointipbot:> CtbUser::__init__(thedoctor___)
DEBUG:cointipbot:< CtbUser::__init__(thedoctor___) DONE
DEBUG:cointipbot:CtbAction::__init__(): <CtbAction: type=givetip, msg.body=+/u/ldogetipbot all, from_user=<CtbUser: name=thedoctor___, giftamnt=None, joindate=None, addr={}, redditobj=thedoctor___, banned=False>, to_user=<CtbUser: name=josephdyland, giftamnt=None, joindate=None, addr={}, redditobj=None, banned=False>, to_addr=None, coin=None, fiat=None, coin_val=None, fiat_val=None, subreddit=litedoge>
WARNING:cointipbot:eval_comment(): CtbAction::__init__(type=%s): keyword is coin-only, but only fiat is set

from altcointip.

justinvforvendetta avatar justinvforvendetta commented on July 22, 2024

this is interesting. when i played with it a bit, i was able to get tipping to work, and lost withdraw function.

from altcointip.

Related Issues (20)

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.