This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- show running queries (pre 9.2) | |
SELECT procpid, age(clock_timestamp(), query_start), usename, current_query | |
FROM pg_stat_activity | |
WHERE current_query != '<IDLE>' AND current_query NOT ILIKE '%pg_stat_activity%' | |
ORDER BY query_start desc; | |
-- show running queries (9.2) | |
SELECT pid, age(clock_timestamp(), query_start), usename, query | |
FROM pg_stat_activity | |
WHERE query != '<IDLE>' AND query NOT ILIKE '%pg_stat_activity%' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Docker-in-Docker Gitlab runners setup taken from: | |
# https://medium.com/@tonywooster/docker-in-docker-in-gitlab-runners-220caeb708ca | |
dind: | |
restart: always | |
privileged: true | |
volumes: | |
- /var/lib/docker | |
image: docker:17.09.0-ce-dind | |
command: | |
- --storage-driver=overlay2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Random Value : ok | |
Compare XOR : ok | |
Compare SUB : ok | |
Compare MUL : ok | |
Compare DIV : ok | |
Compare OR : ok | |
Compare AND : ok | |
Sequential Increment: ok | |
Solid Bits : ok | |
Block Sequential : ok |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FAILURE: 0x76ffa13a12f7ec54 != 0x76ffa13a12f5ec54 at offset 0xa1d1b230. | |
FAILURE: 0x76ffa13a12f7ec55 != 0x76ffa13a12c7ec55 at offset 0xa1d1b238. | |
FAILURE: 0x76ffa13a12f7ec57 != 0x76ffa13a12ffec57 at offset 0xa1d1b248. | |
FAILURE: 0x76ffa13a12f7ec59 != 0x76ffa13a12e6ec59 at offset 0xa1d1b258. | |
FAILURE: 0x76ffa13a12f7ec5b != 0x76ffa13a12faec5b at offset 0xa1d1b268. | |
FAILURE: 0x76ffa13a12f7ec5d != 0x76ffa13a1267ec5d at offset 0xa1d1b278. | |
FAILURE: 0x76ffa13a12f7ec5f != 0x76ffa13a12dfec5f at offset 0xa1d1b288. | |
FAILURE: 0x76ffa13a12f7ec60 != 0x76ffa13a12f5ec60 at offset 0xa1d1b290. | |
FAILURE: 0x76ffa13a12f7ec61 != 0x76ffa13a1266ec61 at offset 0xa1d1b298. | |
FAILURE: 0x76ffa13a12f7ec62 != 0x76ffa13a12f5ec62 at offset 0xa1d1b2a0. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
memtester version 4.5.1 (64-bit) | |
Copyright (C) 2001-2020 Charles Cazabon. | |
Licensed under the GNU General Public License version 2 (only). | |
pagesize is 4096 | |
pagesizemask is 0xfffffffffffff000 | |
want 24576MB (25769803776 bytes) | |
got 24576MB (25769803776 bytes), trying mlock ...locked. | |
Loop 1/5: | |
Stuck Address : ok |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const { revertReason } = await ethers.provider.send('eth_getTransactionReceipt', [error.transaction.hash]) | |
const output = revertReason.slice(2) | |
const strLen = parseInt(output.slice(8 + 64, 8 + 128), 16) | |
const reason = ethers.utils.toUtf8String('0x' + output.slice(8 + 128, 8 + 128 + (strLen * 2))) | |
console.log('🚀 ~ reason', reason) | |
console.log('with abi decoder', ethers.utils.defaultAbiCoder.decode(['string'], ethers.utils.hexDataSlice(revertReason, 4))[0]) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pragma solidity ^0.8.14; | |
// SPDX-License-Identifier: GPL-3.0 | |
pragma experimental ABIEncoderV2; | |
contract Money { | |
struct People{ | |
uint id; | |
string name; | |
uint amount; | |
} | |
mapping (uint => People) public peoples; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// SPDX-License-Identifier: GPL-3.0 | |
pragma solidity >=0.7.0 <0.9.0; | |
import "https://github.com/OpenZeppelin/openzeppelin-contracts/blob/master/contracts/utils/math/SafeMath.sol"; | |
abstract contract AUSD { | |
/** | |
* @dev Returns the cost of withdraw | |
* @param sig is the withdraw method signature |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Sources flattened with hardhat v2.6.0 https://hardhat.org | |
// File contracts/IEarn.sol | |
pragma solidity ^0.8.0; | |
/** | |
* @title IEarn interface | |
* @dev Interface only available with stake and unstake methods used in FactoryEarnDepositRelayer |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// File: https://github.com/OpenZeppelin/openzeppelin-contracts/blob/master/contracts/utils/Context.sol | |
// OpenZeppelin Contracts v4.4.1 (utils/Context.sol) | |
pragma solidity ^0.8.0; | |
/** | |
* @dev Provides information about the current execution context, including the |