Skip to content

beck-8/sectors_penalty

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

21 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

sectors_penalty

  • 获取节点扇区过期时间、过期扇区数量、到期释放质押币、此时终结惩罚(扇区在请求数据时进行终结,要惩罚的费用)
  • 获取节点的锁仓释放明细

install && run

返回慢时,优化此程序到lotus rpc之间的链接

git clone https://github.com/beck-8/sectors_penalty.git
make build

# run
./sectors_penalty

# use port 6666
./sectors_penalty -port 6666

# use other lotus
# lotus auth api-info --perm read
export FULLNODE_API_INFO=/ip4/192.168.1.1/tcp/1234/http
./sectors_penalty

Usage

miner 节点ID
all 是否展示全部的扇区(包含过期的)
offset 往前/往后推移多少天(+20/-20)
json 返回json格式数据

查看f01155的信息

http://127.0.0.1:8099/penalty?miner=f01155

http://127.0.0.1:8099/penalty?miner=f01155&json=1

查看f01155全部的信息(包含已经过期的)

http://127.0.0.1:8099/penalty?miner=f01155&all=1

查看f01155 20天后的终结惩罚信息(penalty列数据不变说明已经达到惩罚上限)

http://127.0.0.1:8099/penalty?miner=f01155&offset=20

查看f01155 锁仓释放明细

http://127.0.0.1:8099/vested?miner=f01155

http://127.0.0.1:8099/vested?miner=f01155&json=1

example

使用curl命令或者浏览器打开都可以

curl http://127.0.0.1:8099/penalty?miner=f0866680

date,mid,sectors_sum,power(TiB),pledge,penalty
2024-12-01,f0866680,38,1.1875,75.2688139355,3.6893887223
2024-12-02,f0866680,78,2.4375,158.2429226213,7.5040697345
2024-12-03,f0866680,84,2.625,170.3091640243,8.0580883233
2024-12-04,f0866680,95,2.96875,192.6741598187,8.8614362125
2024-12-05,f0866680,95,2.96875,192.2272089942,8.7681901009
2024-12-06,f0866680,94,2.9375,190.4208206143,8.3987484425
2024-12-07,f0866680,100,3.125,202.8031188903,8.8478346955
2024-12-08,f0866680,165,5.15625,334.4079559344,14.2238906870
2024-12-09,f0866680,399,12.46875,807.3704029356,34.1501383588
2024-12-10,f0866680,424,13.25,859.8929713294,35.0366972770
2024-12-11,f0866680,163,5.09375,330.5287945072,13.5163591034
2024-12-14,f0866680,2,0.0625,4.0420407207,0.1536782909
2024-12-15,f0866680,4,0.125,8.0734560093,0.3064116772
2024-12-16,f0866680,6,0.1875,10.9430125046,0.3981992402
2024-12-17,f0866680,282,8.8125,567.1220840978,20.6613795328
2024-12-18,f0866680,423,13.21875,848.8358715125,29.6119697896
2024-12-19,f0866680,156,4.875,312.6695184390,10.8398275530
2024-12-20,f0866680,108,3.375,216.1049270035,7.2353115337
2024-12-21,f0866680,69,2.15625,138.1236400462,4.6387485048
2024-12-22,f0866680,164,5.125,328.1744731517,10.5813191863
2024-12-23,f0866680,394,12.3125,785.3279018250,25.0888386966
2024-12-24,f0866680,396,12.375,787.9921027059,24.1156159453
2024-12-25,f0866680,384,12,763.0601758970,23.2382573520
2024-12-26,f0866680,198,6.1875,392.1859160204,11.4823118285
2024-12-29,f0866680,76,2.375,150.7013478409,4.1635104806
2024-12-30,f0866680,97,3.03125,192.3118708868,5.0892094651
2024-12-31,f0866680,169,5.28125,334.3857092328,8.8231273695
2025-01-01,f0866680,236,7.375,466.2388610899,11.6620230540
2025-01-02,f0866680,174,5.4375,343.7625333907,8.5634895705
,,5073,158.53125,10164.2017759800,357.7080707281
  • 第一行是标题,最后一行是数据汇总,最后一列是扇区惩罚的预估数据
  • 如果想看之前已经过期的数据,使用 curl http://127.0.0.1:8099/penalty?miner=f0866680&all=1
  • 如果想看此节点20天之后全部终结的惩罚,使用 curl http://127.0.0.1:8099/penalty?miner=f0866680&offset=20
  • 如果想看此节点20天之前全部终结的惩罚,使用 curl http://127.0.0.1:8099/penalty?miner=f0866680&offset=-20
  • 如果要对数据进行二次处理加工,复制数据保存为csv打开或者使用excel按逗号分列或者awk等等

curl http://127.0.0.1:8099/vested?miner=f0866680

Date,VestedFunds(FIL)
2023-07-27,0.0000000000
2023-07-28,1.0712193049
...
2024-01-21,0.1849083665
2024-01-22,0.0457635234

curl http://127.0.0.1:8099/penalty?miner=f010202&json=1

{
    "code": 200,
    "level": 0,
    "msg": "OK",
    "data": [
        {
            "date": "2023-09-25",
            "mid": "f010202",
            "sectors_sum": 1,
            "power": 0.03125,
            "pledge": "0.1885872137",
            "penalty": "0.0578863373"
        },
        {
            "date": "2025-02-13",
            "mid": "f010202",
            "sectors_sum": 1,
            "power": 0.03125,
            "pledge": "0.1916776235",
            "penalty": "0.0045002204"
        }
    ]
}

curl http://127.0.0.1:8099/vested?miner=f010202&json=1

{
    "code": 200,
    "level": 0,
    "msg": "OK",
    "data": [
        {
            "date": "2023-08-26",
            "vested_funds": "1.4587645221"
        },
        {
            "date": "2024-02-20",
            "vested_funds": "0.0659376734"
        }
    ]
}

About

filecoin sector_penalty data

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published