Bible Pay

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Rob Andrews

Pages: 1 ... 181 182 183 184 185 186 187 [188] 189 190 191
2806
Alright so I just deployed a couple new governance features to the pool.

Now you can go to proposals, and when you click View Proposal, it opens the Discussion in a new Tab on the browser.  The idea is we create proposals with Forum URLs, let everyone discuss it, and the URL for the discussion stays on the proposal forever.

I updated the Orphan proposal that still needs voted on today with the new Forum URL, so lets pretend its real and vote on it now.

I added some more features to make voting more intuitive.  The proposal has to go through the initial voting stage (that is it either gets voted for funding or gets voted away and dies).  During this phase internally it has a gobject id.  To make this easier, when you right click on a proposal that is not fully voted to a budget, you can now either copy the proposal ID to the clipboard or copy the Vote command to the clipboard.  It appears only IE lets me write to your clipboard, so if you are on Chrome, you will have to copy the command from the dialog into your clipboard.  I think this will work on firefox, let me know.

So another words to vote on the orphan proposal, right click on it and copy the proposal vote command to the clipboard then vote on it from your masternode. Let me know that it works.

Then once the system finds a supermajority voted on it, it will create a budget item for it. You will also have to vote on the budget once per month.
When you right click the proposal and click Vote on Budget, it will copy the Budget Tx ID and voting command to the clipboard.  Later today we can use that to vote on the budget.

We still need someone to create another real proposal (a good one) and some one to create a tacky one.

Got to head to church have fun.



2807
@togoshigekata: I'm having the same problem with watchman. Dit you solve this issue?

rpcallowip=127.0.0.1 is set in the biblepay.conf file, and this is my watchman.conf:

Code: [Select]
# specify path to biblepay.conf or leave blank
# default is the same as BiblepayCore
#biblepay_conf=/home/rob/.biblepaycore/biblepay.conf

# valid options are mainnet, testnet (default=mainnet)
#network=mainnet
network=testnet

# database connection details
db_name=database/watchman.db
db_driver=sqlite

venv/bin/python bin/watchman.py

I do work from the GUI. Might this be the problem?

Sorry, I dont understand what is broken, but, if you ran the
venv/bin/python bin/watchman.py and did not receive an error I believe you are actually OK with watchman.   
What you can do is vote on our new proposal that is coming out in one hour and then go into this

sqlite3 Watchman
select * from vote;

And just see if your vote went in from your masternode then you will know for sure your watchman is working.

Also if you receive WatchdogExpired from the GUI list of Sanctuaries in a few hours, watchman is down.


2808
I've had a busy week, but I think I've finally got a masternode working  :D

I didn't set it up on a vultr server, but run it within my own network. So now I have two computers running from my home, one having the controller wallet and the other having the sanctuary wallet.

I do still have a few questions/remarks.
In the guide it says:

 What I got was:

Code: [Select]
{
  "d7701a68ef4a7af4f066499477b935bfccf5efaacf28149cdf8b5316c1daa626": "1",
  "fd5cb3ef632fb25a40665d1b4da0c1cd992c4f3d99ef38ce1ddf725ecfe53836": "0"
}

Then later on the guide says:

But I didn't know where to find the 'SANCTUARY_TXID' and 'SANCTUARY_VOUT'. Am I right in saying that these two are the last two I got when typing 'masternode outputs' on my controller wallet (thus in my case 'SANCTUARY_TXID'='fd5cb3ef632fb25a40665d1b4da0c1cd992c4f3d99ef38ce1ddf725ecfe53836' and 'SANCTUARY_VOUT'='0'?
That's the way I configured it a least, and it seems to be working.

When I type 'masternode status' on my sanctuary wallet, I get:

Code: [Select]
{
  "vin": "CTxIn(COutPoint(fd5cb3ef632fb25a40665d1b4da0c1cd992c4f3d99ef38ce1ddf725ecfe53836, 0), scriptSig=)",
  "service": "84.29.208.33:40001",
  "payee": "yahMsXVAioaFT9EXfna78sqoYZh5y4NMfP",
  "status": "Masternode successfully started"
}

While typing this, I got my first masternode-payment, so I guess it's working  8)
Next step is getting wachtman up and running.

One last question: do I also need to keep the controller wallet online? I don't think so, based on the information I've read, but I'm wondering how it works...

That is great dude, glad to hear it.

Yeah, in masternode outputs, it prints the TXID of the collateral, colon then the vout (locationid) of the collateral.  So Ill modify the FAQ to make it clearer that what value is which one.

Once your masternode is started you dont have to keep the controller wallet online.  When in prod, we will have to ocasionally look at the masternode list and if it says "Restart Required"thats when you have to bring the controller back up and do a restart on the cold sanctuary.  Ill take a look at the code to ensure this is not going to be a nuisance where its down if it misses one ping.  Maybe we relax it a little so its easier to manage these for the first year (IE requires a hard down for one hour instead of 5 minutes) as I noticed out of my 3 sanctuaries I left them running and one of them already requires restart.

Ill add this to the faq also.

Btw guys I added the watchman to the create_masternode wiki.

2809
On a side note, on my guinea pig test last night where I took a funded-paid gobject, and tried to revote it into a new superblock, it was rejected.  So thats great to know, because that means one cannot pull a fast one on the community and try to slip their proposal into two budgets and have the sanctuaries accidentally pay it twice (especially thinking they didnt vote it in properly in the last budget-superblock).

However there is one circumstance I can think of that will happen in prod that we have to make a distinction on.  If a proposal is submitted, and everyone likes it and approves it, but everyone goes away after proposal is approved, and forgets to vote on the budget, then it fails to to be created in the next superblock, then it is not funded, then we will auto-create a new budget, and that allows us to continue to vote for it in the *next* superblock.  In prod that would be rare, as we only have one per month, so dont worry too much about this.  It should happen in testnet however quite a bit with these hourly superblocks.


2810
No problem, family first.  I gotta do some other things. But I did vote and the proposal did show when I left clicked it.
Wait, I think its fixed.  Gotta step out, but go ahead and left click from the weblist from the one that is not funded and you should see a Wiki page pop up.

When you create your forum link and a new proposal, once you navigate to the list, it should also pop up- we will probably need to make that open in a new window, otherwise forum javascript will probably be broken (IE it may need a whole dedicated discussion page).


2811
Is there a way to see more detail on what the proposal is?  Because (and yes, I understand we're testing), right now, I see a proposal entitled "Oct 2017 recurring orphan expense due" and a id, but there is no way to really tell what we're voting on.  Or is that coming and I'm jumping the gun?

Well on a side note, I am working on an advanced feature now that will let you pull up commands to let you vote on a budget or a proposal, but Im kind of getting ahead of myself here, the current version in Pool-testnet right now please check this out:

If you single left click on the First row of each Proposal, you can view the Forum detail.  To vote on it, copy the Second rows gobject ID to clipboard and vote.  Let me know if you vote, because Ive done something very convoluted to the first proposal.  I voted on it, voted on the budget, became the supermajority (because I had 3 cool sanctuaries running) got it in the superblock and paid and then pulled it back out and re-instantiated it - I am trying to see what happens if us guys vote on something again that was already paid.

Anyway, since you are mod, if you want to create that other one we need, you should then be able to left click it and see your forum URL discussion also.

You should see an entire web page for the recurring orphan expense with the invoice in it.

2812
Alright everyone, I believe we are now at the point where we need to perform end-to-end sanctuary testing!

Lets try to go through this process from start-finish to see what needs improvements  :'(

So first, log in to pool.biblepay.org and click Network: Testnet.  If you are not in testnet mode, the proposals lists will be empty.

Next click Governance | Proposal List.  You will see the list of Active proposals at the top (those not funded yet that need voted on) and then in the Funded List you will see those proposals that are already inside superblocks and paid.
NOTE: I will be adding a chart soon so we can see a graphical view of the proximity to funding per row one proposal is generating in popularity.

We need to simulate: Keeping compassion as a charity, Paying a single invoice, Paying multiple invoices in a superblock, Shooting down a proposal, and watching a proposal get paid (included in a superblock), verifying the budget, test inability to exceed the budget, and review a historical expense.

First lets test a dry run of the theoretical monthly recurring expense for compassion.  I added a new proposal and it is ready to be voted on, for Octobers recurring orphan sponsorships (39,900 BBP).  Click on Proposal List.  Note the gobjectID in the second row of each item row (that is the Detail row).  Copy the gobjectID to the clipboard (note - Clicking on the first line of each row allows you to View the proposal), so you need to double click the gobject id (62a9c8afaf2af86f3820d6d30a93b4f84b29927b66c88badf8ad9699a48e20a6) from the second row, (the row that says the Proposal Name hyphen the gobjectid).  To vote on this for funding from your sanctuary issue this command:

Code: [Select]
gobject vote-many 62a9c8afaf2af86f3820d6d30a93b4f84b29927b66c88badf8ad9699a48e20a6 funding yes


The pool will actually update the row eventually with voting information also.

After the supermajority votes on it, the pool will create a budget item automatically that "fits" as many proposals as possible into a superblock (IE it will try to create a superblock for us), the pool has no power to vote, all it can do is suggest to the sanctuary network that "4 approved proposals can fit in superblock Y" and Y must be an upcoming superblock with at least enough lead time to be voted on (this is called the budget maturity period).  We need to test that also.

So please go ahead and vote on this proposal, and we will watch to see if it moves through the phases.

Also, I wanted to mention, for the very first Discussion URL, I used the wiki page just to get started.  But, technically, we need to use a Forum topic for this purpose so that other Biblepayers and Sanctuaries can discuss the validity in an open forum of the actual item.  For example, if someone submits a proposal to place a BiblePay ATM with a "medicianal weed" dispenser in it, the community should stand up and say: Wait I thought we were a Christian community isnt this going to tarnish our image, and coax the sanctuaries to vote it down.

Initiative II:

Id also like to ask someone here, who has a running sanctuary, to go ahead and create a Mock up proposal with a real testnet discussion URL, one that we can vote on, so we can test the "multiple proposals in one budget and in one superblock" issue.  Who is up for it?  Click on Proposals| Add.
Create a discussion URL on Forum.biblepay.org in the Testnet Forum, as a new Topic.  Ensure you can post to it (test it).  Use that as the discussion URL.
Enter an amount below 10000 BBP as the "amount" because the superblock budget is only 72000 on testnet and the orphan budget is already at 39,900.
Add the Proposal and verify it exists and notify us so that we can discuss and vote on it. 

And finally, please, someone who wants to make a really negative and tacky proposal, go ahead and make one, and let us know, one that we deliberately want to shoot down so that it misses the budget.



2813
Good news, I think I got a master node working!
(One gotchya was that with AWS (Amazon Web Services) I needed to add inbound rule for port 40001 in the security group of the EC2)

Love your updates to the Masternode guide Rob!
http://wiki.biblepay.org/Create_Masternode

===

Bad news, Im having trouble with Watchman:
https://github.com/biblepay/biblepay/blob/master/BuildBiblePay.txt
https://github.com/biblepay/watchman

Im using Ubuntu 16.04

My watchman.conf:
~/.biblepaycore/watchman$ venv/bin/python bin/watchman.py
Code: [Select]
[error]: unable to open database file
Cannot connect to database. Please ensure database service is running and user access is properly configured in 'watchman.conf'.

Source Code:
https://github.com/biblepay/watchman/blob/c6f4cdc831b45019b1f7b3b6ce99100b5fa7086f/lib/init.py#L46

https://github.com/biblepay/watchman/blob/c6f4cdc831b45019b1f7b3b6ce99100b5fa7086f/lib/config.py#L82

https://github.com/biblepay/watchman/blob/c6f4cdc831b45019b1f7b3b6ce99100b5fa7086f/lib/config.py#L37

===

~/.biblepaycore/watchman$ venv/bin/pip list

inflection (0.3.1)
peewee (2.8.3)
pip (9.0.1)
pkg-resources (0.0.0)
py (1.4.31)
wheel (0.30.0)

===

So it seems like database file isnt getting created? Im not sure
Looks like peewee library handles the database stuff?

if driver == peewee.SqliteDatabase:
        db_conn = {}

db = driver(db_name, **db_conn)

Oh man thats great!  You almost have it working.  Yeah, on the watchman, I will add those instructions to the create_masternode guide in a few minutes for everyone else.

So lets start with a couple basic things to see if the problem reveals itself.

Im no python guy, but during the time that I was debugging the first superblock I had to figure out how to turn peewee logging on and I was successfully able to see the watchman debug output and figure out where the system was breaking.  So step 1 that might help a little is turning on the logging, and then try to run the venv/bin/python watchman.py again, here is how I turned on logging:

First cd into the watchman directory
Then execute the python interpreter like this:

venv/bin/python

Then you will see the python interpreter command line:
Python interpreter>>

Type:

import os;
os.env["WATCHMAN_DEBUG"]="1";
quit()


Then rerun venv/bin/python watchman.py first to see if it reveals anything.
Btw, I think you already modified your config file properly as it looks good.
The database file itself should have been downloaded to the watchman directory - its called "Watchman".  If you ls -l, and cat the file it should have some tables in it.  Note the case is "Watchman" in this case.

To check to see what is in the database, if you have not gotten further try this:

sudo apt-get install sqlite3
sqlite3 Watchman
sqlite>
select * from votes;
.table <enter>

See if the .table command lists out all the governance object tables?  Or if possibly the "Watchman" file does not even exist in the directory?

Im not sure if you have access to any other machines, but it would also be good to know if the behavior is different on another machine (IE Watchman gets created on ubuntu, but not at AWS).

We will have to see which step it fails to create the database file in.


2814
This is it. This was somehow missing from the wiki instructions, I added it now: http://wiki.biblepay.org/Create_Masternode
(I have no idea how all of you set it up and knew about that :) )

Now when I type masternode status, I get this:

Code: [Select]
{
  "vin": "CTxIn(COutPoint(0000000000000000000000000000000000000000000000000000000000000000, 4294967295), coinbase )",
  "service": "35.196.88.202:40001",
  "status": "Not capable masternode: Masternode not in masternode list"
}

Which I reckon is normal and you just need to add this IP to some list, right? So there it is above. Thanks
Thanks, glad you added that.  I think we had that line in the config at one time and deleted it by accident.

I believe this error is coming from the wallets broadcast identifier, it stores the masternodes public ip, port, and vin (which is the txid and vout of the escrow) in order to validate the masternode when you come on line.

So, check to see if you have ''externalip=your_public_ip" in your base biblepay.conf file on the masternode itself (ie under masternode=1).  Try leaving off the colon and port # as I monkeyed with that and mine is working without the port number crrently at least for that setting.

Then restart the masternode, and wait until 'mnsync status' shows 999, then check the 'masternode status'  again and lets see if it works?


EDIT:  Also ensure your masternode.conf file in the /testnet3 directory of your controller wallet has the public IP And the colon and 40001 in it, and it matches, the public ip, and that you can reach the public ip from the controller wallet with:
telnet public_IP 40001



2815
So a little update for everyone- I spent last night adding the ability to the pool to add a governance object, added a proposal object, and the ability to list proposals.  Since the proposals have to go through phases (IE created, submitted, voted, budgeted, approved, queued for superblock, paid) I have to still add more code to the pool on the testnet side in order to get everyone on board and vote from testnet for the first proposal!  Then we can watch it go through the phases, and add some more code to be able to see the masternodes voting on it!  Kind of like dash-central does, when they see the progress of their proposals, and the entry into the budget superblock cycle.
I also have to ensure we move these proposals to history so we dont clutter up the screen.  We will probably have an active proposals list (those that you can vote on) respecting testnet and prod of course, and then the Historical proposals (those are the ones that have been Paid in a superblock already).

Just as a side note, I am going to create a wiki page for a Fundraiser for testnet, to pay our orphan recurring expenses as a Proposal - IE to simulate a real world use case for January 2018!  Then we can all vote on it here in testnet and see if it pays the keypair properly!

Exciting stuff!  You will be able to click on the row in the proposal to bring up the wiki page to see what you are voting as a masternode....



2816
Maybe this is the problem? Was this exactly 500000 BBP or not? I'm confused with the fee. I used the command from the wiki instructions:

Code: [Select]
sendtoaddress <ESCROW_ADDRESS> 500000
But maybe I need to send it through the GUI and uncheck any fees?

Also, this is how the transaction appears in the wallet:



And balance:




Yeah, you sent it right.  There are a couple ways to double check it.  But first of all when you do it from the command line like that, you cant screw it up.

First, if you do a getrawtransaction b0cfdfa2194556e211099bc620a7e27487958aa5774db0c78ded0f839e3105d2 1, and look at the vout1 you will see its exactly 500 grand.

Next if you type masternode outputs from the node that received the BBP, you will get the proper txid and vout to use for the masternode.conf.

Regarding the 'not a masternode' issue,from masternode status, you have to run that command from the masternode (not the controller wallet).  The masternode has to have the masternode=1 in the config file, along with its masternodeprivkey=XXX in the config.  Was all that set up?

Hopefully you got it all worked out.



2817



*** YIPPI ****

We had our first testnet superblock!  I feel like Evan Duffield.    The Hex encoding finally broke through, oh but the convoluted feeling.

Alright now I need to regroup and figure out how we can add this to the testnet side of the pool.

Will be back tomorrow for more testing.

PS: If anyone wants to see the very first testnet superblock, do a showblock 10125.
I see that the miner gets the block subsidy (no sanctuary is paid the 50% on the superblock, lucky miner gets entire subsidy), and the 15% budget we allocate to IT/PR and Charity is paid in vout 2+ to the recipients of the passing voted budget.  So if we had a superblock every 100 blocks in prod for example (this is only an example), 15% would be held back from all 99 blocks (10% for charity, 5% for IT-PR) and on block 1000, that superblock would have the sum of the 15% allocated over the last 99 blocks included in the voted and approved budget, paying recipients 2+ (IE for the distinct count of approved campaigns) for those 100 blocks.....  Sweet....   

The website will allow us to create proposals in an easier manner, and enter receiving addresses.

Right now it will be a little convoluted to vote on things from the masternodes.  I forgot to mention an added benefit of the cold wallet.  If you plan on hosting say 5 masternodes, you can create one controller wallet and vote on an issue with all masternode keys at once with the command 'gobject vote-many objectid action vote'.  That will alleviate a lot of the pain once we work this template out.




2818
Just got in from work, in my wallet it still says status:enabled in both the My Sanctuaries and All Sanctuaries views.

Got txID f864a54729cff1c481ba3e1a275b5d4c9402560022739bffb9d7cc2bfbf35ad8-000 for block 9461 at 10/12/17 04:43:22 (a few minutes ago local time)

Ok cool, well Im learning more about the details of watchdog now.  It looks like after 7200 seconds, if watchman runs while your node is dead, it fails to create a signable gobject for POSE.  So, somewhere in the picture, it looks like your node would eventually fall behind in the payment queue if you werent the miner.  I think right now we can all get paid because our actual biblepayd instances are miners themselves, so they can always find the receiving address to append to the block plus we have more than enough blocks to go around.


Anyway, this is a very deep rabbit hole, the budgets and superblocks.  It looks like we actually need more code to be executed between proposal, budget and superblock creation (called a trigger).  Im merging in the trigger code now and Ill let everyone know what happens after I figure this out. 

Since we are on testnet, we only need 2 signing masternodes to approve the budget.  Since I have 2 I might be able to approve the budget, will update asap.


2819
So now I am doing a little Biblepay hacking to try to find out if our approved proposal made it into the budget, and therefore becomes a lone superblock.

On a side note, we have superblocks every 25 blocks in testnet. 

If you want to see what is inside watchman, you can do the following:

apt-get install sqlite3

cd into the watchman directory

sqlite3 watchman

sqlite> .tables (ENTER)

select * from proposals;

To dump the schema:

.fullschema

So now, on the bright side, I see our proposal has become a proposal in SQLite.  And I see our watchdog is communicating back and forth for POSE into biblepayd.  I see the votes going into the gobject in SQL. 
     However what Im trying to find next is if the superblock height has to be between the start and end unix time of the approved proposal.  I believe all we had to do was have more than 2 absolute votes for validity and funding for this proposal to become part of the superblock, but cant say for certain yet.  Checking...


2820
910ac78557d3fbefe063e0a070333de4043010db95016002f0661aaa31344de9-001 is one of the MN payments. It was for block 8980.  I also mined block 8980 with TXID 910ac78557d3fbefe063e0a070333de4043010db95016002f0661aaa31344de9-000.
I see it, looks like a masternode payment.

I did see your watchdog expire while I was casually looking.  I wonder if your payments stopped after that?


Pages: 1 ... 181 182 183 184 185 186 187 [188] 189 190 191