From 8faf83aac2242a56ee270ade84cbe4d529ae3d9f Mon Sep 17 00:00:00 2001 From: realisation Date: Tue, 24 Oct 2023 14:54:24 -0400 Subject: [PATCH] removed QNSRegistry.json and abigen from main.rs as networking information validation was moved entirely into the register app --- src/QNSRegistry.json | 429 ------------------------------------------- src/main.rs | 4 +- 2 files changed, 1 insertion(+), 432 deletions(-) delete mode 100644 src/QNSRegistry.json diff --git a/src/QNSRegistry.json b/src/QNSRegistry.json deleted file mode 100644 index ab491902..00000000 --- a/src/QNSRegistry.json +++ /dev/null @@ -1,429 +0,0 @@ -[ - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "address", - "name": "previousAdmin", - "type": "address" - }, - { - "indexed": false, - "internalType": "address", - "name": "newAdmin", - "type": "address" - } - ], - "name": "AdminChanged", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "beacon", - "type": "address" - } - ], - "name": "BeaconUpgraded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "uint8", - "name": "version", - "type": "uint8" - } - ], - "name": "Initialized", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "node", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "bytes", - "name": "name", - "type": "bytes" - }, - { - "indexed": false, - "internalType": "address", - "name": "nft", - "type": "address" - } - ], - "name": "NewSubdomainContract", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "node", - "type": "uint256" - }, - { - "indexed": false, - "internalType": "bytes", - "name": "name", - "type": "bytes" - } - ], - "name": "NodeRegistered", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "previousOwner", - "type": "address" - }, - { - "indexed": true, - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "OwnershipTransferred", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "implementation", - "type": "address" - } - ], - "name": "Upgraded", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "uint256", - "name": "node", - "type": "uint256" - }, - { - "indexed": true, - "internalType": "uint96", - "name": "protocols", - "type": "uint96" - }, - { - "indexed": false, - "internalType": "bytes32", - "name": "publicKey", - "type": "bytes32" - }, - { - "indexed": false, - "internalType": "uint32", - "name": "ip", - "type": "uint32" - }, - { - "indexed": false, - "internalType": "uint16", - "name": "port", - "type": "uint16" - }, - { - "indexed": false, - "internalType": "bytes32[]", - "name": "routers", - "type": "bytes32[]" - } - ], - "name": "WsChanged", - "type": "event" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "node", - "type": "uint256" - }, - { - "internalType": "uint32", - "name": "protocols", - "type": "uint32" - } - ], - "name": "clearProtocols", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "getInitializedVersion", - "outputs": [ - { - "internalType": "uint8", - "name": "", - "type": "uint8" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "initialize", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "owner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "proxiableUUID", - "outputs": [ - { - "internalType": "bytes32", - "name": "", - "type": "bytes32" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "name": "records", - "outputs": [ - { - "internalType": "address", - "name": "owner", - "type": "address" - }, - { - "internalType": "uint96", - "name": "protocols", - "type": "uint96" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes", - "name": "fqdn", - "type": "bytes" - } - ], - "name": "registerNode", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes", - "name": "fqdn", - "type": "bytes" - }, - { - "internalType": "contract IQNSNFT", - "name": "nft", - "type": "address" - } - ], - "name": "registerSubdomainContract", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [], - "name": "renounceOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "node", - "type": "uint256" - }, - { - "internalType": "bytes32", - "name": "publicKey", - "type": "bytes32" - }, - { - "internalType": "uint32", - "name": "ip", - "type": "uint32" - }, - { - "internalType": "uint16", - "name": "port", - "type": "uint16" - }, - { - "internalType": "bytes32[]", - "name": "routers", - "type": "bytes32[]" - } - ], - "name": "setWsRecord", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes4", - "name": "interfaceID", - "type": "bytes4" - } - ], - "name": "supportsInterface", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newOwner", - "type": "address" - } - ], - "name": "transferOwnership", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newImplementation", - "type": "address" - } - ], - "name": "upgradeTo", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "newImplementation", - "type": "address" - }, - { - "internalType": "bytes", - "name": "data", - "type": "bytes" - } - ], - "name": "upgradeToAndCall", - "outputs": [], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "node", - "type": "uint256" - } - ], - "name": "ws", - "outputs": [ - { - "components": [ - { - "internalType": "bytes32", - "name": "publicKey", - "type": "bytes32" - }, - { - "internalType": "uint32", - "name": "ip", - "type": "uint32" - }, - { - "internalType": "uint16", - "name": "port", - "type": "uint16" - }, - { - "internalType": "bytes32[]", - "name": "routers", - "type": "bytes32[]" - } - ], - "internalType": "struct IQNS.WsRecord", - "name": "", - "type": "tuple" - } - ], - "stateMutability": "view", - "type": "function" - } -] \ No newline at end of file diff --git a/src/main.rs b/src/main.rs index d422c487..deac24c9 100644 --- a/src/main.rs +++ b/src/main.rs @@ -1,6 +1,6 @@ use anyhow::Result; use dotenv; -use ethers::prelude::{abigen, namehash}; +use ethers::prelude::{namehash}; use std::env; use std::sync::Arc; use tokio::sync::{mpsc, oneshot}; @@ -37,8 +37,6 @@ const CAP_CHANNEL_CAPACITY: usize = 1_000; const VERSION: &str = env!("CARGO_PKG_VERSION"); -abigen!(QNSRegistry, "src/QNSRegistry.json"); - #[tokio::main] async fn main() { // For use with https://github.com/tokio-rs/console