Bitcoin Forum

Alternate cryptocurrencies => Altcoin Discussion => Topic started by: chameleon123 on October 26, 2018, 06:13:12 PM



Title: How can I disable bitcoind auto test cases in main network?
Post by: chameleon123 on October 26, 2018, 06:13:12 PM
Hello. I recently saw some BOOST_AUTO_TEST_CASE in /src/test folder. I want to disable them specially pow_tests.cpp. Does any one know how it can be done ?


Title: Re: How can I disable bitcoind auto test cases in main network?
Post by: bob123 on October 26, 2018, 06:20:56 PM
Sometimes it is more helpful to explain what you want to achieve instead of asking about a particular step which you think will help you achieving your goal.

This sounds like a XY problem (https://en.wikipedia.org/wiki/XY_problem). May i ask what you exactly want to achieve (especially why you want to 'disable' source files) ?


Title: Re: How can I disable bitcoind auto test cases in main network?
Post by: chameleon123 on October 27, 2018, 04:46:19 AM
Sometimes it is more helpful to explain what you want to achieve instead of asking about a particular step which you think will help you achieving your goal.

This sounds like a XY problem (https://en.wikipedia.org/wiki/XY_problem). May i ask what you exactly want to achieve (especially why you want to 'disable' source files) ?


The real reason I asked this was a strange problem I faced in my last post of https://bitcointalk.org/index.php?topic=5039512.msg46439126#msg46439126 (https://bitcointalk.org/index.php?topic=5039512.msg46439126#msg46439126).

I only changed nBits field and consenus.powLimit field in chainparams.cpp(created new genesis block according to the change) . I wanted to increase threshold and reduce difficulty but when I started up two nodes and tried to add one node to the other, but when I typed
Code:
bitcoin-cli getblocktemplate
I get:

Code:
error code: -10
error message:
Bitcoin is downloading blocks...

I tried hard for a while where this comes from and had to take any speculation into consideration. I thought maybe in some test cases it failed bc I changed target threshold(tried to change some test cases as well but didn't work). Do you have any suggestion on this ?

Here is the link to my code and changes : https://github.com/chameleon1239/bitcoin.git (https://github.com/chameleon1239/bitcoin.git). I would be so thankful if you could find some time and take a look at it. The two parameters that caused this is only nBits and consenus.powLimit.


Title: Re: How can I disable bitcoind auto test cases in main network?
Post by: raden1922 on October 28, 2018, 04:30:56 AM
So far I have never thought about how to disable, even I just heard or read from your post here. I wonder your reason for deactivating.
This confused me.


Title: Re: How can I disable bitcoind auto test cases in main network?
Post by: chameleon123 on October 28, 2018, 05:40:38 AM
You can change the program if you know the code. Also, the provided site and contacting them should help. So you can try various way, but the default settings are always in your support if you're a novice.

I tried to, but I though it would be simple because they were only two fields in the code. Unfortunately I am a newbie to gdb and don't have any idea how to debug the coin efficiently. I searched google and everywhere but it seems no one even tried it and nobody knows anything about what I'm struggling. I'm bound to a strict deadlineand don't know what to do. :(


Title: Re: How can I disable bitcoind auto test cases in main network?
Post by: chameleon123 on October 28, 2018, 05:47:35 AM
So far I have never thought about how to disable, even I just heard or read from your post here. I wonder your reason for deactivating.
This confused me.

Do you have any idea what are possible reasons to my problem? If you reached anything, any idea I'd be very happy if you let me know about it.


Title: Re: How can I disable bitcoind auto test cases in main network?
Post by: Ted DiBiase on October 28, 2018, 09:26:15 AM
I do not understand why do you want to disable the source file. Seems like you aren't getting any answers even on your previous post. I suggest you seek professional help or try on reddit or google.


Title: Re: How can I disable bitcoind auto test cases in main network?
Post by: BarneyXC on October 28, 2018, 09:29:48 AM
Sometimes it is more helpful to explain what you want to achieve instead of asking about a particular step which you think will help you achieving your goal. I wanted to increase threshold and reduce difficulty but when I started up two nodes and tried to add one node to other.


Title: Re: How can I disable bitcoind auto test cases in main network?
Post by: Aidenpeters on October 29, 2018, 04:34:32 AM
Best advice would be to try a few sources of information to find what you're looking for. Considering the nature of the problem it is important to try several places, determine the best possible solution from the information provided. Hopefully you'll find what you're looking for.


Title: Re: How can I disable bitcoind auto test cases in main network?
Post by: chameleon123 on October 29, 2018, 05:08:38 AM
Best advice would be to try a few sources of information to find what you're looking for. Considering the nature of the problem it is important to try several places, determine the best possible solution from the information provided. Hopefully you'll find what you're looking for.

Thank you for the advice. I know "Mastering Bitcoin" is a good source for learning about bitcoin.I also tried to study functions and see where they are referenced in the code. U try to keep the effort go on. I'll let you all know if I find the solution.


Title: Re: How can I disable bitcoind auto test cases in main network?
Post by: chameleon123 on October 29, 2018, 05:10:24 AM
Sometimes it is more helpful to explain what you want to achieve instead of asking about a particular step which you think will help you achieving your goal. I wanted to increase threshold and reduce difficulty but when I started up two nodes and tried to add one node to other.

This is absolutely good enough reason for all to know. If you want more info see may last post in https://bitcointalk.org/index.php?topic=5057572.msg47318146#msg47318146 (https://bitcointalk.org/index.php?topic=5057572.msg47318146#msg47318146)


Title: Re: How can I disable bitcoind auto test cases in main network?
Post by: chameleon123 on October 29, 2018, 05:16:23 AM
I do not understand why do you want to disable the source file. Seems like you aren't getting any answers even on your previous post. I suggest you seek professional help or try on reddit or google.

I'm still trying to find some one professional in person. I don't know if google or reddit have technical discussion part but I will take a look.Thanks.


Title: Re: How can I disable bitcoind auto test cases in main network?
Post by: Ocoremar06 on October 30, 2018, 03:47:35 PM
I would suggest you to run a decoder if you are experienced with it. If the input value is true then it will run and false scenario will not.


Title: Re: How can I disable bitcoind auto test cases in main network?
Post by: Oleriwyr21 on October 30, 2018, 03:47:50 PM
Try disabling the decorder, it might help. True value will demonstrate that the test unit will run and false value will demonstrate that the test unit will not run.


Title: Re: How can I disable bitcoind auto test cases in main network?
Post by: Onalelle87 on October 30, 2018, 03:48:06 PM
Did you disable the decorator? A false value indicates test units will not run and a true value indicates otherwise. I think this will solve the issue.


Title: Re: How can I disable bitcoind auto test cases in main network?
Post by: chameleon123 on October 30, 2018, 05:56:49 PM
Guys!!!! I can't believe the problem is finally solved. @achow101 played the greatest part and I'm very grateful. See the reason in the three final posts in https://bitcointalk.org/index.php?topic=5057572.new#new (https://bitcointalk.org/index.php?topic=5057572.new#new) (which was another speculation of mine) if you are interested. The reason was quite interesting.


Title: Re: How can I disable bitcoind auto test cases in main network?
Post by: oioioi on October 30, 2018, 10:26:48 PM
I have never experienced this before, but the problem that you have faced seems to be rarely experienced by many people, so it must deactivate it, but this should be studied further