fix: full-repo ruff lint cleanup and CI migration to uv

Resolve all 374 ruff errors across 36 Python files (E501, E702, E722,
E741, F821, F841, invalid-syntax) bringing `ruff check .` to zero
errors repo-wide with line-length=100.

Rewrite CI workflow to use uv for dependency management, whole-repo
`ruff check .`, py_compile syntax gate, and merged python-tests job.
Add pyproject.toml with ruff config and uv dependency groups.

CI structure proposed by hcm444.
This commit is contained in:
Jason
2026-04-09 02:05:34 +03:00
parent 57de32b172
commit 11aa590cf2
31 changed files with 3633 additions and 2789 deletions
+15 -3
View File
@@ -26,10 +26,20 @@ ax.axhline(polygon_y2, color="blue", linestyle="--")
via_positions = [2, 2 + via_pitch] # two vias for showing spacing
for x in via_positions:
# Case A
ax.add_patch(plt.Circle((x, polygon_y1), via_pad_A/2, facecolor="green", alpha=0.5, label="Via pad A" if x==2 else ""))
ax.add_patch(
plt.Circle(
(x, polygon_y1), via_pad_A / 2, facecolor="green", alpha=0.5,
label="Via pad A" if x == 2 else ""
)
)
ax.add_patch(plt.Circle((x, polygon_y2), via_pad_A/2, facecolor="green", alpha=0.5))
# Case B
ax.add_patch(plt.Circle((-x, polygon_y1), via_pad_B/2, facecolor="red", alpha=0.3, label="Via pad B" if x==2 else ""))
ax.add_patch(
plt.Circle(
(-x, polygon_y1), via_pad_B / 2, facecolor="red", alpha=0.3,
label="Via pad B" if x == 2 else ""
)
)
ax.add_patch(plt.Circle((-x, polygon_y2), via_pad_B/2, facecolor="red", alpha=0.3))
# Add text annotations
@@ -48,7 +58,9 @@ line_edge_y = rf_line_y + line_width/2
via_center_y = polygon_y1
ax.annotate("", xy=(2.4, line_edge_y), xytext=(2.4, via_center_y),
arrowprops=dict(arrowstyle="<->", color="brown"))
ax.text(2.5, (line_edge_y + via_center_y)/2, f"{via_center_offset:.2f} mm", color="brown", va="center")
ax.text(
2.5, (line_edge_y + via_center_y) / 2, f"{via_center_offset:.2f} mm", color="brown", va="center"
)
# Formatting
ax.set_xlim(-5, 5)