Skip to content

Fix/output multiplicity pipe sequence#530

Merged
lchoquel merged 6 commits intodevfrom
fix/output-multiplicity-PipeSequence
Dec 21, 2025
Merged

Fix/output multiplicity pipe sequence#530
lchoquel merged 6 commits intodevfrom
fix/output-multiplicity-PipeSequence

Conversation

@thomashebrard
Copy link
Copy Markdown
Member

@thomashebrard thomashebrard commented Dec 19, 2025

🔗 Related Issues

📝 Description

🔄 Type of Change

  • 🐛 Bug fix
  • ✨ New feature
  • 💥 Breaking change
  • 📚 Documentation update
  • 🧹 Code refactor
  • ⚡ Performance improvement
  • ✅ Test update

🧪 Tests

📋 Checklist

  • Linting / type-checking / unit tests pass locally with my changes
  • I've added tests that prove my fix is effective or that my feature works
  • My code follows the style guidelines of this project
  • I've made corresponding changes to the documentation
  • My changes generate no new warnings

Note

Validate PipeSequence output multiplicity against last step using new compatibility helper; refine batch/sub-pipe param handling and pretty rendering for text.

  • Pipes / Controllers:
    • PipeSequence: Validate output using concept compatibility and is_multiplicity_compatible, considering per-step overrides and batching; improved error messages.
    • SubPipe / PipeBatch: Propagate batch_params only when batching; create ad-hoc batch pipe code (<pipe>_adhoc_batch); in batch branches set final_stuff_code and force single per-branch output via output_multiplicity=False.
    • SubPipeFactory: Compute output_multiplicity directly (handles batch_over/batch_as, nb_output, multiple_output).
  • Core:
    • variable_multiplicity: Add is_multiplicity_compatible utility.
    • concept_factory: For string-declared concepts, stop setting refines.
    • TextContent: Implement rendered_pretty via rich.markdown.Markdown and remove inline pretty print.
  • Tests:
    • Add unit tests for is_multiplicity_compatible.
    • Expand integration tests for PipeSequence multiplicity scenarios and Discord newsletter batching (plus sample test data).
  • Misc:
    • Update VS Code launch configs (debugging presets).

Written by Cursor Bugbot for commit 63c4b28. This will update automatically on new commits. Configure here.

thomashebrard and others added 5 commits December 19, 2025 22:31
* Add setup to launch debug run of a pipe code

* sample input shaped as working memory to enable direct pipe run

* Fix checking multiplicity without modifying a pipe.
Fix multiplicity of pipe batch branch pipe.

* cleanup imports

* Fix debug print

* is_multiplicity_compatible() so that fixed multiplicity is compatible with multiplicity true

* Fix and test wrong case due to bool being a subclass of int

---------

Co-authored-by: Louis Choquel <8851983+lchoquel@users.noreply.github.com>
@lchoquel lchoquel merged commit a770aa1 into dev Dec 21, 2025
18 checks passed
@github-actions github-actions bot locked and limited conversation to collaborators Dec 21, 2025
@lchoquel lchoquel deleted the fix/output-multiplicity-PipeSequence branch December 21, 2025 11:00
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants