Agent CLI build and deploy guide: captures the contract ID the CLI's own skill says not to

未关闭 适合新手
#2,980 3 条评论 1 个 reaction 已指派 1 人 在 GitHub 查看

维护者通常 1 天内回复

还没有人认领这个 Issue。

评估

难度
2/5
预计耗时
1-3 小时
新手友好度
65/100
Issue 类型
文档
描述清晰度
基本清楚
活跃度
活跃
技术栈
shell
领域
cli, documentation

调研方向

从 docs/tools/cli/agent-cli/guides/build-and-deploy-contracts.mdx 大约第 53 行开始,第 3 步在那里把部署输出捕获到 ID 中。后续步骤使用的是 --id hello_world,因此该变量未被使用。阅读 skill/SKILL.md(第 45-59 行)中的 skill 文本,以及 CLI 参考中 stellar contract alias show 的条目,找出如何恢复 ID。完成的标准是:没有任何步骤把部署输出捕获到未使用的变量中,指南展示了基于别名获取 ID 的方法,并且 pnpm validate 通过。

由索引模型根据 Issue 内容生成。

描述

bot:hands-off

Page: https://developers.stellar.org/docs/tools/cli/agent-cli/guides/build-and-deploy-contracts
File: docs/tools/cli/agent-cli/guides/build-and-deploy-contracts.mdx:53

What's wrong:
Step 3 deploys with ID=$(stellar contract deploy ... --alias hello_world). $ID is never used afterwards (later steps use --id hello_world), and the CLI's built-in skill tells agents: "Do not capture the deployed contract id into a shell variable or .env file". The page doesn't say how to get the ID back later if an agent needs it.

Outcome we're after:
The guide doesn't model capturing deploy output, agrees with the CLI's skill, and an agent reading it knows how to get a deployed contract's ID when it needs one. How to get there is up to whoever picks this up.

Reference:

How to check the fix:

  • Following the guide with CLI 28.x on testnet, every step still works.
  • No step captures deploy output into a variable that the guide doesn't use.
  • pnpm validate passes.

Why it matters: Coding agents copy these guides as is. In the HackMeridian 2026 hackathon (147 public repos), deploy scripts captured contract IDs from stdout and copied them into files.

Related: stellar/stellar-cli#2880 (the skill doesn't mention alias show), #2972 (initialization guide, same pattern), #2892 (added this guide).

主要语言
MDX
星标
145
派生
326
平均合并
2 天 18 小时
30 天内合并 PR
109

环境准备

  • 没有 Dockerfile 或 Docker Compose 文件
  • 没有 Pull Request 模板
  • 阅读贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

stellar/stellar-docs 的其他 Issue

查看 stellar/stellar-docs 的全部 Issue

相似的 Issue

更多 CLI Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。