Skip to content

Releases: 0xSpaceShard/starknet-hardhat-plugin

v0.4.2

28 Feb 17:04
Compare
Choose a tag to compare

Usage changes

  • Introduce utility functions for handling L1-L2 communication (postman message exchange with Devnet):
    • starknet.devnet.loadL1MessagingContract - for loading an L1 contract that exchanges messages between L1 and L2
    • starknet.devnet.flush - for propagating messages to the other layer
    • Basic example
    • Complex example
  • Introduce an Account class for invoking/calling contract functions through an Account. Create Account using utility functions:
    • starknet.deployAccountFromABI - for new Account deployment
    • starknet.getAccountFromAddress - for loading a predeployed Account
    • Basic example
    • Complex example

Dev specific changes

  • None

PRs merged

Full Changelog: v0.4.1...v0.4.2

v0.4.1

21 Feb 10:35
Compare
Choose a tag to compare

Usage

  • Use cairo-lang 0.7.1 by default.
  • Make hardhat a peerDependency (and devDependency).

Dev

  • Introduce formatting (prettier).
  • Fix CI/CD workflow.

What's Changed

New Contributors

Full Changelog: v0.4.0...v0.4.1

v0.4.0

15 Feb 09:51
Compare
Choose a tag to compare

Usage

  • Expand tilde (~) to homedir in venv path.
  • Add Docker issue fix to Readme.
  • BREAKING changes:
    • Rename string utility functions to reflect their real purpose (functionality stays the same, the name changes):
      • stringToBigInt -> shortStringToBigInt
      • bigIntToString -> bigIntToShortString
    • Change the expected config file structure (check here for an example):
      • Use starknet key.
      • Stop using cairo key:
        • Rename version to dockerizedVersion:
          • Because the version key affected and affects only the Docker image used (if user opts for dockerized mode).
      • Move wallets key to starknet.
      • Rename starknetNetwork to network and move it from mocha to starknet:
        • This is because the network wasn't just mocha specific but could be used in any Hardhat script.
    • Use options object in StarknetContract methods instead of using optional function arguments; e.g.:
      • OLD: StarknetContract.call(functionName: string, args?: StringMap, signature?: Array<Numeric>, wallet?: Wallet, blockNumber?: string)
      • NEW: StarknetContract.call(functionName: string, args?: StringMap, options: CallOptions = {})

Dev

  • No dev-specific changes to list.

Merged PRs

Full Changelog: v0.3.11...v0.4.0

v0.3.11

04 Feb 17:30
Compare
Choose a tag to compare

Usage

Dev

  • Update linter.

PRs merged

Full Changelog: v0.3.10...v0.3.11

v0.3.10

24 Jan 15:55
11d6da6
Compare
Choose a tag to compare

Usage

  • Use cairo-lang v0.7.0 as the default Docker image (if using the Docker mode).
  • Support arrays of structs in function input/output.
  • Fix parsing negative BigInt by @clexmond.
  • Improve error message on invalid CLI input to deploy/invoke/call (the --inputs option).

Dev

  • Use cache in CircleCI.
  • Use hardhat v2.8.2.

PRs merged

Full Changelog: v0.3.9...v0.3.10

v0.3.9

13 Jan 15:27
Compare
Choose a tag to compare

Usage

  • Add starknet-invoke and starknet-call tasks.
  • Improved error logging:
    • If invalid number of arguments or keys passed to Starknet functions.
    • Log available networks.
  • Improve Readme.
  • Support specifying salt when deploying contracts:
    • With npx hardhat starknet-deploy.
    • With ContractFactory.deploy.

Dev

  • Add linting.
  • Update hardhat version.
  • Refactor.

PRs

Full Changelog: v0.3.8...v0.3.9

v0.3.8

22 Dec 13:49
Compare
Choose a tag to compare

Usage

  • Add utility functions for converting short string literals to BigInt and vice versa:
    • stringToBigInt
    • bigIntToString
  • Improve Readme.
  • Improve deployment logging.

Dev

  • Refactor index.ts into task-actions.ts and extend-utils.ts.
  • In Starknet wrappers:
    • Consistently await internal function calls.
    • Fix typo.

PRs

Full Changelog: v0.3.7...v0.3.8

v0.3.7

15 Dec 17:22
Compare
Choose a tag to compare

What's Changed

Usage

  • Fix interacting with starknet-devnet if using the Docker option (specified with cairo.version in hardhat.config).

Dev

  • Restructure tests.
  • Reduce the amount of work done in CI.
  • Test starknet-devnet interaction in CI.

Full Changelog: v0.3.6...v0.3.7

v0.3.6

14 Dec 14:55
Compare
Choose a tag to compare

What's Changed

  • Parallelize testing workflow + adapt to cairo-lang v0.6.2 by @dribeiro-ShardLabs in #30
  • Refactor running Starknet commands; Fix devnet interaction on macOS+venv by @FabijanC in #29

Usage

  • Fix interaction with starknet-devnet when using venv on macOS.
  • Adapt to v0.6.2:
    • when awaiting transactions, they are resolved when ACCEPTED_ON_L2)
    • have both alpha and goerli-alpha as predefined network names for Alpha Testnet (on Goerli)
  • Use alpha-mainnet as the predefined network name of Alpha Mainnet.
  • Improve Readme.

Dev

  • Parallelize jobs in CircleCI (reduce testing time).
  • Major refactor of how Starknet CLI commands are internally run.

Full Changelog: v0.3.5...v0.3.6

v0.3.5

09 Dec 10:18
cd6b2aa
Compare
Choose a tag to compare

What's Changed

Usage

  • Add starknet-verify task:
    • Enables verifying contracts on Voyager through the CLI instead of through UI
    • Suggested by @maciejka.
  • Add --wait flag to starknet-deploy task:
    • Allows waiting until deployment becomes at least PENDING.
  • Handle error arising on using Python virtual environment without cairo-lang.
  • Improve getContractFactory (the function that creates a contract factory from the provided contract):
    • Handle ambiguous input.
    • Allow specifying the contract by the path of its source.

Dev

  • Replace the recursive traverseFiles with glob package.

New Contributors

Full Changelog: v0.3.4...v0.3.5