Skip to content

Schema fix#3671

Merged
ssbarnea merged 2 commits intoansible:mainfrom
apatard:schema_fix
Sep 30, 2022
Merged

Schema fix#3671
ssbarnea merged 2 commits intoansible:mainfrom
apatard:schema_fix

Conversation

@apatard
Copy link
Copy Markdown
Contributor

@apatard apatard commented Sep 26, 2022

Commit "Adopt molecule config JSON schema (#3668)" (acb9ae0)
has imported the molecule schema into data/ but everything is using
src/molecule/schemas/ as directory for the schema.

So:

  • Replace src/molecule/schemas/molecule.json content with the one
    from src/molecule/data/. The replacement was partial as the local
    schema handles in a better way the MoleculeDependencyModel. The
    new schema was allowing to use the "shell" dependency with an
    empty command.
  • Update schema $id to point to the correct location
  • Fix test link to point to the correct schema file.

Signed-off-by: Arnaud Patard apatard@hupstream.com

@apatard apatard requested review from a team as code owners September 26, 2022 14:47
@apatard apatard requested review from Shaps, ganeshrn, shatakshiiii, sky-joker and ssbarnea and removed request for a team September 26, 2022 14:47
@ssbarnea ssbarnea added the bug label Sep 26, 2022
Commit "Adopt molecule config JSON schema (ansible#3668)" (acb9ae0)
has imported the molecule schema into data/ but everything is using
src/molecule/schemas/ as directory for the schema.

So:
- Update src/molecule/data/molecule.json with parts of
  src/molecule/schemas/molecule.json content with the one. The update/
  replacement was partial as the local schema handles in a better way
  the MoleculeDependencyModel. The new schema was allowing to use the
  "shell" dependency with an empty command.
- Update schema $id to point to the correct location
- Fix test link to point to the correct schema file.
- Fix path to the schema in schema_v3.py

Signed-off-by: Arnaud Patard <apatard@hupstream.com>
With the new schema file, the schema check doesn't return the same
error strings, so update them.

Signed-off-by: Arnaud Patard <apatard@hupstream.com>
@davedittrich
Copy link
Copy Markdown
Contributor

I believe there is a relationship to PR #3667.

@ssbarnea ssbarnea merged commit be175c5 into ansible:main Sep 30, 2022
davedittrich pushed a commit to davedittrich/molecule that referenced this pull request Oct 24, 2022
* Fix import of molecule schema.

Commit "Adopt molecule config JSON schema (ansible#3668)" (acb9ae0)
has imported the molecule schema into data/ but everything is using
src/molecule/schemas/ as directory for the schema.

So:
- Update src/molecule/data/molecule.json with parts of
  src/molecule/schemas/molecule.json content with the one. The update/
  replacement was partial as the local schema handles in a better way
  the MoleculeDependencyModel. The new schema was allowing to use the
  "shell" dependency with an empty command.
- Update schema $id to point to the correct location
- Fix test link to point to the correct schema file.
- Fix path to the schema in schema_v3.py

Signed-off-by: Arnaud Patard <apatard@hupstream.com>

* rc/molecule/test/unit/model/v2/test_dependency_section.py: Fix checks

With the new schema file, the schema check doesn't return the same
error strings, so update them.

Signed-off-by: Arnaud Patard <apatard@hupstream.com>

Signed-off-by: Arnaud Patard <apatard@hupstream.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants