`tsci check netlist` prints `undefined` after a resistor's value and labels resistor pins anode / cathode

未关闭
#5,447 1 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 1 天内回复

@cocvn157 已经在做这个了。

开始于 2026年11月5日。

  • #694 来自 @godgamerex3-boop —— 已关闭,未合并
  • #5475 来自 @JohnNuwan —— 已关闭,未合并
  • #5564 来自 @ducanh3005 —— 已关闭,未合并
  • #5595 来自 @vulinh1704 —— 已关闭,未合并
  • #5708 来自 @cocvn157 —— 未关闭

评估

难度
3/5
预计耗时
1-2 天
新手友好度
35/100
Issue 类型
缺陷
描述清晰度
描述清楚
活跃度
停滞
技术栈
react, typescript
领域
backend, cli

调研方向

Start by reproducing the example with the listed tscircuit and CLI versions, then trace how tsci check netlist formats resistor metadata and pin aliases. The issue gives no source files or tests, so locate the relevant formatter and its coverage before making changes. Done means the output omits undefined and shows appropriate resistor pin labels; an open linked pull request (#5475) is already working on the issue.

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

描述

For a header, a 1 kΩ 0603 resistor and an LED in series:

export default () => (
  <board width="20mm" height="12mm" layers={2}>
    <pinheader name="J1" pinCount={2} pitch="2.54mm" pcbX={-6} pcbY={0} />
    <resistor name="R1" resistance="1k" footprint="0603" pcbX={1} pcbY={2} />
    <led name="D1" color="green" footprint="0603" pcbX={6} pcbY={0} />
    <trace name="VIN" from=".J1 > .pin1" to=".R1 > .pin1" />
    <trace name="LED_A" from=".R1 > .pin2" to=".D1 > .anode" />
    <trace name="GND" from=".D1 > .cathode" to=".J1 > .pin2" />
  </board>
)

tsci check netlist prints:

R1 (1kΩ undefined)
- pin1(anode, pos, left): NETS(R1_pos)
- pin2(cathode, neg, right): NETS(D1_pos)
  • undefined: probably an empty manufacturer part number or package field. Expected: the field left out, or a real value such as 0603.
  • Pin aliases: a resistor's pins are listed with the aliases anode / cathode (and pos / neg), which belong to diodes and polarised parts. Expected: pin1 / pin2, or pos / neg at most.

Versions: tscircuit 0.0.2942 (@tscircuit/cli 0.1.2364).

主要语言
TypeScript
星标
19
派生
115
平均合并
1 小时 50 分钟
30 天内合并 PR
260

环境准备

这个项目没有提供开发容器、Dockerfile 或贡献指南,环境需要你自己搭建:先看它的 README,通用步骤见我们的新手贡献指南。

从这里开始

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

tscircuit/cli 的其他 Issue

查看 tscircuit/cli 的全部 Issue

相似的 Issue

更多 TypeScript Issue

把新 issue 发到你的邮箱

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