官网:https://clemcer.github.io/loggifly/
github: https://github.com/henrygd/beszel
您正在查看: Surou 发布的文章
以导入方式新增WSL Ubuntu
下载镜像
使用7z 解压
你可以保留 .tar.gz 直接导入,或先解压为 .tar
注销原有系统
wsl --unregister Ubuntu-24.04
导入
wsl --import Ubuntu-24.04 D:\Linux\Ubuntu-24.04 ubuntu-noble-wsl-amd64-24.04lts.rootfs.tar
启动并设置 WSL
wsl -d Ubuntu-24.04
首次启动会进入 root shell。
建议添加一个用户
adduser surou
usermod -aG sudo surou
回到 PowerShell,设置默认用户
wsl -d Ubuntu-24.04 -u surouSolana 开源内部监控
最全面的开源工具,用于监控 Solana 钱包活动、检测余额变化、跟踪潜在内幕交易以及接收 SOL 和所有 SPL 代币的实时警报。
https://accursedgalaxy.github.io/Insider-Monitor/
https://github.com/AccursedGalaxy/Insider-Monitor
doesn't look like an ERC 1967 proxy with a logic contract addres
背景
使用 upgrades.erc1967.getImplementationAddress 来获取通过 upgrades.deployProxy 部署的合约的逻辑合约地址(implementation address)
测试部署脚本
const [deployer] = await ethers.getSigners();
console.log("Deployer:", await deployer.getAddress())
const commonBridgeFactory = await ethers.getContractFactory("CommonBridge", deployer);
let commonBridgeProxyContract;
if (deployOutput.commonBridgeProxyContract === undefined || deployOutput.commonBridgeProxyContract === '') {
commonBridgeProxyContract = await upgrades.deployProxy(
commonBridgeFactory,
[
process.env.DOMAIN_ID,
process.env.SUPER_ADMIN_ADDRESS,
process.env.BRIDGE_FEE_ADDRESS
],
{
constructorArgs: [],
unsafeAllow: ['constructor', 'state-variable-immutable'],
});
console.log('tx hash:', commonBridgeProxyContract.deploymentTransaction().hash);
} else {
commonBridgeProxyContract = commonBridgeFactory.attach(deployOutput.commonBridgeProxyContract);
}
console.log('commonBridgeProxyContract deployed to:', commonBridgeProxyContract.target);
await sleep(6000);
const commonBridgeImpl = await upgrades.erc1967.getImplementationAddress(commonBridgeProxyContract.target);
console.log('commonBridgeProxyContract implementation deployed to:', commonBridgeImpl);
部署超时
Error: Timed out waiting for implementation contract deployment to address 0x5393... with transaction 0x9492...
解决:增加超时和轮询设置
...
commonBridgeProxyContract = await upgrades.deployProxy(
commonBridgeFactory,
[
process.env.DOMAIN_ID,
process.env.SUPER_ADMIN_ADDRESS,
process.env.BRIDGE_FEE_ADDRESS
],
{
constructorArgs: [],
unsafeAllow: ['constructor', 'state-variable-immutable'],
timeout: 300000, // 5分钟
pollingInterval: 5000, // 每5秒轮询一次
});
console.log('tx hash:', commonBridgeProxyContract.deploymentTransaction().hash);
...
不符合 ERC1967 标准
使用 upgrades.erc1967.getImplementationAddress 来获取通过 upgrades.deployProxy 部署的合约的逻辑合约地址(implementation address),结果报:部署地址不符合 ERC1967 标准的代理合约(Proxy)
Error: Contract at 0xffa5f716D890CFd4f9D709A40d6EB7Fb19fC43B4 doesn't look like an ERC 1967 proxy with a logic contract address
const implSlot = '0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc';
const proxyAddress = '0xffa5f716D890CFd4f9D709A40d6EB7Fb19fC43B4';
const storage = await ethers.provider.getStorage(proxyAddress, implSlot);
console.log("Raw implementation slot:", storage);
const implAddress = '0x' + storage.slice(-40);
console.log("Implementation address:", implAddress);
const implAddress1 = await upgrades.erc1967.getImplementationAddress(proxyAddress);
console.log("Implementation address1:", implAddress1);
如果返回的 implStorage 是全零(0x000...),说明实现地址确实没有写进去,可能部署时失败或未初始化。
如果你用其他方式部署 Proxy(比如自己 new TransparentUpgradeableProxy,而不是用 upgrades.deployProxy()),OpenZeppelin 插件就不能保证你用了它支持的初始化逻辑。
解决: 是因为网络延迟原因,增加延迟时间
console.log('commonBridgeProxyContract deployed to:', commonBridgeProxyContract.target);
await sleep(20000); // 提高延迟间隔
const commonBridgeImpl = await upgrades.erc1967.getImplementationAddress(commonBridgeProxyContract.target);
console.log('commonBridgeProxyContract implementation deployed to:', commonBridgeImpl);
最终版本
const [deployer] = await ethers.getSigners();
console.log("Deployer:", await deployer.getAddress())
const commonBridgeFactory = await ethers.getContractFactory("CommonBridge", deployer);
let commonBridgeProxyContract;
if (deployOutput.commonBridgeProxyContract === undefined || deployOutput.commonBridgeProxyContract === '') {
commonBridgeProxyContract = await upgrades.deployProxy(
commonBridgeFactory,
[
process.env.DOMAIN_ID,
process.env.SUPER_ADMIN_ADDRESS,
process.env.BRIDGE_FEE_ADDRESS
],
{
constructorArgs: [],
unsafeAllow: ['constructor', 'state-variable-immutable'],
timeout: 300000,
pollingInterval: 5000,
});
console.log('tx hash:', commonBridgeProxyContract.deploymentTransaction().hash);
} else {
commonBridgeProxyContract = commonBridgeFactory.attach(deployOutput.commonBridgeProxyContract);
}
console.log('commonBridgeProxyContract deployed to:', commonBridgeProxyContract.target);
await sleep(20000);
const commonBridgeImpl = await upgrades.erc1967.getImplementationAddress(commonBridgeProxyContract.target);
console.log('commonBridgeProxyContract implementation deployed to:', commonBridgeImpl);最新回复
fzd: 请问这个解决了吗
StarkWare explained: layer 2 solution provider of dYdX and iMMUTABLE R11; BitKeep News: [...]Layer 2: https://...
一文读懂 StarkWare:dYdX 和 Immutable 背后的 L2 方案 R11; BitKeep 博客: [...]Layer 2:Comparing Laye...
http://andere.strikingly.com/: Regards, Great stuff!
surou: 需要先执行提案合约申请,等待出块节点地址同意后,才会进...
heco: WARN [11-19|11:26:09.459] N...
P: 你好,我在heco链上遇到了“tx fee excee...
Peng: 楼主安装成功了吗?我正在同步区块链,一天了,差不多才同...
joyhu: 你好,请问下安装好之后如何获取到bee.yaml配置文...
kaka: 支票最终怎么提币呢?
归档
September 2026July 2026June 2026May 2026April 2026March 2026February 2026January 2026December 2025November 2025October 2025September 2025August 2025July 2025June 2025May 2025April 2025March 2025February 2025January 2025December 2024November 2024October 2024September 2024August 2024July 2024June 2024May 2024April 2024March 2024January 2024December 2023November 2023October 2023September 2023August 2023July 2023June 2023April 2023March 2023February 2023January 2023December 2022November 2022October 2022August 2022July 2022June 2022May 2022March 2022February 2022January 2022December 2021November 2021October 2021September 2021August 2021July 2021June 2021May 2021April 2021March 2021February 2021January 2021December 2020November 2020October 2020September 2020July 2020June 2020May 2020April 2020March 2020February 2020January 2020December 2019November 2019October 2019September 2019August 2019July 2019June 2019May 2019April 2019March 2019February 2019January 2019December 2018November 2018October 2018September 2018August 2018July 2018June 2018