npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

@chainlink-sol-fork/gauntlet-solana-contracts

v1.4.0

Published

Gauntlet Solana Contracts

Downloads

3

Readme

gauntlet-solana

Prepare

yarn

Create a .env on the project root directory, and set your private key as:

# .env
PRIVATE_KEY=[38,56,112,28,28,122, ...]

Optional: Build binary

yarn bundle

Execute commands:

Contracts available

  • Access Controller: access_controller
  • OCR2: ocr2
  • Flags: flags,
  • Deviation flagging store: store

Commands

To execute with binary, change yarn gauntlet for ./bin/chainlink-solana-[macos|linux] <command>

  • Deploy

Deployment is available for any of the contracts in the list

yarn gauntlet <contract_name>:deploy --network=<testnet|devnet>
  • Commands available

Contract functions are only available in some contracts. Get the latest supported commands running

yarn gauntlet help
  • Interact with contract
yarn gauntlet <contract_name>:<contract_function> --network=<testnet|devnet> --state=<state_account_public_key> [OPTIONAL: --<function_parameter_name=<value>] <contract_address>

Command example:

yarn gauntlet <contract_name>:<contract_function> --help

Testing Locally

Preparation

  • Include program keypairs under /packages/gauntlet-solana-contracts/artifacts/programId/*.json, resulting in:
packages/gauntlet-solana-contracts/artifacts/programId
|  access_controller.json
|  store.json
|  ocr2.json
  • Make sure these accounts public keys correspond to the ones declared on each contract declare_id. If they don't, compile the contracts (anchor build) with the correct declare_id and move the generated binaries from /target/deploy/*.so to /packages/gauntlet-solana-contracts/artifacts/bin/*.so

  • Run a local store node

solana config set --url http://127.0.0.1:8899
solana-test-store -r
  • Get some SOL on your account. This account needs to be the same specified on gauntlet .env PRIVATE_KEY
solana airdrop 100 9ohrpVDVNKKW1LipksFrmq6wa1oLLYL9QSoYUn4pAQ2v

Running

A flow command can be executed to set up everything needed. Program deployments, initialization, configuration setting and single transmission.

SKIP_PROMPTS=true yarn gauntlet ocr2:setup:flow --network=local

The result of the command will be stored on /flow-report.json file

If any error occurs, the flow can be started from that point, using the previous flow report, as:

SKIP_PROMPTS=true yarn gauntlet ocr2:setup:flow --network=local --withReport --start=<step number>

After the flow has finished succesfully, more transmissions can be executed, either by:

SKIP_PROMPTS=true yarn gauntlet ocr2:setup:flow --network=local --withReport --start=12 --round=2

or

yarn gauntlet ocr2:transmit --network=local --state=<state_account_public_key> --transmissions=<state_account_public_key> --store=<state_account_public_key> --accessController=<state_account_public_key> --round=<round number>

The account public keys can be found inside the /flow-report.json file

Make sure to increment the round after every transmission