js-sdk
js-sdk copied to clipboard
Feature/lit 3744 js sdk from slack use getg active unkicked validator struct and counts 2
Description
Merge multiple connection to a RPC call
- feat(contracts-sdk): introduce
getConnectionInfo
public static function, that calls thegetActiveUnkickedValidatorStructsAndCounts
smart contract function to getepoch
,minNodeCount
andactiveUnkickedValidatorStructs
- feat(lit-core): refactor
_getValidatorData
to usegetConnectionInfo
from the contracts-sdk, which will be used in the initial_connect
function, to set the stakingContract (to be re-used in other code), minNodeCount, and bootstrapUrls. - in the initial connection,
fetchCurrentEpochState
is now non-async (need confirmation that it's ok. See here)
Test
- Running local nodes from this PR https://github.com/LIT-Protocol/lit-assets/pull/1372 and ran
NETWORK=localchain yarn test:local --filter=testUseEoaSessionSigsToExecuteJsSigning --exclude=Parallel