Overview
The purpose of this document is to define initial recommendation for the operating procedures for running the wrapping operations, which is planned to be conducted by a decentralized group of oracles and custodians, who are also FIO Chain Block Producers. This document is not intended to describe the detailed functionality of the FIO contracts, Polygon contracts or the Oracle software. See References below for that information.
...
Oracles will need to set environment variables as defined in the fio.oracle README: https://github.com/fioprotocol/fio.oracle
If the .env file is updated, the oracle service must be restarted to pull in the latest values.
Manual oracle transactions
...
A command line script is included in the fio.oracle repository that enables manual wrapping and unwrapping of tokens and domains.
The manual scripts must be run on the server where the oracle is running. It uses the oracle functionality to execute the transactions. Success and error information will be logged in the usual oracle log files.
From the fio.oracle root directory:
Code Block |
---|
> npm run oracle This returns the usage: Usage: npm run oracle ['wrap'|'unwrap'] ['tokens'|'domain'] [amount|domain] [fio handle or eth address] trxid Examples: npm run oracle wrap tokens 12000000000 0xe28FF0D44d533d15cD1f811f4DE8e6b1549945c9 ec52a13e3fd60c1a06ad3d9c0d66b97144aa020426d91cc43565483c743dd320 npm run oracle wrap domain fiohacker 0xe28FF0D44d533d15cD1f811f4DE8e6b1549945c9 ec52a13e3fd60c1a06ad3d9c0d66b97144aa020426d91cc43565483c743dd320 npm run oracle unwrap tokens 12000000000 alice@fiotestnet ec52a13e3fd60c1a06ad3d9c0d66b97144aa020426d91cc43565483c743dd320 npm run oracle unwrap domain fiohacker alice@fiotestnet ec52a13e3fd60c1a06ad3d9c0d66b97144aa020426d91cc43565483c743dd320 |
Requests for manual transactions should be posted to the FIO Token Wrapping Committee Telegram channel.
Setting oracle fees
Code Block |
---|
clio -u http://fiotestnet.blockpane.com push action fio.oracle setoraclefee '{ "wrap_fio_domain": 60000000000, "wrap_fio_tokens": 50000000000, "actor": "qbxn5zhw2ypw" }' -p qbxn5zhw2ypw@active |
...
Errors on FIO Chain. If user receives errors on the FIO Chain, FIO Domain will not be transferred, so no customer service issue exists.
Possible mitigation:
Oracles investigate issue.
If unwraps are working but wraps are not, it usually means there is a problem with getting wrap transactions from the Oracle’s history node. Check if any changes have been made to their FIO node infrastructure and confirm the server tied to the
FIO_SERVER_URL_HISTORY
param is correct.
Errors on Polygon Chain. If the Oracle experiences an error when trying to record an observation onto the Polygon Chain using wrap action, it means that the user has sent FIO Domian, but did not receive the ERC-721 token, creating a customer service issue. Oracles should monitor their nodes to look for errors.
Possible mitigation:
Preferred: Fix and manually resubmit the wrap transaction to the Polygon chain to ensure the ERC-721 token is delivered to target user.
Alternatively, Oracles can unwrap FIO Domain on FIO Chain using unwrapdomain action. This effectively returns the user’s FIO Domain which failed to wrap.
fio_address - use FIO Address owned by account which initiated the wrap
obt_id - manually set, e.g. 20210604001ReturnDueToFailure - this has to be globally unique and Oracles have to coordinate to all use the same obt_id.
...