SiaFoundation/hostd

Add timestamps to contract API responses

开放

#376 创建于 2024年5月1日

 (0 条评论) (0 个反应) (0 位负责人)Go (27 个派生)auto 404
featuregood first issue

仓库指标

星标
 (68 个星标)
PR 合并指标
 (PR 指标待抓取)

描述

Description

The contract data in the UI currently uses estimates based on block heights for all timestamps. Once the block has passed, the actual timestamp should be used instead.

This requires a few changes across hostd:

  • Add additional columns to the contracts table for the timestamps
    • Negotiation timestamp
    • Window start timestamp
    • Window end timestamp
    • Resolution timestamp
    • Payout timestamp
  • Update the corresponding columns during block processing
  • Add the fields to the Contract type and API response

贡献者指南