Hacktoberfest 2026:维护者为十月标记出来的 issue,仍然开放、适合新手。 浏览 Hacktoberfest issue

Quick Start: TypeScript mediation example calls ConnectionsManager with missing arguments

未关闭 适合新手
#302 1 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

评估

难度
1/5
预计耗时
1 小时以内
新手友好度
88/100
Issue 类型
缺陷
描述清晰度
描述清楚
活跃度
活跃
技术栈
typescript
领域
documentation

调研方向

阅读 documentation/develop/quick-start.md 中的 TypeScript mediation 示例(第 375–402 行),并将其中对 ConnectionsManager 的调用与固定版本 SDK v6.6.0 源码 src/edge-agent/connectionsManager/ConnectionsManager.ts 中的构造函数进行比较。更新示例以提供所需依赖,然后根据该构造函数验证 handler 已定义且调用通过类型检查。

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

描述

bug documentation ready-for-agent

User impact

Developers copying the Quick Start's "establish mediation when building your own application" TypeScript example cannot construct the connection manager at the SDK version the page itself selects. The call supplies four arguments, so the mediator handler is passed into the Pollux position and the required mediation-handler argument is missing. Starting the agent then reaches mediation setup with an undefined handler instead of a working manager.

Affected documentation and ownership

Observed versus expected

The page example calls:

const manager = new SDK.ConnectionsManager(castor, mercury, pluto, handler);

At the selected v6.6.0 commit, ConnectionsManager requires five positional dependencies before the optional arguments (ConnectionsManager.ts lines 70–78):

constructor(
  public castor: Castor,
  public mercury: Mercury,
  public pluto: Pluto,
  public pollux: Pollux,
  public mediationHandler: MediatorHandler,
  public pairings: DIDPair[] = [],
  public options?: AgentOptions
)

With the page's four arguments, handler binds to pollux, and mediationHandler is undefined. The manager's startMediator() calls this.mediationHandler.bootRegisteredMediator().

Expected: the example supplies the dependencies the selected SDK requires, so the copied code type-checks and agent start can begin mediation.

The rest of the snippet is consistent with v6.6.0: SDK.Agent resolves to edge-agent/didcomm/Agent (src/index.ts lines 10–11), whose constructor takes apollo, castor, pluto, mercury, mediationHandler, connectionManager, seed, ... (Agent.ts lines 62–72). The defect is the manager construction, not a comparison against an unrelated base Agent class.

Evidence and reproduction

Static comparison at immutable revisions, observed 2026-10-29T16:57:35Z:

  1. Read the page snippet in the current source at fa985df and in the saved deployed HTML.
  2. Read the v6.6.0 ConnectionsManager constructor and startMediator() in hyperledger-identus/sdk-ts at 1a9da81.
  3. Count the page's arguments (4) against the constructor's required parameters (5).

Limitations: no TypeScript compiler, build or agent run was executed. Execution was blocked because no disposable credential-free check environment was established. This is a source-level contradiction with the page's own selected version, not a runtime trace.

Existing work checked

Searched open and closed issues and PRs in hyperledger-identus/docs (full title inventory of 62 issues and 238 PRs) and in hyperledger-identus/sdk-ts, by ConnectionsManager, Pollux, mediation, code example and quick start, and read matching bodies and discussion.

  • The seven open Quick Start issues #290–#296 cover startup paths, schema examples, offer/response IDs, demo controls and manual issuance attribution; none covers this mediation constructor snippet.
  • sdk-ts PR #394 (feat!: refactor ConnectionManager) is the SDK-side API change that the portal example did not follow; it is not a documentation repair.
  • No open issue or PR repairs this example.

Acceptance criteria

  • The TypeScript mediation example constructs ConnectionsManager with the dependencies required by the page's selected SDK version.
  • Verification against the pinned v6.6.0 source, or a type-check/build in a disposable environment, shows the example compiles and reaches mediation setup with a defined handler.
主要语言
TypeScript
星标
15
派生
8
平均合并
3 天 14 小时
30 天内合并 PR
2

环境准备

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

从这里开始

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

hyperledger-identus/docs 的其他 Issue

查看 hyperledger-identus/docs 的全部 Issue

相似的 Issue

更多 TypeScript Issue

把新 issue 发到你的邮箱

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