Skip to content

feat: add optical fiber ray visualization - #10

Draft
CodingBunny06 wants to merge 3 commits into
mainfrom
feat/fiber-ray-visualization-integration
Draft

CodingBunny06 wants to merge 3 commits into
mainfrom
feat/fiber-ray-visualization-integration

Conversation

@CodingBunny06

Copy link
Copy Markdown
Owner

Summary

  • Recover the v2 optical fiber ray visualization implementation onto a branch based on the current main.
  • Add the Plotly fiber structure, incident/propagating ray paths, TIR/refraction labeling, and optional refracted-ray overlays.
  • Correct the test expectations to match the trace names emitted by the implementation.
  • Replace the duplicate non-TIR assertion with a check for the attenuated propagating-ray label.

Validation

  • The source branch's isolated test run produced 12 passed, 1 failed; the failure was caused by stale expected trace names.
  • This PR is a draft pending a fresh CI run and review of the corrected test suite.

Scope

This PR adds the fiber-ray visualization module only. It does not implement physics calculations or integrate the Fiber Explorer page.

Copy link
Copy Markdown
Owner Author

@copilot Please fix the four Ruff errors reported by the latest FiberLab CI run for this PR, without changing the visualization behaviour or expanding scope.

CI run: https://github.com/CodingBunny06/FiberLab/actions/runs/43575660537

Required fixes in visualization/fiber_animation.py:

  1. Sort imports to satisfy Ruff I001.
  2. Use TypeError for invalid input types in the ray coordinate sequence validation (TRY004).
  3. Use TypeError for a non-boolean is_tir value (TRY004).
  4. Combine the nested optional-metadata validation condition to satisfy SIM102.

Then run the full test suite, ruff check ., and the formatting check used by the repository CI. Push the fixes to this PR branch and report the exact command results. Do not merge the PR.

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>

Copilot AI commented Nov 14, 2026

Copy link
Copy Markdown
Contributor

@copilot Please fix the four Ruff errors reported by the latest FiberLab CI run for this PR, without changing the visualization behaviour or expanding scope.

CI run: https://github.com/CodingBunny06/...

Fixed in commit 00a5559. Validation: python -m pytest -v — 167 passed, 1 skipped; ruff check . — passed; ruff format --check . — 53 files already formatted; targeted python -m pytest -q tests/test_fiber_animation.py — 13 passed. Secret scan found no secrets, and CodeQL reported the changes as trivial.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants