tools-python icon indicating copy to clipboard operation
tools-python copied to clipboard

changes necessary to validate against SPDX jsonschema

Open dholth opened this issue 2 years ago • 11 comments

These changes were necessary to validate against the SPDX jsonschema https://github.com/spdx/spdx-spec/blob/development/v2.2.2/schemas/spdx-schema.json and to include multiple checksums.

This is a work in progress. No attention has been given to parsing or non-json/yaml formats.

Let me know if this approach is acceptable for the project.

Fixes #184

dholth avatar Nov 12 '21 22:11 dholth

Thank you ++ This works. ... Great and honored to see you drop by!

pombredanne avatar Nov 13 '21 10:11 pombredanne

@pombredanne OK to add Python 3 type annotations? OK to format with black?

dholth avatar Nov 15 '21 15:11 dholth

@pombredanne I think this could be merged. It shoud be able to read/write json that is valid according to the spdx jsonschema, and it should be able to write multiple checksums.

Still open is to read multiple checksums, but that further complicates the code. It would also be nice to add a test that validates the output against the spdx spec using the jsonschema Python package.

dholth avatar Nov 16 '21 02:11 dholth

@pombredanne OK to add Python 3 type annotations? OK to format with black?

I am not too keen but OK wrt. Python 3 type annotations and yes black is fine, but it would be best in a completely separate PR as this would create a "wall" in the history

pombredanne avatar Nov 29 '21 17:11 pombredanne

I think this could be merged. It shoud be able to read/write json that is valid according to the spdx jsonschema, and it should be able to write multiple checksums.

Still open is to read multiple checksums, but that further complicates the code. It would also be nice to add a test that validates the output against the spdx spec using the jsonschema Python package.

Thanks! I will need a few days before I can review.

pombredanne avatar Nov 29 '21 17:11 pombredanne

I am not sure why the macOS tests fail... but Circle CI is a bit flaky at times

pombredanne avatar Dec 15 '21 14:12 pombredanne

macos tests are failing due to using a now-unsupported version of xcode: See #202 for a fix

RodneyRichardson avatar Dec 22 '21 11:12 RodneyRichardson

@pombredanne let us know if you require any updates to this - it would be useful to get it merged! Thanks

nettrino avatar Jul 27 '22 07:07 nettrino

@dholth can you rebase this PR to the latest in the main branch? This should fix the CircleCI errors.

goneall avatar Aug 05 '22 18:08 goneall

CircleCI should be fixed once https://github.com/spdx/tools-python/pull/226 is merged and this PR is rebased on top of the changes.

nicoweidner avatar Sep 06 '22 08:09 nicoweidner

@dholth Will you have time to rebase this PR on main? I'd also be happy to do so if you are short on time.

nicoweidner avatar Oct 14 '22 08:10 nicoweidner

@dholth As you already pointed out this PR doesn't handle parsing or other file formats. Do you plan on working on these things more or are you okay with me working on them?

meretp avatar Oct 25 '22 09:10 meretp

I would be happy for anyone to pick this up, thanks!

dholth avatar Oct 25 '22 13:10 dholth

Thanks for your work @dholth! I openend another PR which continues this one and will close this one.

meretp avatar Oct 27 '22 07:10 meretp