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 Web3 = require('web3'); | |
const web3 = new Web3(new Web3.providers.WebsocketProvider(process.env.ENDPOINT)); | |
const transferSignature = Web3.utils.keccak256("Transfer(address,address,uint256)"); | |
// Listen for Transfer events from all contracts | |
web3.eth.subscribe('logs', { | |
topics: [transferSignature] | |
}, (error, event) => { | |
if (error) { |
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
from telethon import TelegramClient, events, sync | |
import numpy as np | |
import asyncio | |
import random | |
from telethon.tl.functions.account import UpdateProfileRequest | |
from telethon.tl.functions.messages import SendReactionRequest | |
from telethon.tl.types import IpPort, ReactionEmoji | |
import torch | |
import os | |
import sys |
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
{ | |
"minimum-stability":"dev", | |
"autoload": { | |
"psr-4": { | |
"Ethereum\\": "src/" | |
} | |
}, | |
"repositories": [ | |
{ | |
"type": "git", |
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
/* | |
_// _// _// | |
_// _// _// _// | |
_// _// _/_/ _/ _// _/// _// _//_// _//_/ _// _//// _// | |
_// _// _// _// _// _// _// _// _// _// _// _// _/ _// _// _/ _// | |
_// _// _// _// _// _//_// _// _// _// _/// _/ _// _/// _///// _// | |
_// _//_// _// _// _// _// _// _// _// _// _// _// _// _//_/ | |
_//// _// _/// _// _// _/// _// _///_/// _// _// _// _// _//// | |
_// _// |
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
struct Foo { | |
value: String, | |
} | |
impl Foo { | |
#[cfg(not(target_os = "macos"))] | |
fn xxx(&mut self) { | |
self.value.push_str(".not macOS.") | |
} |
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.0; | |
interface IERC20 { | |
function totalSupply() external view returns (uint256); | |
function balanceOf(address account) external view returns (uint256); | |
function allowance(address owner, address spender) external view returns (uint256); | |
function transfer(address recipient, uint256 amount) external returns (bool); | |
function approve(address spender, uint256 amount) external returns (bool); |
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
[package] | |
name = "lola-nft" | |
version = "0.1.4" | |
authors = ["Nikita Kuznetsov <[email protected]>"] | |
edition = "2018" | |
[dependencies] | |
near-sdk = "4.0.0" | |
# near-sdk-sim = "4.0.0-pre.9" | |
near-contract-standards = "4.0.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
running 1 test | |
test test_claim ... ok | |
test result: ok. 1 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 23.04s | |
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
import os | |
import tornado.ioloop | |
import tornado.web | |
from eth_account.messages import encode_defunct | |
from eth_account.account import Account | |
PRIVATE_KEY = os.environ.get("PRIVATE_KEY") | |
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
#!/usr/bin/env python | |
import sys | |
import csv | |
import typing | |
import requests | |
all_owners: typing.List[str] = [] | |
contract_id = None |