wallet: introduce namedtuples TxMinedStatus and VerifiedTxInfo
This commit is contained in:
@@ -23,6 +23,7 @@
|
||||
import binascii
|
||||
import os, sys, re, json
|
||||
from collections import defaultdict
|
||||
from typing import NamedTuple
|
||||
from datetime import datetime
|
||||
import decimal
|
||||
from decimal import Decimal
|
||||
@@ -903,3 +904,13 @@ def make_dir(path, allow_symlink=True):
|
||||
raise Exception('Dangling link: ' + path)
|
||||
os.mkdir(path)
|
||||
os.chmod(path, stat.S_IRUSR | stat.S_IWUSR | stat.S_IXUSR)
|
||||
|
||||
|
||||
TxMinedStatus = NamedTuple("TxMinedStatus", [("height", int),
|
||||
("conf", int),
|
||||
("timestamp", int),
|
||||
("header_hash", str)])
|
||||
VerifiedTxInfo = NamedTuple("VerifiedTxInfo", [("height", int),
|
||||
("timestamp", int),
|
||||
("txpos", int),
|
||||
("header_hash", str)])
|
||||
|
||||
Reference in New Issue
Block a user