Skip to content

Add python3-vcs2l-vcstool-shim debian package#90

Closed
cottsay wants to merge 1 commit intomainfrom
cottsay/vcstool-shim
Closed

Add python3-vcs2l-vcstool-shim debian package#90
cottsay wants to merge 1 commit intomainfrom
cottsay/vcstool-shim

Conversation

@cottsay
Copy link
Member

@cottsay cottsay commented Dec 15, 2025

Basic Info

Info Please fill out this column
Ticket(s) this addresses resolves #88
Primary OS tested on Ubuntu
Is this a breaking change? No
Does this PR contain AI generated software? No

Description of contribution in a few bullet points

This sub-package presents vcs2l as a wholesale replacement for vcstool and should satisfy any existing dependencies on vcstool without requiring changes to vcs2l itself. It operates under the fact that the existing vcs2l API is similar enough to vcstool that it can simply be installed and used under that name.

When the vcs2l API deviates from vcstool enough, this commit may be reverted and the shim package dropped.

Description of how this change was tested

  • Performed linting validation using pre-commit run --all
  • Verified that the code passes all tests using python3 -m pytest -s -v test
  • Verified that debs satisfy dependency on python3-vcstool

This sub-package presents vcs2l as a wholesale replacement for vcstool
and should satisfy any existing dependencies on vcstool without
requiring changes to vcs2l itself. It operates under the fact that the
existing vcs2l API is similar enough to vcstool that it can simply be
installed and used under that name.

When the vcs2l API deviates from vcstool enough, this commit may be
reverted and the shim package dropped.

Signed-off-by: Scott K Logan <logans@cottsay.net>
@cottsay cottsay requested a review from j-rivero December 15, 2025 18:10
@cottsay cottsay self-assigned this Dec 15, 2025
@cottsay cottsay added the enhancement New feature or request label Dec 15, 2025
@cottsay cottsay force-pushed the cottsay/vcstool-shim branch from 55779bd to a82ddeb Compare December 15, 2025 18:11
@codecov-commenter
Copy link

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 26.96%. Comparing base (a9022f0) to head (a82ddeb).

Additional details and impacted files
@@           Coverage Diff           @@
##             main      #90   +/-   ##
=======================================
  Coverage   26.96%   26.96%           
=======================================
  Files          31       31           
  Lines        2240     2240           
  Branches      393      393           
=======================================
  Hits          604      604           
  Misses       1576     1576           
  Partials       60       60           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@j-rivero
Copy link

Comparing to what we did in gazebo-release/gz_math_vendor#18 and we are generalizing in gazebo-tooling/gz_vendor#26. seems to me a different approach:

  • This repo uses a package duplication approach where setup.py installs the same source files under both vcs2l/ and vcstool/ directories using package_dir mapping. This happens at building time duplicating code on disk.

  • The gz_math_vendor#18 approach uses a runtime re-export shim - a small Python file that imports everything from the real module and re-exports it under the old name.

I think that use cases are quite different. Here there is a transparent aliasing for vcs command invocations. most of them hosted in bin/. In gz_*_vendor we are dealing with a Python library so we mostly prepare the terrain for the usuals "import gz_foo" or "from gz_foo import lala". A single entry point coming from a Python import.

Said that: I think that both approaches are fine taking into account the different context on both packages (one is a vendoring, another is a native)

@cottsay
Copy link
Member Author

cottsay commented Jan 13, 2026

Thanks @j-rivero! I think the approach taken in Gazebo is much better. I drafted #94 implementing it, please have a look.

@cottsay cottsay closed this Jan 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[packaging] Make python3-vcs2l fulfill python3-vcstool dependency.

3 participants