forknote / cryptonote-generator

Generate Cryptonote coin with 1 command
104 stars 211 forks source link

Forknote Generator issues with extensions/premine #56

Closed davidealva closed 6 years ago

davidealva commented 6 years ago

I've been playing around with this for about a week and come to the conclusion there needs to be more info somewhere on how to compile and use these extensions. When I use the JSON file generated by the creator I was given this to use:

{ "base_coin": { "name": "bytecoin", "git": "https://github.com/amjuarez/bytecoin.git" }, "core": { "SEED_NODES": [ "159.203.250.77:44615", "159.203.211.218:44615" ], "EMISSION_SPEED_FACTOR": 18, "DIFFICULTY_TARGET": 120, "CRYPTONOTE_DISPLAY_DECIMAL_POINT": 8, "MONEY_SUPPLY": "8446744000000000", "GENESIS_BLOCK_REWARD": "253402320000000", "DEFAULT_DUST_THRESHOLD": 100, "MINIMUM_FEE": 100, "CRYPTONOTE_MINED_MONEY_UNLOCK_WINDOW": 10, "CRYPTONOTE_BLOCK_GRANTED_FULL_REWARD_ZONE": 100000, "MAX_TRANSACTION_SIZE_LIMIT": 100000, "CRYPTONOTE_PUBLIC_ADDRESS_BASE58_PREFIX": 76, "DIFFICULTY_CUT_V1": 60, "DIFFICULTY_CUT_V2": 60, "DIFFICULTY_CUT": 0, "DIFFICULTY_LAG_V1": 15, "DIFFICULTY_LAG_V2": 15, "DIFFICULTY_LAG": 0, "DIFFICULTY_WINDOW_V1": 720, "DIFFICULTY_WINDOW_V2": 720, "DIFFICULTY_WINDOW": 17, "ZAWY_DIFFICULTY_V3": 1, "ZAWY_DIFFICULTY_DIFFICULTY_BLOCK_VERSION": 3, "P2P_DEFAULT_PORT": 44615, "RPC_DEFAULT_PORT": 44616, "BYTECOIN_NETWORK": "d2bc902d-ee63-c999-99a4-136af5dd2660", "CRYPTONOTE_NAME": "plastic", "DAEMON_NAME": "plasticd", "GENESIS_COINBASE_TX_HEX": "", "CHECKPOINTS": "", "MAX_BLOCK_SIZE_INITIAL": 100000 }, "extensions": [ "core/bytecoin.json", "bug-fixes.json", "print-genesis-tx.json", "genesis-block-reward.json" ] }

This file compiles fine on Mac OSX and when it comes to running the daemon the first time to generate the "GENESIS_COINBASE_TX_HEX" for the first time I get:

'Failed to parse arguments: Failed to initialize currency object'

If I remove the "genesis-block-reward.json" extension and recompile and run the daemon again with the "--print-genesis-tx" argument then it produces the hex properly. I have to then add the "genesis-block-reward.json" and recompile again to be able to use the argument to add the " --genesis-block-reward-address"

Interestingly enough on the forknote creator, there is an input to add "Addresses for the premined coins" and yet when the config file is generated it doesn't appear to have any relevance. So what am I missing here?

Once I add the "genesis-block-reward.json" and start the daemon with the address and start the simplewallet and miner it starts to add transactions to the wallet but only small fractions. If I set the total money supply to something like 5000 coins and do a premine of 50% or 2500 coins, then I see the 2500 in one single transaction. Larger numbers premined seem to trickle in, can you clarify what the bug is here with the extensions and Genesis Block Reward?

pmitchev commented 6 years ago

Use dummy GENESIS_COINBASE_TX_HEX from some of the other coins. Then replace it with your and delete the blockchain folder.

To add addresses, use --genesis-block-reward-address when you generate. You can add multiple addresses with multiple --genesis-block-reward-address

davidealva commented 6 years ago

So why is it then I have to compile first without the "genesis-block-reward.json" extension to generate my hex? Also, I understand this with the addresses:

"To add addresses, use --genesis-block-reward-address when you generate. You can add multiple addresses with multiple --genesis-block-reward-address"

How does that resolve this? "Once I add the "genesis-block-reward.json" and start the daemon with the address and start the simplewallet and miner it starts to add transactions to the wallet but only small fractions. If I set the total money supply to something like 5000 coins and do a premine of 50% or 2500 coins, then I see the 2500 in one single transaction. Larger numbers premined seem to trickle in, can you clarify what the bug is here with the extensions and Genesis Block Reward?"

It would be good to expand on these issues a bit more to understand how these extensions and options work.

luiscosio commented 6 years ago

@davidealva Come join us at https://t.me/forknote

gldneagl commented 6 years ago

In reply to your original post... It seems that folks are resistant to providing enough information on the process of creating a new coin. A lot of empty rhetoric that rarely stays directly on topic, and more importantly, answers what was asked.

In this particular case, aka Forknote etc, seems to run you directly into a catch-22 when using the form to create your new config.

It asks for a GENESIS_COINBASE_TX_HEX that you cannot possibly have yet, and doesn't provide any help for what to do to create it, and the form also requires an address to "premine" to, but without any detail about what wallet address, when you cannot possibly have one yet for a brand new coin you are trying to create.

pmitchev commented 6 years ago

@gldneagl Just use dummy GENESIS_COINBASE_TX_HEX. Then print the real one with --print-genesis-tx and substitute. Better do those stuffs with forknote, so you do not waste time in compiling

mike2lab commented 6 years ago

Hello i have same issue with the premined coins. Without the --genesis-block-reward-address option, it works fine and prints the Genesis HEX TX.

But When i put this command :

./forknoted --config-file configs/althusconf.conf --print-genesis-tx --genesis-block-reward-address 22PicfUoS9LUU1RUyqCBPmbYiiFvmzjBm2Xy7o7GEjXpN29WkQdPiEs966RmWXREsADAscZ2Ej7m2Tup6btBk8WnA98E5db

I get this message:

Success: Configuration file openned: "configs/althusconf.conf" Failed to parse address: 22PicfUoS9LUU1RUyqCBPmbYiiFvmzjBm2Xy7o7GEjXpN29WkQdPiEs966RmWXREsADAscZ2Ej7m2Tup6btBk8WnA98E5db

I have already created a wallet before this
Any ideas ?