Coder Social home page Coder Social logo

kasarlabs / deoxys-fork Goto Github PK

View Code? Open in Web Editor NEW

This project forked from keep-starknet-strange/madara

27.0 3.0 8.0 153.9 MB

Deoxys πŸ‘½ is a Starknet full node based on substrate and powered by Rust πŸ¦€

Home Page: https://deoxys.kasar.io

License: MIT License

Rust 99.06% Nix 0.12% Dockerfile 0.11% Shell 0.70%

deoxys-fork's Introduction

πŸ‘½ Deoxys: Starknet full node client on Substrate

βš™οΈ Installation

πŸ“Έ Snapshots

βœ” Supported Features

πŸ‘ Contribute

🀝 Partnerships

To establish a partnership with the Kasar team, or if you have any suggestion or special request, feel free to reach us on telegram.

⚠️ License

Copyright (c) 2022-present, with the following contributors.

Deoxys is open-source software licensed under the Apache-2.0 License.

deoxys-fork's People

Contributors

antiyro avatar abdelstark avatar lucaslvy avatar evolveart avatar dependabot[bot] avatar tdelabro avatar d-roak avatar apoorvsadana avatar jbcaron avatar clementwalter avatar greged93 avatar nils-mathieu avatar lambda-0x avatar sparqet avatar lana-shanghai avatar dbejarano820 avatar drspacemn avatar bajpai244 avatar glihm avatar chirag-bgh avatar zarboq avatar lucienfer avatar davidesilva avatar fishseabowl avatar mdteach avatar eikix avatar tarrencev avatar xjonathanlei avatar jobez avatar exp-table avatar

Stargazers

Jimmy Fate avatar Asten avatar Bolaji Ahmad avatar Tristan avatar nicabar avatar adel avatar 0xCa11ab1e avatar  avatar Abel David avatar  avatar  avatar Starkience avatar Srdjan avatar  avatar Mathieu avatar 0xKubitus avatar Mael Jousset avatar  avatar 0xYYY avatar StarkNet δΈ­ζ–‡ | China avatar Francesco Ceccon avatar  avatar  avatar  avatar Eytan Levy avatar Yohan @ ScreenshotLabs avatar Tbelleng avatar

Watchers

Ninja342 avatar SovTester avatar  avatar

deoxys-fork's Issues

feat/starknet_addInvokeTransaction

Issue: Implement starknet_addInvokeTransaction RPC Call

Description:
The starknet_addInvokeTransaction RPC call has been implemented but requires further testing and verification against the entire state. This RPC call invokes a function of a deployed contract from an L1 transaction.

Parameters:

  • transaction: The invoke transaction to add. This parameter is required.

Expected Result:
The result of the transaction invocation.

Potential Errors:

  • TXN_FAILED: The transaction failed.
  • TXN_ALREADY_KNOWN: The transaction is already known.

Testing:
Initial testings can be found here. However, these should not be considered complete and improvements are welcome.

Resources:

Comments:
Please comment below for coordination.

feat/starknet_call

Issue: Implement starknet_call RPC Call

Description:
The starknet_call RPC call has been implemented but requires further testing and verification against the entire state. This RPC call allows for calling a StarkNet function without creating a StarkNet transaction.

Parameters:

  • request: The details of the function call.
  • block_id: The hash of the requested block, or number (height) of the requested block, or a block tag. This parameter is required.

Expected Result:
The function's return value, as defined in the Cairo output.

Potential Errors:

  • CONTRACT_NOT_FOUND: The specified contract could not be found.
  • CONTRACT_ERROR: An error occurred in the contract.
  • BLOCK_NOT_FOUND: The specified block could not be found.

Testing:
Initial testings can be found here. However, these should not be considered complete and improvements are welcome.

Resources:

Comments:
Please comment below for coordination.

feat/starknet_getStorageAt

Issue: Implement starknet_getStorageAt RPC Call

Description:
Get the value of the storage at the given address and key.

Parameters:

  • contract_address: The address of the contract to read from. This parameter is required.
  • key: The key to the storage value for the given contract. This parameter is required.
  • block_id: The hash of the requested block, or number (height) of the requested block, or a block tag. This parameter is required.

Expected Result:
The value at the given key for the given contract. If no value is found, the result should be 0.

Potential Errors:

  • CONTRACT_NOT_FOUND: The specified contract could not be found.
  • BLOCK_NOT_FOUND: The block requested could not be found.

Testing:
Initial testings can be found here. However, these should not be considered complete and improvements are welcome.

Resources:

Comments:
Please comment below for coordination.

feat/starknet_getNonce

Issue: Implement starknet_getNonce RPC Call

Description:
The starknet_getNonce RPC call has been implemented but requires further testing and verification against the entire state. This RPC call retrieves the nonce associated with the given address in the specified block.

Parameters:

  • block_id: The hash of the requested block, or number (height) of the requested block, or a block tag. This parameter is required.
  • contract_address: The address of the contract whose nonce is being sought. This parameter is required.

Expected Result:
The contract's nonce at the requested state.

Potential Errors:

  • BLOCK_NOT_FOUND: The specified block could not be found.
  • CONTRACT_NOT_FOUND: The specified contract could not be found.

Testing:
Initial testings can be found here. However, these should not be considered complete and improvements are welcome.

Resources:

Comments:
Please comment below for coordination.

feat/starknet_getClassHashAt

Issue: Test starknet_getClassHashAt RPC Call

Description:
The starknet_getClassHashAt RPC call has been implemented but requires further testing and verification against the entire state. This RPC call retrieves the contract class hash in the given block for the contract deployed at the specified address.

Parameters:

  • block_id: The hash of the requested block, or number (height) of the requested block, or a block tag. This parameter is required.
  • contract_address: The address of the contract whose class hash will be returned. This parameter is required.

Expected Result:
The class hash of the given contract.

Potential Errors:

  • BLOCK_NOT_FOUND: The specified block could not be found.
  • CONTRACT_NOT_FOUND: The specified contract could not be found.

Testing:
Initial testings can be found here. However, these should not be considered complete and improvements are welcome.

Resources:

Comments:
Please comment below for coordination.

feat/starknet_getClassAt

Issue: Implement starknet_getClassAt RPC Call

Description:
The starknet_getClassAt RPC call has been implemented but requires further testing and verification against the entire state. This RPC call retrieves the contract class definition in the given block at the specified address.

Parameters:

  • block_id: The hash of the requested block, or number (height) of the requested block, or a block tag. This parameter is required.
  • contract_address: The address of the contract whose class definition will be returned. This parameter is required.

Expected Result:
The contract class definition for the given address in the specified block. The result can be:

  1. Deprecated contract class
  2. Contract class

Potential Errors:

  • BLOCK_NOT_FOUND: The specified block could not be found.
  • CONTRACT_NOT_FOUND: The specified contract could not be found.

Testing:
Initial testings can be found here. However, these should not be considered complete and improvements are welcome.

Resources:

Comments:
Please comment below for coordination.

RUSTSEC-2021-0059: `aesni` has been merged into the `aes` crate

aesni has been merged into the aes crate

Details
Status unmaintained
Package aesni
Version 0.10.0
URL RustCrypto/block-ciphers#200
Date 2021-04-29

Please use the aes crate going forward. The new repository location is at:

<https://github.com/RustCrypto/block-ciphers/tree/master/aes>

AES-NI is now autodetected at runtime on i686/x86-64 platforms.
If AES-NI is not present, the aes crate will fallback to a constant-time
portable software implementation.

To prevent this fallback (and have absence of AES-NI result in an illegal
instruction crash instead), continue to pass the same RUSTFLAGS which were
previously required for the aesni crate to compile:

RUSTFLAGS=-Ctarget-feature=+aes,+ssse3

See advisory page for additional details.

feat/rpc_parity

Issue: Solve All RPC Call implementations Issues

Description:
Several RPC call testing issues have been generated for the StarkNet system. This issue serves as an overarching task to address and solve each individual testing issue related to the RPC calls.

Tasks:

  1. Review all the generated RPC call testing issues.
  2. Coordinate with the team to address each testing issue.
  3. Ensure that the tests adhere to the StarkNet specifications.
  4. Resolve any discrepancies or issues found during testing.
  5. Update the respective tests in the repository: Deoxys Tests.
  6. Ensure that all RPC call functionalities are working as expected and are robust against edge cases.

Resources:

Comments:
Please refer to the individual RPC call issues for detailed information on each. Team members are encouraged to comment below for coordination and to share updates on progress.

fix/block_zero

Description

There seems to be an issue with the synchronization of block zero. When setting fetch block to zero, an offset is introduced which leads to synchronization problems.

Steps to Reproduce

  1. Set fetch block to zero.
  2. Observe the synchronization offset.

Expected Behavior

Block zero should synchronize correctly without introducing any offsets.

Actual Behavior

An offset is introduced when fetch block is set to zero, causing synchronization problems.

Additional Information

This issue is related to the problem discussed here: Link to the related issue.
Please also refer to this file for more details on where the problem might lie: lib.rs at deoxys/prod.

feat/starknet_getClass

Issue: Implement starknet_getClass RPC Call

Description:
The starknet_getClass RPC call has been implemented but requires further testing and verification against the entire state. This RPC call retrieves the contract class definition in the given block associated with the provided hash.

Parameters:

  • block_id: The hash of the requested block, or number (height) of the requested block, or a block tag. This parameter is required.
  • class_hash: The hash of the requested contract class. This parameter is required.

Expected Result:
The contract class, if found. The result can be:

  1. Deprecated contract class
  2. Contract class

Potential Errors:

  • BLOCK_NOT_FOUND: The specified block could not be found.
  • CLASS_HASH_NOT_FOUND: The specified class hash could not be found.

Testing:
Initial testings can be found here. However, these should not be considered complete and improvements are welcome.

Resources:

Comments:
Please comment below for coordination.

feat/starknet_getTransactionByHash

Issue: Implement starknet_getTransactionByHash RPC Call

Description:
Get the details and status of a submitted transaction.

Parameters:

  • transaction_hash: The hash of the requested transaction. This parameter is required.

Expected Result:
The details and status of the submitted transaction, including its hash.

Potential Errors:

  • TXN_HASH_NOT_FOUND: The specified transaction hash could not be found.

Testing:
Initial testings can be found here. However, these should not be considered complete and improvements are welcome.

Resources:

Comments:
Please comment below for coordination.

feat/starknet_pendingTransactions

Issue: Implement starknet_pendingTransactions RPC Call

Description:
The starknet_pendingTransactions RPC call has been implemented but requires further testing and verification against the entire state. This RPC call returns the transactions in the transaction pool, recognized by this sequencer.

Parameters:
None.

Expected Result:
An array of pending transactions, each containing a transaction hash and other transaction details.

Testing:
Initial testings can be found here. However, these should not be considered complete and improvements are welcome.

Resources:

Comments:
Please comment below for coordination.

feat/starknet_getTransactionByBlockIdAndIndex

Issue: Implement starknet_getTransactionByBlockIdAndIndex RPC Call

Description:
Get the details of a transaction by a given block id and index. If no transaction is found, null is returned.

Parameters:

  • block_id: The hash of the requested block, or number (height) of the requested block, or a block tag. This parameter is required.
  • index: The index in the block to search for the transaction. This parameter is required.

Expected Result:
The details of the transaction given by the identified block and index in that block, including its hash.

Potential Errors:

  • BLOCK_NOT_FOUND: The specified block could not be found.
  • INVALID_TXN_INDEX: The specified transaction index in the block is invalid.

Testing:
Initial testings can be found here. However, these should not be considered complete and improvements are welcome.

Resources:

Comments:
Please comment below for coordination.

feat/tx_receipts

Issue

The block retrieval process currently does not include the transaction_receipts.

Solution

It is necessary to integrate transaction_receipts into block retrieval at this location: lib.rs#L129C9-L129C33. The required implementation for transaction_receipts is already present in this file: transactions.rs. The aim of this issue is to build the complete state via the sequencer.

Tasks

  1. Review the existing transaction_receipts implementation in transactions.rs.
  2. Integrate this implementation into block retrieval at lib.rs#L129C9-L129C33.
  3. Test and ensure that the integrity of the state with the added transaction_receipts.

feat/starknet_estimateMessageFee

Issue: Implement starknet_estimateMessageFee RPC Call

Description:
The starknet_estimateMessageFee RPC call has been implemented but requires further testing and verification against the entire state. This RPC call estimates the resources required by the l1_handler transaction induced by the message.

Parameters:

  • message: The message's parameters. This parameter is required.
  • block_id: The hash of the requested block, or number (height) of the requested block, or a block tag, for the block referencing the state or call the transaction on. This parameter is required.

Expected Result:
The fee estimation for the given message.

Potential Errors:

  • CONTRACT_NOT_FOUND: The specified contract could not be found.
  • CONTRACT_ERROR: An error occurred in the contract.
  • BLOCK_NOT_FOUND: The specified block could not be found.

Testing:
Initial testings can be found here. However, these should not be considered complete and improvements are welcome.

Resources:

Comments:
Please comment below for coordination.

feat/p2p

This is a mock issue to discuss about Deoxys current p2p implementation along with the one decided by Starknet. Sub issues should be created and linked under here.

feat/restart

Issue

Currently, blocks are fetched from the sequencer and then wrapped into substrate blocks. However, if the node is stopped and then restarted, it begins fetching the blocks from the sequencer starting from block 0. This causes a discrepancy between the block height in substrate and that of Deoxys.

Solution

We need to ensure that when Deoxys restarts, it begins from the last synced block, rather than starting all over from block 0.

At present, the starting block is hard-coded at: lib.rs#L209. Necessary modifications should be made to rectify this, while ensuring the integrity of the state remains intact.

Tasks

  1. Implement a mechanism to track and store the last synced block height.
  2. Modify the existing hard-coded value in lib.rs to make use of this stored block height.
  3. Ensure state integrity is maintained throughout this change.

feat/starknet_chainId

Issue: Implement starknet_chainId RPC Call

Description:
The starknet_chainId RPC call has been implemented but requires further testing and verification against the entire state. This RPC call returns the currently configured StarkNet chain id.

Parameters:
None.

Expected Result:
The chain id this node is connected to.

Testing:
Initial testings can be found here. However, these should not be considered complete and improvements are welcome.

Resources:

Comments:
Please comment below for coordination.

feat/starknet_getStateUpdate

Issue: Implement starknet_getStateUpdate RPC Call

Description:
Get the information about the result of executing the requested block.

Parameters:

  • block_id: The hash of the requested block, or number (height) of the requested block, or a block tag. This parameter is required.

Expected Result:
The information about the state update of the requested block. The result can be:

  1. State update
  2. Pending state update

Potential Errors:

  • BLOCK_NOT_FOUND: The block requested could not be found.

Testing:
Initial testings can be found here. However, these should not be considered complete and improvements are welcome.

Resources:

Comments:
Please comment below for coordination.

feat/starknet_getTransactionReceipt

Issue: Implement starknet_getTransactionReceipt RPC Call

Description:
The starknet_getTransactionReceipt RPC call has been implemented but requires further testing and verification against the entire state. This RPC call retrieves the transaction receipt by the transaction hash.

Parameters:

  • transaction_hash: The hash of the requested transaction. This parameter is required.

Expected Result:
The transaction receipt corresponding to the provided transaction hash.

Potential Errors:

  • TXN_HASH_NOT_FOUND: The specified transaction hash could not be found.

Testing:
Initial testings can be found here. However, these should not be considered complete and improvements are welcome.

Resources:

Comments:
Please comment below for coordination.

feat/starknet_getBlockTransactionCount

Issue: Implement starknet_getBlockTransactionCount RPC Call

Description:
The starknet_getBlockTransactionCount RPC call has been implemented but requires further testing and verification against the entire state. This RPC call retrieves the number of transactions in a block given a block id.

Parameters:

  • block_id: The hash of the requested block, or number (height) of the requested block, or a block tag. This parameter is required.

Expected Result:
The number of transactions in the designated block.

Potential Errors:

  • BLOCK_NOT_FOUND: The specified block could not be found.

Testing:
Initial testings can be found here. However, these should not be considered complete and improvements are welcome.

Resources:

Comments:
Please comment below for coordination.

RUSTSEC-2023-0052: webpki: CPU denial of service in certificate path building

webpki: CPU denial of service in certificate path building

Details
Package webpki
Version 0.21.4
Date 2023-08-22
Patched versions >=0.22.1

When this crate is given a pathological certificate chain to validate, it will
spend CPU time exponential with the number of candidate certificates at each
step of path building.

Both TLS clients and TLS servers that accept client certificate are affected.

This was previously reported in
<briansmith/webpki#69> and re-reported recently
by Luke Malinowski.

See advisory page for additional details.

feat/starknet_getEvents

Issue: Implement starknet_getEvents RPC Call

Description:
The starknet_getEvents RPC call has been implemented but requires further testing and verification against the entire state. This RPC call returns all event objects matching the conditions in the provided filter.

Parameters:

  • filter: The conditions used to filter the returned events. The filter includes both event-specific conditions and page request details.

Expected Result:
All the event objects matching the filter conditions.

Potential Errors:

  • PAGE_SIZE_TOO_BIG: The page size specified in the filter is too large.
  • INVALID_CONTINUATION_TOKEN: The continuation token provided is invalid.
  • BLOCK_NOT_FOUND: The specified block could not be found.
  • TOO_MANY_KEYS_IN_FILTER: The filter contains too many keys.

Testing:
Initial testings can be found here. However, these should not be considered complete and improvements are welcome.

Resources:

Comments:
Please comment below for coordination.

feat/starknet_addDeployAccountTransaction

Issue: Implement starknet_addDeployAccountTransaction RPC Call

Description:
The starknet_addDeployAccountTransaction RPC call has been implemented but requires further testing and verification against the entire state. This RPC call deploys an account contract from an L1 transaction.

Parameters:

  • transaction: The deploy account transaction to add. This parameter is required.

Expected Result:
The result of the transaction deployment.

Potential Errors:

  • TXN_FAILED: The transaction failed.
  • TXN_ALREADY_KNOWN: The transaction is already known.

Testing:
Initial testings can be found here. However, these should not be considered complete and improvements are welcome.

Resources:

Comments:
Please comment below for coordination.

RUSTSEC-2021-0139: ansi_term is Unmaintained

ansi_term is Unmaintained

Details
Status unmaintained
Package ansi_term
Version 0.12.1
URL ogham/rust-ansi-term#72
Date 2021-08-18

The maintainer has advised that this crate is deprecated and will not receive any maintenance.

The crate does not seem to have much dependencies and may or may not be ok to use as-is.

Last release seems to have been three years ago.

Possible Alternative(s)

The below list has not been vetted in any way and may or may not contain alternatives;

Dependency Specific Migration(s)

See advisory page for additional details.

feat/starknet_syncing

Issue: Implement starknet_syncing RPC Call

Description:
The starknet_syncing RPC call has been implemented but requires further testing and verification against the entire state. This RPC call returns an object about the sync status, or false if the node is not syncing.

Parameters:
None.

Expected Result:
The state of the synchronization, or false if the node is not synchronizing. The status can either be FALSE or a Sync status object.

Testing:
Initial testings can be found here. However, these should not be considered complete and improvements are welcome.

Resources:

Comments:
Please comment below for coordination.

feat/starknet_blockNumber

Issue: Implement starknet_blockNumber RPC Call

Description:
The starknet_blockNumber RPC call has been implemented but requires further testing and verification against the entire state. This RPC call retrieves the most recent accepted block number.

Parameters:
None.

Expected Result:
The latest block number.

Potential Errors:

  • NO_BLOCKS: No blocks were found.

Testing:
Initial testings can be found here. However, these should not be considered complete and improvements are welcome.

Resources:

Comments:
Please comment below for coordination.

feat/rpc_port

Add rpc port default value if not referenced + optimize rpc implementation

feat/starknet_estimateFee

Issue: Implement starknet_estimateFee RPC Call

Description:
The starknet_estimateFee RPC call has been implemented but requires further testing and verification against the entire state. This RPC call estimates the resources required by transactions when applied on a given state.

Parameters:

  • request: The transaction(s) to estimate. This is a sequence of transactions to estimate, running each transaction on the state resulting from applying all the previous ones. This parameter is required.
  • block_id: The hash of the requested block, or number (height) of the requested block, or a block tag, for the block referencing the state or call the transaction on. This parameter is required.

Expected Result:
A sequence of fee estimations where the i'th estimate corresponds to the i'th transaction.

Potential Errors:

  • CONTRACT_NOT_FOUND: The specified contract could not be found.
  • CONTRACT_ERROR: An error occurred in the contract.
  • BLOCK_NOT_FOUND: The specified block could not be found.

Testing:
Initial testings can be found here. However, these should not be considered complete and improvements are welcome.

Resources:

Comments:
Please comment below for coordination.

RUSTSEC-2020-0168: mach is unmaintained

mach is unmaintained

Details
Status unmaintained
Package mach
Version 0.3.2
URL fitzgen/mach#63
Date 2020-07-14

Last release was almost 4 years ago.

Maintainer(s) seem to be completely unreachable.

Possible Alternative(s)

These may or may not be suitable alternatives and have not been vetted in any way;

See advisory page for additional details.

feat: dev tests rpc

Provide testings for Starknet RPC compatibility comparing outputs with regular RPC
Please use the following branch https://github.com/KasarLabs/deoxys/tree/deoxys/tests_rpc to continue the work done here:
https://github.com/KasarLabs/deoxys/blob/deoxys/tests_rpc/tests/tests/tests-deoxys/deoxys_rpc.ts

Implement the following:

starknet_getBlockWithTxHashes
starknet_getBlockWithTxs
starknet_getStateUpdate
starknet_getStorageAt
starknet_getTransactionByHash
starknet_getTransactionByBlockIdAndIndex
starknet_getTransactionReceipt
starknet_getClass
starknet_getClassHashAt
starknet_getClassAt
starknet_getBlockTransactionCount
starknet_call
starknet_estimateFee
starknet_estimateMessageFee
starknet_blockNumber
starknet_blockHashAndNumber
starknet_chainId
starknet_pendingTransactions
starknet_syncing
starknet_getEvents
starknet_getNonce
starknet_estimateMessageFee
starknet_addDeclareTransaction
starknet_addDeployAccountTransaction
starknet_addInvokeTransaction

You may use https://docs.alchemy.com/reference/starknet-api-endpoints for help
You should have a Deoxys node running with rpc port exposed

feat/networks

Description

We need to implement support for three distinct launch modes, specifically: integration, mainnet, and testnet. These modes should be triggerable via the --testnet, --mainnet, and --integration arguments, respectively.

Details

Using these arguments should alter the sequencer endpoint utilized to synchronize blocks:

Location

The integration should be done in the following file: crates/node/src/cli.rs.

Moreover, it's necessary to tidy up what has been already implemented in lib.rs by moving it to a new client.rs file within the same Deoxys directory.

Tasks

  1. Add support for --testnet, --mainnet, and --integration arguments in cli.rs.
  2. Modify the sequencer endpoints based on the provided argument.
  3. Shift the relevant code from lib.rs to a new client.rs file.

RUSTSEC-2021-0060: `aes-soft` has been merged into the `aes` crate

aes-soft has been merged into the aes crate

Details
Status unmaintained
Package aes-soft
Version 0.6.4
URL RustCrypto/block-ciphers#200
Date 2021-04-29

Please use the aes crate going forward. The new repository location is at:

<https://github.com/RustCrypto/block-ciphers/tree/master/aes>

AES-NI is now autodetected at runtime on i686/x86-64 platforms.
If AES-NI is not present, the aes crate will fallback to a constant-time
portable software implementation.

To force the use of a constant-time portable implementation on these platforms,
even if AES-NI is available, use the new force-soft feature of the aes
crate to disable autodetection.

See advisory page for additional details.

RUSTSEC-2022-0093: Double Public Key Signing Function Oracle Attack on `ed25519-dalek`

Double Public Key Signing Function Oracle Attack on ed25519-dalek

Details
Package ed25519-dalek
Version 1.0.1
URL https://github.com/MystenLabs/ed25519-unsafe-libs
Date 2022-06-11
Patched versions >=2

Versions of ed25519-dalek prior to v2.0 model private and public keys as
separate types which can be assembled into a Keypair, and also provide APIs
for serializing and deserializing 64-byte private/public keypairs.

Such APIs and serializations are inherently unsafe as the public key is one of
the inputs used in the deterministic computation of the S part of the signature,
but not in the R value. An adversary could somehow use the signing function as
an oracle that allows arbitrary public keys as input can obtain two signatures
for the same message sharing the same R and only differ on the S part.

Unfortunately, when this happens, one can easily extract the private key.

Revised public APIs in v2.0 of ed25519-dalek do NOT allow a decoupled
private/public keypair as signing input, except as part of specially labeled
"hazmat" APIs which are clearly labeled as being dangerous if misused.

See advisory page for additional details.

feat/starknet_getBlockWithTxHashes

Issue: Implement starknet_getBlockWithTxHashes RPC Call

Description:
The starknet_getBlockWithTxHashes RPC call has been implemented but requires further testing and verification against the entire state. This RPC call retrieves block information with transaction hashes given the block id.

Parameters:

  • block_id: The hash of the requested block, or number (height) of the requested block, or a block tag. This parameter is required.

Expected Result:
The resulting block information with transaction hashes. The result can be of two types:

  1. Block with transaction hashes
  2. Pending block with transaction hashes

Potential Errors:

  • BLOCK_NOT_FOUND: The block requested could not be found.

Testing:
Initial testings can be found here. However, these should not be considered complete and improvements are welcome.

Resources:

Comments:
Please comment below for coordination.

feat/fix_txs

Issue

The work in the transaction.rs file appears to be incomplete and requires further development to ensure functionality, stability and full state parity

Solution

We need to revisit transaction.rs and finalize the pending implementations or any functions that are left half-implemented.

Tasks

  1. Review the existing code in transaction.rs to identify incomplete or suboptimal areas.
  2. Finalize any methods or functionalities that are left pending.
  3. Conduct tests to ensure that the updates to transaction.rs function as intended without introducing new issues.
  4. Document any significant changes or additions for clarity and future reference.

Please prioritize this issue, as completing the transaction.rs file is essential for the stability and overall functionality of our project.

feat/starknet_getBlockWithTxs

Issue: Implement starknet_getBlockWithTxs RPC Call

Description:
Get block information with full transactions given the block id.

Parameters:

  • block_id: The hash of the requested block, or number (height) of the requested block, or a block tag. This parameter is required.

Expected Result:
The resulting block information with full transactions. The result can be:

  1. Block with transactions
  2. Pending block with transactions

Potential Errors:

  • BLOCK_NOT_FOUND: The block requested could not be found.

Testing:
Initial testings can be found here. However, these should not be considered complete and improvements are welcome.

Resources:

Comments:
Please comment below for coordination.

feat/starknet_blockHashAndNumber

Issue: Implement starknet_blockHashAndNumber RPC Call

Description:
The starknet_blockHashAndNumber RPC call has been implemented but requires further testing and verification against the entire state. This RPC call retrieves the most recent accepted block hash and number.

Parameters:
None.

Expected Result:
The latest block hash and number.

Potential Errors:

  • NO_BLOCKS: No blocks were found.

Testing:
Initial testings can be found here. However, these should not be considered complete and improvements are welcome.

Resources:

Comments:
Please comment below for coordination.

feat/starknet_addDeclareTransaction

Issue: Implement starknet_addDeclareTransaction RPC Call

Description:
The starknet_addDeclareTransaction RPC call has been implemented but requires further testing and verification against the entire state. This RPC call declares a transaction by submitting its hash.

Parameters:

  • transaction_hash: The hash of the transaction to declare. This parameter is required.

Expected Result:
The result of the declaration.

Potential Errors:

  • TXN_HASH_NOT_FOUND: The specified transaction hash could not be found.
  • TXN_ALREADY_DECLARED: The transaction is already declared.

Testing:
Initial testings can be found here. However, these should not be considered complete and improvements are welcome.

Resources:

Comments:
Please comment below for coordination.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.