Page MenuHomeSoftware Heritage

add optional mypy invocation to the CI pipeline (swh-pipeline)
ClosedPublic

Authored by zack on Thu, Oct 3, 8:46 AM.

Details

Summary

Note that this requires mypy to be installed in the "swh-tox" docker image, but
I didn't know how to make sure that's the case. Tips welcome.

Test Plan

I haven't tested it, because I don't know how to. Tips welcome.

Diff Detail

Repository
rCJSWH Jenkins jobs
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

zack created this revision.Thu, Oct 3, 8:46 AM
anlambert accepted this revision.Thu, Oct 3, 10:30 AM
anlambert added a subscriber: anlambert.

Looks good to me.

In order to test the generated XML files for Jenkins are valid, you can run tox at the top level directory of that repository.

To install mypy in the docker image used to run the tests, you have to modify that Dockerfile.
You will have to land the dockerfile change prior to that diff of course.

This revision is now accepted and ready to land.Thu, Oct 3, 10:30 AM
zack added a comment.Thu, Oct 3, 10:38 AM

To install mypy in the docker image used to run the tests, you have to modify that Dockerfile.
You will have to land the dockerfile change prior to that diff of course.

Thanks for the tip.

Although in the end this is actually not needed, as mypy is declared as a dependency in the mypy environments, so tox will take care of installing it as needed. No need to change the docker image. (My bad.)