### Deploying Graph Network Subgraph to Personal Account for Testing (Shell) Source: https://github.com/graphprotocol/graph-network-subgraph/blob/master/README.md Command to deploy the Graph Network Subgraph to a personal explorer account for testing purposes. Requires replacing placeholders with the user's subgraph name and the target network (mainnet or rinkeby). ```Shell yarn deploy-testing ``` -------------------------------- ### Deploying Graph Network Subgraph to Mainnet Staging (Shell) Source: https://github.com/graphprotocol/graph-network-subgraph/blob/master/README.md Command to deploy the Graph Network Subgraph to the mainnet staging environment using yarn. This is used for testing updates before merging to master. ```Shell yarn deploy-mainnet-staging ``` -------------------------------- ### Converting Parts Per Million (ppm) to Percentage - Mathematical Source: https://github.com/graphprotocol/graph-network-subgraph/blob/master/DOCUMENTATION.md Shows how to convert a value stored in Parts Per Million (ppm), a common unit in the subgraph due to EVM limitations, into a standard percentage by dividing the ppm value by 1,000,000. ```mathematical protocolPercentage = 10,000 // value from the subgraph normalizedProtocolPercentage = 10,000 / 1,000,000 = 0.01 = 1% ``` -------------------------------- ### Calculating Network Issuance Rate (Pre-GIP-0037) - Mathematical Source: https://github.com/graphprotocol/graph-network-subgraph/blob/master/DOCUMENTATION.md Illustrates the mathematical formula used to calculate the annual network issuance rate from the `networkGRTIssuance` field before GIP-0037. This field represented compound interest per block, requiring exponentiation over the number of blocks per year to find the annual rate. ```mathematical normalizedIssuanceRate = (networkGRTIssuance * 10^-18)^(blocksPerYear) networkGRTIssuance = 1000000012184945188 // value from the subgraph blocksPerYear = (365*60*60*24)/13 = 2425846.15 // A year in seconds, divided by Ethereum block time, ~13 seconds networkIssuanceRate = 1.000000012184945188^(2425846.15) networkIssuanceRate = 1.03 ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.