Skip to content

Commit

Permalink
Remove temporary comments (#569)
Browse files Browse the repository at this point in the history
* fix: remove temporary comments

* fix: update comments

* fix: update comments

---------

Co-authored-by: Rodolfo Pietro Calabrò <[email protected]>
  • Loading branch information
fabiorigam and rodolfopietro97 authored Feb 15, 2024
1 parent 71c6136 commit bafa919
Show file tree
Hide file tree
Showing 4 changed files with 1 addition and 47 deletions.
26 changes: 1 addition & 25 deletions packages/provider/src/providers/types.d.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
import { type vechain_sdk_core_ethers } from '@vechain/vechain-sdk-core';

/**
* Represents the parameters for a subscription.
* This interface includes all necessary details for managing a subscription.
Expand Down Expand Up @@ -106,26 +104,4 @@ interface SubscriptionManager {
currentBlockNumber: number;
}

/**
* An `EventEmitterable` interface is akin to an EventEmitter,
* but with asynchronous access to its methods.
*
* It follows the observer pattern, facilitating event-driven programming.
*
* ----- TEMPORARY COMMENT -----
* These methods will be implemented by the abstract provider.
* Each subscribe type will be handled by a dedicated subscriber class (e.g, PollingBlockSubscriber, PollingEventSubscriber (polls an event for its logs), etc.)
*
* See hardhat-ethers-plugin and ethers implementations for more details.
*
* https://github.com/ethers-io/ethers.js/blob/6ee1a5f8bb38ec31fa84c00aae7f091e1d3d6837/src.ts/utils/events.ts#L21
* -----------------------------
*/
type EventEmitterable<T> = vechain_sdk_core_ethers.EventEmitterable<T>;

export {
type EventEmitterable,
type SubscriptionEvent,
type SubscriptionManager,
type FilterOptions
};
export { type SubscriptionEvent, type SubscriptionManager, type FilterOptions };
16 changes: 0 additions & 16 deletions packages/provider/src/utils/const/rpc-mapper/rpc-methods.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,10 @@
*/
enum RPC_METHODS {
/**
* ----- TEMPORARY COMMENT -----
* STATUS:
* * Implemented in web3-providers-connex: True
* * Required for hardhat: True -> @see https://github.com/vechain/vechain-sdk/issues/462
* * Possible to implement: True (Already implemented in web3-providers-connex)
*
* @PRIORITY: HIGH
* -----------------------------
*/
eth_blockNumber = 'eth_blockNumber',
eth_chainId = 'eth_chainId',
Expand All @@ -31,14 +27,10 @@ enum RPC_METHODS {
eth_requestAccounts = 'eth_requestAccounts',

/**
* ----- TEMPORARY COMMENT -----
* STATUS:
* * Implemented in web3-providers-connex: True
* * Required for hardhat: False (BUT WE MUST INVESTIGATE BETTER) -> @see https://github.com/vechain/vechain-sdk/issues/462
* * Possible to implement: True (Already implemented in web3-providers-connex)
*
* @PRIORITY: HIGH
* -----------------------------
*/
eth_gasPrice = 'eth_gasPrice',
eth_getTransactionByHash = 'eth_getTransactionByHash',
Expand All @@ -55,14 +47,10 @@ enum RPC_METHODS {
evm_mine = 'evm_mine',

/**
* ----- TEMPORARY COMMENT -----
* STATUS:
* * Implemented in web3-providers-connex: False (ONLY LISTED `EthJsonRpcMethods`array in `src/common.ts` file)
* * Required for hardhat: False -> @see https://github.com/vechain/vechain-sdk/issues/462
* * Possible to implement: TO UNDERSTAND
*
* @PRIORITY: MEDIUM (SEE AFTER FIRST TWO BLOCKS OF FUNCTIONS)
* -----------------------------
*/
eth_coinbase = 'eth_coinbase',
eth_feeHistory = 'eth_feeHistory',
Expand Down Expand Up @@ -91,16 +79,12 @@ enum RPC_METHODS {
eth_uninstallFilter = 'eth_uninstallFilter',

/**
* ----- TEMPORARY COMMENT -----
* STATUS:
* * Implemented in web3-providers-connex: False (AND NOT LISTED in `EthJsonRpcMethods`array in `src/common.ts` file. Probably NEW methods)
* * Required for hardhat: False (BUT WE MUST INVESTIGATE IT BETTER) -> @see https://github.com/vechain/vechain-sdk/issues/462
* * Possible to implement: TO UNDERSTAND
*
* @note: These methods are taken from https://ethereum.github.io/execution-apis/api-documentation/
*
* @PRIORITY: LOW (Probably not needed)
* -----------------------------
*/
debug_getBadBlocks = 'debug_getBadBlocks',
debug_getRawBlock = 'debug_getRawBlock',
Expand Down
4 changes: 0 additions & 4 deletions packages/wallet/src/wallets/base-wallet/types.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,8 @@ interface WalletAccount {
publicKey: Buffer;

/**
* ----- TEMPORARY COMMENT -----
* Here we can add all useful methods for WalletAccount.
* Currently, private key and public key are used by provider.
* -----------------------------
*/
// ... e.g. fromPrivateKey(privateKey), fromPublicKey(publicKey), ...
}
Expand Down Expand Up @@ -73,10 +71,8 @@ interface Wallet {
getDelegator: () => Promise<SignTransactionOptions | null>;

/**
* ----- TEMPORARY COMMENT -----
* Here we can add all useful methods wor wallet.
* Currently, we have only getAddresses (needed by provider)
* -----------------------------
*/
// ... e.g. addAccount, removeAccount, ...
}
Expand Down
2 changes: 0 additions & 2 deletions packages/wallet/src/wallets/hd-wallet/types.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,8 @@ interface HDWallet extends Wallet {
derivationPath: string;

/**
* ----- TEMPORARY COMMENT -----
* Here we can add all useful methods for HDWallet.
* This CURRENTLY is only an example.
* -----------------------------
*/
// ... e.g. fromMnemonic
}
Expand Down

1 comment on commit bafa919

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Test Coverage

Summary

Lines Statements Branches Functions
Coverage: 100%
100% (2520/2520) 100% (526/526) 100% (528/528)
Title Tests Skipped Failures Errors Time
core 409 0 💤 0 ❌ 0 🔥 1m 11s ⏱️
network 234 0 💤 0 ❌ 0 🔥 2m 29s ⏱️
errors 43 0 💤 0 ❌ 0 🔥 9.716s ⏱️

Please sign in to comment.