8000 Merged the refactoring branch into main by maxhbr · Pull Request #541 · spdx/tools-python · GitHub
[go: up one dir, main page]

Skip to content

Merged the refactoring branch into main #541

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 363 commits into from
Mar 29, 2023
Merged
Changes from 1 commit
Commits
Show all changes
363 commits
Select commit Hold shift + click to select a range
d9edf4d
[issue-359] Add validation to json writer, with the possibility of di…
nicoweidner Dec 30, 2022
ce29322
[issue-359] Add docstrings to some core files
nicoweidner Jan 2, 2023
d77ec7a
[issue-359] Extract common method to get all spdx element ids inside …
nicoweidner Jan 2, 2023
5eb63e4
[issue-359] Use extracted relationship filtering methods in document_…
nicoweidner Jan 2, 2023
b964a17
[issue-388] implement CLI parser/validator
armintaenzertng Jan 2, 2023
c68fbc8
[issue-388] introduce format enum and write_anything.py
armintaenzertng Jan 2, 2023
8f08e0c
[issue-388] implement CLI convertor and rewrite docstrings
armintaenzertng Jan 2, 2023
ca9aee5
[issue-388] remove obsolete tests
armintaenzertng Jan 2, 2023
17fedb6
[issue-388] include json writer
armintaenzertng Jan 3, 2023
aee3e10
[issue-388] rework the CLI user flow
armintaenzertng Jan 3, 2023
a9b6525
[issue-388] merge parser and convertor into a single tool and update …
armintaenzertng Jan 3, 2023
f4c48f7
[issue-397] change fixtures to use valid defaults
armintaenzertng Jan 4, 2023
35ed3d8
[issue-397] replace valid_defaults.py usages with fixtures.py
armintaenzertng Jan 4, 2023
da5705e
[issue-403] change spdx version handling during validation
armintaenzertng Jan 3, 2023
e455066
[issue-403] restructure spdx version validation
armintaenzertng Jan 5, 2023
b930fac
[issue-406] rename json parser package to jsonlikedict
armintaenzertng Jan 3, 2023
6696597
[issue-406] extract json parser and restructure test order
armintaenzertng Jan 3, 2023
b59da62
[issue-406] add xml writer
armintaenzertng Jan 3, 2023
5e65349
[issue-406] add xml parser
armintaenzertng Jan 3, 2023
483f459
[issue-406] add yaml writer
armintaenzertng Jan 3, 2023
ea747c8
[issue-406] add yaml parser
armintaenzertng Jan 3, 2023
3765409
[issue-406] fix xml specific problems, update parse/write_anything
armintaenzertng Jan 3, 2023
664a646
[issue-406] fix copyright texts
armintaenzertng Jan 5, 2023
7dc8024
[issue-267] add GitHub Actions workflow and remove CircleCI
armintaenzertng Jan 4, 2023
1245e22
[issue-267] add pull_request to CI triggers
armintaenzertng Jan 5, 2023
a25a384
[issue-267] remove on push trigger
armintaenzertng Jan 5, 2023
9b4dd28
fix hasExtractedLicensingInfos
armintaenzertng Jan 5, 2023
9034f3d
fix filesAnalyzed parsing
armintaenzertng Jan 5, 2023
533328b
[issue-415] introduce src-layout to fix cli
meretp Jan 9, 2023
7f3cd5e
[issue-415] run cli tool in GitHub action
meretp Jan 9, 2023
6777467
add dummy config.yml to pass pipeline
meretp Jan 10, 2023
904782f
[issue-397] use fixtures in writer tests and enable validation in tes…
meretp Jan 9, 2023
11727e2
[fix] delete unused imports
meretp Jan 9, 2023
0d1dcf5
[issue-420] fix order of mocks to match input arguments
meretp Jan 11, 2023
7b71d90
[issue-392] make usage of license_concluded consistent
meretp Jan 12, 2023
3fbc88b
[issue-400] ignore duplicated relationships while parsing
meretp Jan 12, 2023
1f46bd7
also use the src-layout for tests
meretp Jan 10, 2023
9ae0ebc
move typing to common module to prepare for the prototype of spdx 3.0
meretp Jan 10, 2023
ce6f3d7
[issue-373] implement externalPackageRef validation
armintaenzertng Jan 24, 2023
29cb443
[issue-373] add positive externalPackageRef validation tests
armintaenzertng Jan 24, 2023
740f61e
[issue-373] add negative externalPackageRef validation tests
armintaenzertng Jan 24, 2023
f874c5e
[issue-373] add purl and tests, reformat
armintaenzertng Jan 25, 2023
81dc6a5
[issue-373] refactoring
armintaenzertng Jan 25, 2023
0f86691
[issue-373, review] import regex expressions in tests instead of rede…
armintaenzertng Jan 25, 2023
6b3899f
[issue-373, review] refactoring using dictionaries
armintaenzertng Jan 25, 2023
83ef788
[issue-443] change file name validation logic
armintaenzertng Jan 25, 2023
34fabfd
[issue-442] change CLI to read version from document
armintaenzertng Jan 25, 2023
d53df99
[issue-442, review] except SPDXParsingError and delete CLI prompt
armintaenzertng Jan 26, 2023
603fce4
[issue-10] use license_expression library for LicenseExpression
armintaenzertng Jan 26, 2023
c022620
[issue-10, review] remove error handling in parse_license_expressions
armintaenzertng Jan 27, 2023
22d83c6
[issue-10, review] add write_license_info_list
armintaenzertng Jan 27, 2023
b1cd78c
[refactor] make naming consistent
armintaenzertng Jan 27, 2023
9b3365f
[issue-457] add "no #" requirement to validation messages
armintaenzertng Jan 31, 2023
036d21c
delete unused dependencies und update README.md
meretp Jan 26, 2023
a91aa5a
[issue-407] add writer for rdf, start with simple graph
meretp Jan 23, 2023
60e1a8b
[issue-407] add writer for creation information
meretp Jan 24, 2023
76eb155
[issue-407] add writer for annotations
meretp Jan 24, 2023
b9a9326
[issue-407] connect annotation with spdx element that is annotated
meretp Jan 24, 2023
2a4b4f2
[issue-407] add annotation_type as resource not Literal
meretp Jan 24, 2023
922a2c8
[issue-407] add relationship writer
meretp Jan 24, 2023
ce2995d
[issue-407] add relationship writer to document writer
meretp Jan 24, 2023
ea865b7
[issue-407] add checksum writer
meretp Jan 24, 2023
47fde83
[issue-407] add file writer
meretp Jan 24, 2023
8dbeb2e
[issue-407] fix annotation test
meretp Jan 24, 2023
516bc03
[issue-407] also use add_value_if_exists in creation information
meretp Jan 25, 2023
f5303eb
[issue-407] turn spdx_namespace into a variable
meretp Jan 25, 2023
2dc5fa6
[issue-407, refactor] rename function
meretp Jan 25, 2023
22c6363
[issue-407] add helper functions to handle SpdxNoAssertion and SpdxNone
meretp Jan 25, 2023
d8f1085
[issue-407] add package writer
meretp Jan 25, 2023
670096b
[issue-407] use helper method to transform enum names correctly
meretp Jan 25, 2023
31ecf0c
[issue-407] add transformation from ChecksumAlgorithm to rdf string
meretp Jan 25, 2023
4284dae
[issue-407] add snippet writer
meretp Jan 25, 2023
566ed11
[issue-407] add extracted licensing info writer
meretp Jan 25, 2023
fced6d0
[issue-407] add external document ref writer
meretp Jan 26, 2023
8e61973
[issue-407] bind DOAP namespace to "doap" prefix
meretp Jan 26, 2023
242c069
[issue-407] fix handling of spdx id
meretp Jan 26, 2023
8854204
[issue-407] add rdf writer to CLI
meretp Jan 26, 2023
cd31eab
[issue-407] fix writing of reference_type in ExternalPackageRef
meretp Jan 26, 2023
a0acb4f
[issue-407, refactor] rename
meretp Jan 26, 2023
9e349f3
[issue-407] add ranges writer
meretp Jan 26, 2023
dbf7aba
[issue-407] fix
meretp Jan 26, 2023
6cb2dfd
[issue-407] add rdflib as optional dependency
meretp Jan 26, 2023
fd4f5f9
[issue-407] fix pipeline
meretp Jan 26, 2023
e292530
[issue-407] fix writing of data license
meretp Jan 27, 2023
3ce2f92
[issue-407] fix tests after rebase
meretp Jan 27, 2023
7f6f293
[issue-407] add license expression writer
meretp Jan 30, 2023
eec0a39
[issue-407] delete unused imports
meretp Jan 30, 2023
6afd3c6
[issue-407] refactor
meretp Jan 30, 2023
96617b9
[issue-407] delete debug output from development
meretp Jan 30, 2023
c5ad385
[issue-407, review] make global constants uppercase
meretp Jan 31, 2023
bc9dde7
[issue-407, review] reformat and use positive logic
meretp Jan 31, 2023
f4a13d3
[issue-407, review] also test line_range and set datatype for offset …
meretp Jan 31, 2023
02ba6b2
[issue-407, review] include all parameters in test
meretp Jan 31, 2023
d692fc6
[issue-407, review] rename parameter for clarification
meretp Jan 31, 2023
7fa9cfa
[issue-407, review] add tests for helper function and add error handling
meretp Jan 31, 2023
edab59c
[issue-407, review] rename
meretp Jan 31, 2023
9e283af
[issue-407, review] refactor: change order of arguments and rename so…
meretp Jan 31, 2023
48d8746
[issue-407, review] make comment in pyproject.toml more comprehensible
meretp Jan 31, 2023
af2bcb0
[issue-407, review] rename methods
meretp Jan 31, 2023
c36bf8d
[issue-407, review] use fixture values in assert statements
meretp Jan 31, 2023
bceddae
[issue-407, refactor] introduce module "rdfschema" to use common spdx…
meretp Jan 31, 2023
5d05e4f
[issue-407] add license and reference namespace
meretp Jan 31, 2023
57d9db2
[issue-407, review] inline triple
meretp Feb 1, 2023
e25467f
[issue-407, review] precise tests by using RDF.type as predicate and …
meretp Feb 1, 2023
bb4a265
[issue-378] implement invalidation of duplicated SPDX Ids
armintaenzertng Feb 1, 2023
0c8c30d
[issue-376] add tests for spdx_id_validators
armintaenzertng Feb 1, 2023
f5abfe3
[issue-386] add tests for package_verification_code_validator
armintaenzertng Feb 1, 2023
a0141ed
[issue-386] test "no contains relationship when files_analyzed=False"
armintaenzertng Feb 1, 2023
a47533c
[issue-386] test uppercase checksums/verification codes
armintaenzertng Feb 1, 2023
788e8d4
[issue-375] test "document describes at least one element"
armintaenzertng Feb 1, 2023
5538af9
[issue-466] bug fix and add test
meretp Feb 8, 2023
01dfeaf
[issue-407] write comments for relationships
meretp Feb 8, 2023
d0925d1
fix helper method
meretp Feb 15, 2023
11d2c99
[issue-360] delete examples for specVersion 2.1 which didn't define a…
meretp Feb 14, 2023
fa0c215
[issue-360] fix SBOM example
meretp Feb 14, 2023
20b80dc
[issue-407] add document namespace to unknown types in external packa…
meretp Feb 10, 2023
3e96603
delete rdflib as optional dependency as it is required
meretp Feb 1, 2023
096c77d
delete installation from rdflib as the package is a required dependency
meretp Feb 1, 2023
bba5485
move helper methods to also use it for the rdf parser
meretp Feb 9, 2023
e7deaa1
move actor_parser.py as it is format-agnostic and will be used for js…
meretp Feb 1, 2023
b0e48b5
[issue-456] add creation_info parser
meretp Jan 31, 2023
659b2f7
[issue-456] add graph parsing functions
meretp Feb 1, 2023
c81d14a
[issue-456] add snippet parser
meretp Feb 1, 2023
1be51c4
[issue-456] add checksum parser
meretp Feb 2, 2023
01e9aa2
[issue-456] add external document ref parser
meretp Feb 2, 2023
8d38c3f
[issue-456] add file parser
meretp Feb 2, 2023
cf51202
[issue-456] add annotation parser
meretp Feb 2, 2023
4957223
[issue-456] add package parser
meretp Feb 2, 2023
9ffee30
[issue-456] add package verification code parser
meretp Feb 8, 2023
a03f083
[issue-456] add helper method in casing_tools and move the module as …
meretp Feb 8, 2023
4d58389
[issue-456] add parser for ExternalPackageRefs
meretp Feb 8, 2023
43239b1
[issue-456] use enum helper method for primary package purpose
meretp Feb 8, 2023
ade9eae
[issue-456] use enum helper method for annotation type
meretp Feb 8, 2023
82a0048
[issue-456] use helper method for checksum algorithm
meretp Feb 8, 2023
a40687d
[issue-456] add relationship parser
meretp Feb 8, 2023
41bd9a0
[issue-456] use NamespaceManager to translate external document names…
meretp Feb 9, 2023
9d8d359
[issue-456] add extracted licensing info parser
meretp Feb 9, 2023
0416428
[issue-456] allow no assertion in package download location
meretp Feb 8, 2023
6d4c238
[issue-456, refactor] extract method to get a unique value, sort methods
meretp Feb 9, 2023
effcda1
[issue-456, refactor] replace str_or_no_assertion_or_none with parse …
meretp Feb 9, 2023
cf388fd
[issue-456] add license expression parser
meretp Feb 9, 2023
1f37d61
[issue-456, refactor]
meretp Feb 9, 2023
a946a6a
[issue-456] parse list of license expressions
meretp Feb 9, 2023
7c89824
[issue-456] also parse URIRefs with the documents namespace as prefix…
meretp Feb 9, 2023
5659623
[issue-456] add rdf parser to cli tool
meretp Feb 9, 2023
924a259
[issue-456] delete RDFExample from specVersion 2.1 as the tool curren…
meretp Feb 9, 2023
7b6f956
[issue-456, refactor] use generic helper methods instead of individua…
meretp Feb 9, 2023
7b1c2ac
[issue-456] move actor_parser.py as it is format-agnostic and used fo…
meretp Feb 9, 2023
9623b42
[issue-456, refactor] adapt type hints, delete unused imports, rename…
meretp Feb 9, 2023
2eb4fe6
[issue-456] add helper method to remove prefix to support Python 3.7 …
meretp Feb 9, 2023
3e83f43
[issue-456] allow multiple members in ConjunctiveLicenseSet and Disju…
meretp Feb 10, 2023
be4f647
[issue-456] strip parsed values by default to prevent new lines and l…
meretp Feb 10, 2023
5809fee
[issue-456] fix parsing of externalPackageRef
meretp Feb 10, 2023
fa1630b
fix helper method
meretp Feb 15, 2023
8392a2a
[review] use helper method for enums also for FileType
meretp Feb 20, 2023
2d34f2a
[review, refactor] strip copyright texts, delete trailing comma
meretp Feb 20, 2023
6ff9728
[review] rewrite parse_ranges
meretp Feb 20, 2023
b7e0a99
[review, refactor] let Constructor handle None values and use the mor…
meretp Feb 20, 2023
872ab59
[review] refactor helper methods
meretp Feb 20, 2023
4d6cb59
[issue-463] add validation of v2.3 only package fields
armintaenzertng Feb 2, 2023
a5e8b67
[issue-463] add validation of v2.2 mandatory package fields
armintaenzertng Feb 2, 2023
b5e2096
[issue-463] add validation of v2.2 mandatory file fields
armintaenzertng Feb 2, 2023
ebe47a1
[issue-463] add validation of v2.2 mandatory snippet fields
armintaenzertng Feb 2, 2023
d83275d
[issue-463] fix usage of spdx version during validation
armintaenzertng Feb 2, 2023
5904728
[issue-463] restrict possible SPDX versions to supported versions
armintaenzertng Feb 22, 2023
3c932f6
[issue-463] add validation of v2.3 only checksums
armintaenzertng Feb 22, 2023
f7f3b04
[issue-463] change "version" to "spdx_version"
armintaenzertng Feb 22, 2023
2847969
[issue-463] add validation of v2.3 only externalPackageRef types
armintaenzertng Feb 22, 2023
07b02ba
[issue-463, review] early return for 2.2-unsupported values
armintaenzertng Feb 22, 2023
474b2ef
[issue-463, review] add version handling testcase
armintaenzertng Feb 22, 2023
d1cb667
[autoformat]
armintaenzertng Feb 22, 2023
c8fd2d7
[issue-463, review] cli-tool: catch unsupported SPDX versions early
armintaenzertng Feb 22, 2023
2d71c10
[issue-374] implement license expression validation
armintaenzertng Feb 1, 2023
e428de0
[issue-374] adapt validate_license_expression calls to new usage
armintaenzertng Feb 23, 2023
354faa6
[issue-374, review] more descriptive comments, remove unused LICENSE …
armintaenzertng Feb 27, 2023
3171f1f
[issue-391] update readme to reflect the new usage after refactoring
armintaenzertng Feb 27, 2023
9315e42
[issue-391, review] update readme: "Current state", add license_expre…
armintaenzertng Feb 27, 2023
956cf63
[issue-441] replace print() with logging
armintaenzertng Feb 24, 2023
7a6ee59
[issue-441, review] use logging in rdf creation_info_parser
armintaenzertng Feb 27, 2023
20cc1d8
[fix] use correct value for LicenseListVersion
meretp Mar 2, 2023
27a4f61
fix assertion to test that the dataLicense is correctly added to the …
meretp Feb 20, 2023
eb53826
[issue-382] add lexer
meretp Feb 21, 2023
b823fbc
[issue-382] add tag-value parser
meretp Feb 27, 2023
f0c7ede
[refactor] use pytest fixture instead of class
meretp Feb 27, 2023
23afa89
[issue-382] implement error handling
meretp Feb 28, 2023
20f0a41
[issue-382] catch exception if not all required arguments are provide…
meretp Feb 28, 2023
5b64379
[refactor] tests
meretp Mar 1, 2023
092a067
[issue-382] add test and specify error message
meretp Feb 28, 2023
0efa7b2
[issue-382] refactor relationship_parser
meretp Feb 28, 2023
6312af6
[issue-382] use individual logger for current_element
meretp Feb 28, 2023
e913a98
[issue-382] add helper method to start a new current element
meretp Feb 28, 2023
c18d45f
[issue-382] add test to parse whole document
meretp Feb 28, 2023
8172079
[issue-382] add function to parse_checksum
meretp Feb 28, 2023
89a0f82
[issue-382] add error handling and tests for creation_info_parser
meretp Feb 28, 2023
74da757
[issue-382] add contains relationships
meretp Feb 28, 2023
dd7d499
[issue-382] fix example
meretp Mar 1, 2023
8d1b351
[refactor] build parser when initializing class
meretp Mar 1, 2023
9c9b08d
[issue-382] add tag-value parser to cli tool
meretp Mar 1, 2023
50004b5
[fix] raise error if name is an empty string in actor_parser
meretp Mar 1, 2023
46731ff
[issue-382] check that current element matches class of parsed value
meretp Mar 1, 2023
43e8dd3
[issue-382] add negative test for annotation_parser
meretp Mar 1, 2023
c39e516
[issue-382] add negative tests for extracted_licensing_info
meretp Mar 1, 2023
ce2687d
[issue-382] rename parsing methods
meretp Mar 1, 2023
d3d3200
[refactor] merge parsing functions that return the same values
meretp Mar 1, 2023
055dce2
[refactor] creation_info_parser
meretp Mar 1, 2023
e019c2d
[refactor] use helper method to set unique values
meretp Mar 1, 2023
d566d99
[refactor] merge parsing methods for package dates
meretp Mar 1, 2023
a746a5a
[issue-382] rename tests
meretp Mar 2, 2023
09e1e8e
[issue-382] add negative tests for snippet_parser
meretp Mar 2, 2023
b9b776f
[issue-382] add negative tests for package parser
meretp Mar 3, 2023
e724eb5
[issue-382] merge parsing methods
meretp Mar 3, 2023
925492c
[issue-382] add tests for contains relationship
meretp Mar 2, 2023
bd15f71
[issue-382] reformat
meretp Mar 2, 2023
c9b718d
[issue-382] use tag-value parser to test tag-value writer
meretp Mar 2, 2023
be1b3e5
[issue-382] fix logging
meretp Mar 2, 2023
739b23d
[issue-382] delete element_stack as it is not needed
meretp Mar 3, 2023
5c431a8
[issue-382] add line number to error messages
meretp Mar 3, 2023
f34af92
squashed review commits concerning test improvement
meretp Mar 3, 2023
4e279f6
[review] fix type hint, parse_checksum and add test for the latter
meretp Mar 8, 2023
bafc163
squashed review commits concerning the tag value parser
meretp Mar 8, 2023
8039b09
squashed review commits concerning structure of the tag value parser
meretp Mar 8, 2023
08ad4df
squashed review commits concerning structure, double quotes and naming
meretp Mar 8, 2023
af58dfa
squashed review commits with name fixes and comment improvement
meretp Mar 9, 2023
e5af2eb
squashed review commits
meretp Mar 9, 2023
8000
752e964
[issue-228] make type hints in code readable for downstream packages
meretp Mar 10, 2023
0aff1b5
[fix] move "py.typed" to package root directory
meretp Mar 10, 2023
5d3cab0
[fix] write LicenseListVersion only when provided
meretp Mar 10, 2023
2624690
[issue-394] add tests for creation info writer
meretp Mar 10, 2023
08b447d
[refactor] use f-strings, double quotes and more descriptive variable…
meretp Mar 10, 2023
34d0045
[issue-518] rename file_type to file_types
armintaenzertng Mar 10, 2023
4a0675f
[issue-503] validate license_expressions only as a List of LicenseExp…
meretp Mar 3, 2023
66a3355
[issue-503] fix: correct type for LicenseInfoInSnippet in Snippet
meretp Mar 3, 2023
dcfc471
[issue-503] fix: correct type for LicenseInfoFromFiles in Package
meretp Mar 3, 2023
44250c1
[issue-503] fix: correct type for LicenseInfoInFile in File
meretp Mar 3, 2023
8d2f497
[issue-503] fix: delete helper method as we don't need to distinguish…
meretp Mar 3, 2023
91b05dc
fixed the version of typeguard as 3.0.0 introduces breaking changes
armintaenzertng Mar 15, 2023
ea92a1c
Added convenience function to extract SPDX elements by their Id
HarshvMahawar Mar 23, 2023
9f998b9
[issue-402] add validation option to tag-value writer
meretp Mar 28, 2023
d1c01f8
[issue-402] drop spdx version as input argument as it is automaticall…
meretp Mar 28, 2023
1d84bcb
[fix] add python 3.11 to GitHub Action
meretp Mar 29, 2023
2261824
[fix] also run GitHub Action after merge
meretp Mar 29, 2023
ba2c580
Create dependabot.yml
goneall Mar 16, 2023
b132d32
update changelog for v0.7.1
armintaenzertng Mar 14, 2023
de1e86e
[issue-468] add a step to fork the repository
meretp Feb 9, 2023
3019702
delete unused test data
armintaenzertng Mar 29, 2023
9158ecb
delete unused license lists and corresponding files
armintaenzertng Mar 29, 2023
69e938a
change DATE to ISO8601_DATE, don't inherit from object
armintaenzertng Mar 24, 2023
563196d
update README for when the refactor branch is merged to main
armintaenzertng Mar 29, 2023
63dc18a
[issue-487] add tests for the document_utils module
armintaenzertng Mar 24, 2023
3f2619c
Merge branch 'refactor-python-tools'
maxhbr Mar 29, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
[fix] also run GitHub Action after merge
Signed-off-by: Meret Behrens <meret.behrens@tngtech.com>
  • Loading branch information
meretp committed Mar 29, 2023
commit 22618247df67b56ad5be976a21939b349bc21d7e
7 changes: 6 additions & 1 deletion .github/workflows/install_and_test.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
name: Install and Test

on: [ workflow_dispatch, pull_request ]
on:
push:
branches:
- refactor-python-tools
pull_request:
workflow_dispatch:

jobs:
install_and_test:
Expand Down
0