<#9118 feat: Support a `requires_meltano` key at t...
# meltano-repo-activity
g
#9118 feat: Support a `requires_meltano` key at the project level Pull request opened by edgarrmondragon ## Description This PR adds support for defining the Meltano version requirement for a project. For example: version: 1 # deprecated here default_environment: dev project_readonly: true requires_meltano: ">=3,!=3.5.0,!3.5.1,<4" ## TODO • Support
requires_meltano
per plugin (maybe out of scope? undecided) • Decide what to do with
version: 1
. If we decide to keep it, we should make the distinction clear in the docs. • Documentation ## Related Issues • Closes #3187 ## Summary by Sourcery Enforce Meltano version constraints by introducing a
requires_meltano
field for both projects and plugins, deprecating the old
version
key, and wiring in compatibility checks with clear errors and documentation updates. New Features: • Support a
requires_meltano
key at the project level to enforce Meltano version requirements in project configurations • Add a
requires_meltano
field to plugin definitions to declare and enforce plugin-specific Meltano version constraints • Deprecate the top-level
version
field in meltano.yml and emit a warning when it is present Enhancements: • Introduce
get_meltano_version
and
check_meltano_compatibility
utilities along with an
IncompatibleMeltanoVersionError
for version validation • Update project activation and plugin invocation to perform compatibility checks and provide a clear exit code and message on mismatch • Add a
__repr__
method to the Project class and switch user agent generation to use the cached Meltano version Documentation: • Remove the deprecated
version
field from examples and tutorials • Document the
requires_meltano
key in project and plugin definition reference guides and update plugin management notes Tests: • Add tests for project-level and plugin-level
requires_meltano
compatibility enforcement and error messaging • Add tests for deprecation warnings when
version
is used and JSON schema validation of plugin
requires_meltano
meltano/meltano