Skip to main content

A Python package for interacting with Cardano.

Project description

Installation

⚠️ Warning: Only x86/64 Linux platform is supported.

pip install adaup

SystemWide Installation

sudo pip install --upgrade adaup --break-system-packages

After installation, the cardano executable will be available in your PATH.

Usage

The cardano executable provides a command-line interface to manage Cardano and Hydra nodes.

Running a Cardano Node

To start a Cardano node for a specific network (e.g., preview or preprod or mainnet ), use the node command:

cardano node preview

You can also specify a different network or node version:

cardano node mainnet 

For a local single-node development network with prepackaged genesis material and an auto-funded default wallet in ~/.cardano/keys, use:

cardano node devnet

This starts a local node at ~/.cardano/devnet/node.socket using cardano-node 11.0.1, regenerates payment.*, stake.* and payment.addr under ~/.cardano/keys on each run, and funds that address with 1000000000000 lovelace (1,000,000 ADA) from the devnet faucet. The packaged devnet genesis funds the faucet with enough lovelace for repeated local bootstraps.

Running Cardano CLI Commands

To execute cardano-cli commands, use the cli subcommand followed by the cardano-cli arguments:

export CARDANO_NODE_SOCKET_PATH=~/.cardano/preview/node.socket
cardano cli query tip --testnet-magic 2
cardano cli query tip --testnet-magic=2 --socket-path=~/.cardano/preview/node.socket ## socket path in the cli

Running a Hydra Cluster

To set up and run a Hydra cluster:

  1. Bootstrap Hydra Node Credentials: Generate the necessary folders and credentials for your Hydra nodes. This will create hydra-{n} directories under $HOME/.cardano/<network_name>/.

    e.g. this will generate configuration for running 2 hydra nodes.

    cardano hydra bootstrap preview  2
    
  2. Start 1st Hydra Node:

    cardano hydra node preview  0
    
  3. Start 2nd Hydra Node in different terminal:

    cardano hydra node preview  1
    

    Note the command to run this node is available at ~/.cardano/preview/hydra-0/run.sh

  4. Watch hydra status in Hydra TUI : To interact with a running Hydra node, you can open the Text User Interface (TUI):

    cardano hydra tui  0
    
  5. Reset Hydra Head Data : Shutdown you nodes, and use reset command to restart a new hydra head with same configurations. You can then start the nodes again.

    cardano hydra reset preview
    
  6. Prune Hydra Cluster : To remove all keys, data and cluster information. You need to bootstrap the cluster again.

    cardano hydra prune preview
    

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

adaup-0.2.0.tar.gz (33.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

adaup-0.2.0-py3-none-any.whl (42.5 kB view details)

Uploaded Python 3

File details

Details for the file adaup-0.2.0.tar.gz.

File metadata

  • Download URL: adaup-0.2.0.tar.gz
  • Upload date:
  • Size: 33.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.2.0 CPython/3.10.20

File hashes

Hashes for adaup-0.2.0.tar.gz
Algorithm Hash digest
SHA256 c9b4a1127f8a1e908be20b76ea13e92cee014a740b43b147df953e8e22aa6970
MD5 8e97c485da4cbada6ad783b7c88ac28f
BLAKE2b-256 7a38ec148ae3570f068b8bfe236f79120f17c98f6c86e4089c36a262398fdb89

See more details on using hashes here.

File details

Details for the file adaup-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: adaup-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 42.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.2.0 CPython/3.10.20

File hashes

Hashes for adaup-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 fac7ceb65e3df7c6e454efa3b781811ee48d87b7971299c9a3ea4baea046ce72
MD5 d2d686711106779c68073312c2e21cab
BLAKE2b-256 33912f877034a16721329333cb040277054fd4a4d66f8c5a96ca5f789a275125

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page