api

package
v1.0.13 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 18, 2023 License: GPL-3.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

View Source
const TimeoutSafetyFactor int = 2

The fraction of the timeout period to trigger overdue transactions

Variables

This section is empty.

Functions

func IsTransactionDue

func IsTransactionDue(rp *rocketpool.RocketPool, startTime time.Time) (bool, time.Duration, error)

True if a transaction is due and needs to bypass the gas threshold

func PrintAndCheckGasInfo

func PrintAndCheckGasInfo(gasInfo rocketpool.GasInfo, checkThreshold bool, gasThresholdGwei float64, logger log.ColorLogger, maxFeeWei *big.Int, gasLimit uint64) bool

Print the gas price and cost of a TX

func PrintAndWaitForTransaction

func PrintAndWaitForTransaction(cfg *config.RocketPoolConfig, hash common.Hash, ec rocketpool.ExecutionClient, logger log.ColorLogger) error

Print a TX's details to the logger and waits for it to validated.

func PrintErrorResponse

func PrintErrorResponse(err error)

Print an API error response

func PrintResponse

func PrintResponse(response interface{}, responseError error)

Print an API response response must be a pointer to a struct type with Error and Status string fields

func ZeroIfNil

func ZeroIfNil(in **big.Int)

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL