Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Local changes needed to run lobster-contribute.sh #8

Open
bryanyee opened this issue Sep 18, 2021 · 2 comments
Open

Local changes needed to run lobster-contribute.sh #8

bryanyee opened this issue Sep 18, 2021 · 2 comments

Comments

@bryanyee
Copy link

bryanyee commented Sep 18, 2021

Hi, I'm documenting two local changes I made in order to run the lobster-contribute.sh script. Hopefully this helps others! I'm using a Mac, so I'm not sure if other environments would have had similar issues.

Full script signature (run from scripts folder):

./lobster-contribute.sh <my_utxo> <lobster_script_utxo> <my_payment_address_path> <my_payment_signing_key_path> <old_counter> <new_counter> <old_votes>

Changes needed:

Ensure that the CARDANO_NODE_SOCKET_PATH is correct in the script files. Two options:

  • Remove the export CARDANO_NODE_SOCKET_PATH line in shell scripts, since it's likely already set in .bashrc or .zshrc.
  • Or, set CARDANO_NODE_SOCKET_PATH to the correct location for your node.socket file.
  • This is needed in lobster-contribute.sh, lobster-deploy.sh, lobster-mint-nft.sh, mainnet-query-protocol-parameters.sh, and mainnet-utxo-at.sh

Ensure you can run cardano-cli.

  • There may be multiple ways to ensure that cardano-cli is available in the scripts. I just removed ./ in front on cardano-cli in the following scripts (assuming cardano-cli is already available in your $PATH):
    • lobster-contribute.sh, lobster-deploy.sh, lobster-mint-nft.sh, mainnet-query-protocol-parameters.sh, mainnet-script-address.sh, mainnet-utxo-at.sh, and policyId.sh
@jbarros35
Copy link

what is these old counter, new counter old votes?

@bryanyee
Copy link
Author

what is these old counter, new counter old votes?

Use the cli to query the utxos at the script address:

# Option 1 - script
./mainnet-utxo-at.sh addr1w8433zk2shufk42hn4x7zznjjuqwwyfmxffcjszw5l2ulesdt3jff

# Option 2 - run CLI directly (I had some issues running the script)
cardano-cli query utxo \
--address addr1w8433zk2shufk42hn4x7zznjjuqwwyfmxffcjszw5l2ulesdt3jff \
--mainnet

The output should look like:

                           TxHash                                 TxIx        Amount
--------------------------------------------------------------------------------------
319752b414804415988fb1165358e69f46095a9e9b1c01ef0830c182dc57f78b     0        1000000 lovelace + TxOutDatumHashNone
4c34feb07e32aa4855a494306aefcf16743356811914d680e112a6ec12214455     0        1000000 lovelace + TxOutDatumHashNone
63091c70aa6f8b402faffd24909d93c7721cbdced7094b62e52d157da8fb44e4     0        5000000 lovelace + TxOutDatumHashNone
67d318fabdd9905033bfe6156c6595716c952d496cabb9d98773c948974780ec     0        1000000 lovelace + TxOutDatumHashNone
85fef164485267ef2023bf3aee53036ef2b6c0ce4e8158913a5d759e7b7cda5b     1        2034438 lovelace + 1 cc7888851f0f5aa64c136e0c8fb251e9702f3f6c9efcf3a60a54f419.LobsterNFT + 13501 fda1b6b487bee2e7f64ecf24d24b1224342484c0195ee1b7b943db50.LobsterCounter + 318 fda1b6b487bee2e7f64ecf24d24b1224342484c0195ee1b7b943db50.LobsterVotes + TxOutDatumHash ScriptDataInAlonzoEra "45b0cfc220ceec5b7c1c62c4d4193d38e4eba48e8815729ce75f9c0ab0e4c1c0"
cb7b44500fc9145cf5b13a533bc7616eb219b7a080bc49d7ce6204c06b351733     0        1000000 lovelace + TxOutDatumHashNone
db250ed5eb4454843af19dea7ca84a8adda170fc88284e7e5e2381b41dab5f9b     1        30768137 lovelace + TxOutDatumHashNone

The utxo used for this vote is the one that has a really long entry in the table. Right now, it has the TxHash 85fef164485267ef2023bf3aee53036ef2b6c0ce4e8158913a5d759e7b7cda5b, but this will change over time.

From that entry, we can get the values:

  • Old counter: 13501
  • New counter: 13502
  • Old votes: 318

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants