Skip to content

T-010: Add fleet-contextual README#2

Open
SuperInstance wants to merge 2 commits intomainfrom
superz/T-010
Open

T-010: Add fleet-contextual README#2
SuperInstance wants to merge 2 commits intomainfrom
superz/T-010

Conversation

@SuperInstance
Copy link
Copy Markdown
Owner

@SuperInstance SuperInstance commented Apr 13, 2026

Summary

Adds a fleet-contextual README.md that explains this repo's role in the FLUX ecosystem.

What changed

  • Replaced minimal/outdated README with comprehensive fleet-contextual documentation
  • Added: one-liner description, ecosystem role, key features table, quick start with code examples, related fleet repos with links

Why

Many repos in the SuperInstance org were forked from Lucineer and had minimal or placeholder READMEs. Fleet-contextual READMEs help agents (and humans) understand how each repo fits into the broader FLUX architecture.


Task T-010 — Generated by Super Z (FLUX Fleet Greenhorn)


Staging: Open in Devin

Super Z and others added 2 commits April 12, 2026 18:55
- Add 66 pytest tests covering CoverageReport, _inst_size,
  _count_instructions, and CoverageCollector
- Test all opcodes: MOVI, INC, DEC, ADD, SUB, MUL, CMP_EQ, MOV,
  PUSH, POP, JZ, JNZ
- Test edge cases: empty bytecode, max_cycles, unknown opcodes,
  negative immediates, unreachable code
- Test branch coverage both-ways and path accumulation
- Document known discrepancy with unknown opcode sizing
- Add .gitignore for Python, IDE, testing, and fleet artifacts
Copy link
Copy Markdown

@beta-devin-ai-integration beta-devin-ai-integration bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Devin Review found 3 potential issues.

View 4 additional findings in Devin Review.

Staging: Open in Devin

from flux_coverage import CoverageCollector

# Analyze coverage of a factorial program
bytecode = [0x18, 0, 6, 0x18, 1, 1, 0x22, 1, 1, 0, 0x09, 0, 0x3D, 0, -6, 0, 0x00]
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 README Quick Start bytecode contains -6 which crashes bytes() constructor

The Quick Start example on line 37 uses -6 in the bytecode list: bytecode = [... 0x3D, 0, -6, 0, 0x00]. When this is passed to CoverageCollector.__init__ (coverage.py:68), it calls self.bytecode = bytes(bytecode), which raises ValueError: bytes must be in range(0, 256) because -6 is negative. The working tests use 0xFA for this value (the unsigned byte representation whose signed interpretation via sb() is -6).

Suggested change
bytecode = [0x18, 0, 6, 0x18, 1, 1, 0x22, 1, 1, 0, 0x09, 0, 0x3D, 0, -6, 0, 0x00]
bytecode = [0x18, 0, 6, 0x18, 1, 1, 0x22, 1, 1, 0, 0x09, 0, 0x3D, 0, 0xFA, 0, 0x00]
Staging: Open in Devin

Was this helpful? React with 👍 or 👎 to provide feedback.

Debug

Playground

## Quick Start

```python
from flux_coverage import CoverageCollector
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 README Quick Start imports non-existent module flux_coverage

The Quick Start example imports from flux_coverage import CoverageCollector, but the actual module file is coverage.py, not flux_coverage.py. There is no flux_coverage module, package, or installed distribution in the repository. The test suite (tests/test_coverage.py:4) correctly imports from coverage import CoverageCollector. Copying the README example would raise ModuleNotFoundError.

Suggested change
from flux_coverage import CoverageCollector
from coverage import CoverageCollector
Staging: Open in Devin

Was this helpful? React with 👍 or 👎 to provide feedback.

Debug

Playground


# Test with different inputs for differential coverage
collector2 = CoverageCollector(bytecode)
_, report2 = collector2.run(initial_regs={0: 1}) # n=1 instead of n=6
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 README differential coverage example is ineffective — initial_regs={0: 1} is immediately overwritten

Line 52 shows collector2.run(initial_regs={0: 1}) with the comment # n=1 instead of n=6, implying this runs the factorial with a different input. However, the bytecode starts with MOVI r0, 6 (opcode 0x18, 0, 6 at position 0), which unconditionally sets r0 to 6, overwriting the initial value of 1. The factorial still computes 6!=720, not 1!=1. This undermines the "differential coverage" demonstration — both runs produce identical behavior.

Prompt for agents
The differential coverage example at README.md:50-52 is misleading. The bytecode begins with MOVI r0, 6 which unconditionally sets r0=6, so passing initial_regs={0: 1} has no effect — the program still computes 6!=720.

To fix this, either:
1. Modify the bytecode to not hardcode the input (remove the MOVI r0,6 instruction and start from ADD/MUL), relying on initial_regs to set the input, or
2. Change the example to use a different bytecode that actually depends on initial register values, or
3. At minimum, fix the comment to not claim 'n=1 instead of n=6' since that's incorrect.
Staging: Open in Devin

Was this helpful? React with 👍 or 👎 to provide feedback.

Debug

Playground

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.

1 participant