Skip to content

Repository analysis: 20 actionable issues identified across bugs, enhancements, tests, and CI#4

Draft
Copilot wants to merge 3 commits intomainfrom
copilot/analyze-repository-for-issues
Draft

Repository analysis: 20 actionable issues identified across bugs, enhancements, tests, and CI#4
Copilot wants to merge 3 commits intomainfrom
copilot/analyze-repository-for-issues

Conversation

Copy link
Copy Markdown

Copilot AI commented Mar 8, 2026

Full codebase audit to surface filing-ready issues. Cross-referenced against all 44 upstream arxlang/irx issues (25 open, 19 closed) to avoid duplicates.

Adds REPOSITORY_ANALYSIS.md with 20 issues organized by category:

Bugs (6)

  • RegisterTable methods crash with IndexError on empty stack — no bounds checking on any of increase(), last, pop(), redefine(), reset()
  • run_command() swallows CalledProcessError, returns str(returncode) — callers can't distinguish success from failure
  • LLVMLiteIRVisitor declares named_values: dict = {} and result_stack: list = [] as class-level mutable defaults (shared across instances)
  • WhileStmt/ForCountLoopStmt visitors use raw pop() instead of safe_pop() — unhandled IndexError on empty stack
  • String literal encoding uses bytearray(..., "ascii") — crashes on non-ASCII Unicode
  • LiteralDateTime timezone parsing does "-" in time_part[2:] — silently wrong on malformed input

Enhancements (6)

  • Abstract translate() raises Exception instead of NotImplementedError
  • Module name hardcoded to "Arx" — should be configurable
  • Duplicated condition-to-boolean logic in IfStmt/WhileStmt — extract helper
  • RegisterTable has no __repr__ for debugging
  • Inconsistent exception types across visitors (ValueError vs Exception vs TypeError)
  • tools/typing.py mutates global typeguard config at import time

Test gaps (4)

  • No error-path tests for RegisterTable empty-stack operations
  • Only > and < tested in conditionals — ==, !=, >=, <= uncovered
  • All cast tests use value 42 — no overflow/boundary/precision-loss coverage
  • Translation action commented out in every test file — IR output never validated

CI / Infra (4)

  • actions/checkout@v3 → should be v4
  • Coverage computed but never uploaded
  • No [tool.coverage] section in pyproject.toml
  • macOS CI disabled with no tracking issue

🔒 GitHub Advanced Security automatically protects Copilot coding agent pull requests. You can protect all pull requests by enabling Advanced Security for your repositories. Learn more about Advanced Security.

Copilot AI and others added 2 commits March 8, 2026 13:05
…ptions

Co-authored-by: omsherikar <180152315+omsherikar@users.noreply.github.com>
…behavior, fix macOS casing

Co-authored-by: omsherikar <180152315+omsherikar@users.noreply.github.com>
Copilot AI changed the title [WIP] Analyze repository for potential improvements and bugs Repository analysis: 20 actionable issues identified across bugs, enhancements, tests, and CI Mar 8, 2026
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