Bitcoin Forum
May 07, 2024, 12:14:42 AM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: transaction create and signing  (Read 770 times)
Nelzat (OP)
Newbie
*
Offline Offline

Activity: 20
Merit: 0


View Profile
November 18, 2015, 09:29:37 AM
 #1

Hi everyone

I am trying to run the code to create a transaction on Armory using a python script  found in
https://github.com/etotheipi/BitcoinArmory/blob/master/extras/createTxFromAddrList.py, instead of the GUI.

I am getting the following errors,

1.RuntimeError: Cannot start transaction without db env

2.Segmentation fault (core dumped)

3.TypeError: UnspentTxOut_getNumConfirm() takes exactly 2 arguments (1 given)


Has anybody encountered the same problem?

Please aid and thank you very much.

1715040882
Hero Member
*
Offline Offline

Posts: 1715040882

View Profile Personal Message (Offline)

Ignore
1715040882
Reply with quote  #2

1715040882
Report to moderator
1715040882
Hero Member
*
Offline Offline

Posts: 1715040882

View Profile Personal Message (Offline)

Ignore
1715040882
Reply with quote  #2

1715040882
Report to moderator
The trust scores you see are subjective; they will change depending on who you have in your trust list.
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
1715040882
Hero Member
*
Offline Offline

Posts: 1715040882

View Profile Personal Message (Offline)

Ignore
1715040882
Reply with quote  #2

1715040882
Report to moderator
goatpig
Moderator
Legendary
*
Offline Offline

Activity: 3668
Merit: 1345

Armory Developer


View Profile
November 18, 2015, 10:15:39 AM
 #2

1. You have to initialize the DB before you query it

2. That's what will happen if you pass a null DB pointer

3. UnspentTxOut.getNumConfirm(blockNum)

Nelzat (OP)
Newbie
*
Offline Offline

Activity: 20
Merit: 0


View Profile
November 18, 2015, 11:57:36 AM
 #3

Hi goatPig

Thanks

1.You have to initialize the DB before you query it, I am running the Armory GUI too, which means the DB is initialized already, at least that is what i think.
or is there another way to do it?

2. That's what will happen if you pass a null DB pointer

3. The UnspentTxOut.getNumConfirm is in the Coinselection.py and if i add,(blockNum), it is undefined. Its a variable from nowhere
goatpig
Moderator
Legendary
*
Offline Offline

Activity: 3668
Merit: 1345

Armory Developer


View Profile
November 18, 2015, 01:56:23 PM
 #4

Hi goatPig

Thanks

1.You have to initialize the DB before you query it, I am running the Armory GUI too, which means the DB is initialized already, at least that is what i think.
or is there another way to do it?

2. That's what will happen if you pass a null DB pointer

3. The UnspentTxOut.getNumConfirm is in the Coinselection.py and if i add,(blockNum), it is undefined. Its a variable from nowhere

1. These are different processes altogether. The DB exists as a shared library within each process address space. You have to init the DB properly in Python process you are running your script from. Probably something is going wrong at this line:

https://github.com/etotheipi/BitcoinArmory/blob/master/armoryengine/BDM.py#L228https://github.com/etotheipi/BitcoinArmory/blob/master/extras/createTxFromAddrList.py#L38

2. Not sure what you mean by repeating the sentence

3. I meant blockNum as in any block height as integer. You can't figure out the number of confirmations a transaction has without specifying from which block height. By default, you should use TheBDM.getTopBlockHeight():

https://github.com/etotheipi/BitcoinArmory/blob/master/armoryengine/BDM.py#L228

Nelzat (OP)
Newbie
*
Offline Offline

Activity: 20
Merit: 0


View Profile
December 03, 2015, 05:22:52 PM
 #5

Hi goatpig

Thanks a lot, you actually helped me to figure out the problem.
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!