python-ort 0.1.1__tar.gz → 0.1.3__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of python-ort might be problematic. Click here for more details.

@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: python-ort
3
- Version: 0.1.1
3
+ Version: 0.1.3
4
4
  Summary: A Python Ort model serialization library
5
5
  License-Expression: MIT
6
6
  License-File: LICENSE
@@ -10,7 +10,7 @@ Classifier: Programming Language :: Python :: 3 :: Only
10
10
  Classifier: Programming Language :: Python :: 3.10
11
11
  Classifier: Programming Language :: Python :: 3.11
12
12
  Classifier: Programming Language :: Python :: 3.12
13
- Classifier: Programming Language :: Python :: 3.14
13
+ Classifier: Programming Language :: Python :: 3.13
14
14
  Classifier: Topic :: Software Development :: Libraries :: Python Modules
15
15
  Requires-Dist: pydantic>=2.11.10
16
16
  Requires-Dist: pyyaml>=6.0.3
@@ -7,7 +7,7 @@ packages = ["src/ort"]
7
7
 
8
8
  [project]
9
9
  name = "python-ort"
10
- version = "0.1.1"
10
+ version = "0.1.3"
11
11
  description = "A Python Ort model serialization library"
12
12
  readme = "README.md"
13
13
  license = "MIT"
@@ -24,7 +24,7 @@ classifiers = [
24
24
  "Programming Language :: Python :: 3.10",
25
25
  "Programming Language :: Python :: 3.11",
26
26
  "Programming Language :: Python :: 3.12",
27
- "Programming Language :: Python :: 3.14",
27
+ "Programming Language :: Python :: 3.13",
28
28
  "Topic :: Software Development :: Libraries :: Python Modules",
29
29
  ]
30
30
 
@@ -162,4 +162,5 @@ skip-magic-trailing-comma = false
162
162
  [tool.pyrefly]
163
163
  project_includes = [
164
164
  "src/ort/**",
165
+ "tests/**",
165
166
  ]
@@ -4,14 +4,15 @@
4
4
 
5
5
  from ort.models.analyzer_configurations import OrtAnalyzerConfigurations
6
6
  from ort.models.ort_configuration import OrtConfiguration, Scanner, Severity, Storages
7
- from ort.models.package_manager_configurations import OrtPackageManagerConfigurations
8
- from ort.models.package_managers import OrtPackageManagers
7
+ from ort.models.package_managers import OrtPackageManagerConfigurations, OrtPackageManagers
8
+ from ort.models.repository_configuration import OrtRepositoryConfiguration
9
9
 
10
10
  __all__ = [
11
11
  "OrtAnalyzerConfigurations",
12
+ "OrtConfiguration",
12
13
  "OrtPackageManagerConfigurations",
13
14
  "OrtPackageManagers",
14
- "OrtConfiguration",
15
+ "OrtRepositoryConfiguration",
15
16
  "Scanner",
16
17
  "Severity",
17
18
  "Storages",
@@ -2,20 +2,9 @@
2
2
  # SPDX-License-Identifier: MIT
3
3
 
4
4
 
5
- from typing import Any
6
-
7
5
  from pydantic import AnyUrl, BaseModel, ConfigDict, Field
8
6
 
9
- from .package_manager_configurations import OrtPackageManagerConfigurations
10
- from .package_managers import OrtPackageManagers
11
-
12
-
13
- class PackageManagerConfigs(BaseModel):
14
- model_config = ConfigDict(
15
- extra="forbid",
16
- )
17
- must_run_after: list[OrtPackageManagers] | None = Field(None, alias="mustRunAfter")
18
- options: Any | None = None
7
+ from .package_managers import OrtPackageManagerConfigurations, OrtPackageManagers
19
8
 
20
9
 
21
10
  class Sw360Configuration(BaseModel):
@@ -11,8 +11,7 @@ import yaml
11
11
  import yaml.parser
12
12
  from pydantic import AnyUrl, BaseModel, ConfigDict, Field, RootModel
13
13
 
14
- from .package_manager_configurations import OrtPackageManagerConfigurations
15
- from .package_managers import OrtPackageManagers
14
+ from .package_managers import OrtPackageManagerConfigurations, OrtPackageManagers
16
15
 
17
16
 
18
17
  class AdvisorConfig(RootModel[dict[str, dict[str, Any]] | None]):
@@ -3,9 +3,18 @@
3
3
 
4
4
 
5
5
  from enum import Enum
6
+ from typing import Any
7
+
8
+ from pydantic import BaseModel, ConfigDict, Field, RootModel
6
9
 
7
10
 
8
11
  class OrtPackageManagers(Enum):
12
+ """
13
+ Enumeration of supported package managers in ORT.
14
+
15
+ This enum represents a variety of package managers across different programming ecosystems.
16
+ """
17
+
9
18
  bazel = "Bazel"
10
19
  bower = "Bower"
11
20
  bundler = "Bundler"
@@ -32,3 +41,15 @@ class OrtPackageManagers(Enum):
32
41
  unmanaged = "Unmanaged"
33
42
  yarn = "Yarn"
34
43
  yarn2 = "Yarn2"
44
+
45
+
46
+ class PackageManagerConfigs(BaseModel):
47
+ model_config = ConfigDict(
48
+ extra="forbid",
49
+ )
50
+ must_run_after: list[OrtPackageManagers] | None = Field(None, alias="mustRunAfter")
51
+ options: Any | None = None
52
+
53
+
54
+ class OrtPackageManagerConfigurations(RootModel[dict[str, PackageManagerConfigs]]):
55
+ root: dict[str, PackageManagerConfigs]
@@ -5,11 +5,10 @@
5
5
  from enum import Enum
6
6
  from typing import Any
7
7
 
8
- from pydantic import BaseModel, ConfigDict, Field, RootModel
8
+ from pydantic import BaseModel, Field, RootModel
9
9
 
10
10
  from .analyzer_configurations import OrtAnalyzerConfigurations
11
- from .package_manager_configurations import OrtPackageManagerConfigurations
12
- from .package_managers import OrtPackageManagers
11
+ from .package_managers import OrtPackageManagerConfigurations, PackageManagerConfigs
13
12
 
14
13
 
15
14
  class OrtRepositoryConfigurationLicenseChoicesPackageLicenseChoiceLicenseChoice(BaseModel):
@@ -41,14 +40,6 @@ class OrtRepositoryConfigurationSnippetChoiceChoiceGiven(BaseModel):
41
40
  source_location: OrtRepositoryConfigurationSnippetChoiceChoiceGivenSourceLocation | None = None
42
41
 
43
42
 
44
- class PackageManagerConfigs(BaseModel):
45
- model_config = ConfigDict(
46
- extra="forbid",
47
- )
48
- must_run_after: list[OrtPackageManagers] | None = None
49
- options: Any | None = None
50
-
51
-
52
43
  class IssueResolutionReason(Enum):
53
44
  build_tool_issue = "BUILD_TOOL_ISSUE"
54
45
  cant_fix_issue = "CANT_FIX_ISSUE"
@@ -302,8 +293,8 @@ class ResolutionsSchema(
302
293
  ResolutionsSchemaResolutionsSchema | ResolutionsSchemaResolutionsSchema1 | ResolutionsSchemaResolutionsSchema2
303
294
  ) = Field(
304
295
  ...,
305
- description="The OSS-Review-Toolkit (ORT) provides a possibility to resolve issues, rule violations and"
306
- "security vulnerabilities in a resolutions file. A full list of all available options can be found at"
296
+ description="The OSS-Review-Toolkit (ORT) provides a possibility to resolve issues, rule violations and "
297
+ "security vulnerabilities in a resolutions file. A full list of all available options can be found at "
307
298
  "https://oss-review-toolkit.org/ort/docs/configuration/resolutions.",
308
299
  title="ORT resolutions",
309
300
  )
@@ -341,8 +332,8 @@ class CurationsSchemaCurationsSchemaItem(BaseModel):
341
332
  class CurationsSchema(RootModel[list[CurationsSchemaCurationsSchemaItem]]):
342
333
  root: list[CurationsSchemaCurationsSchemaItem] = Field(
343
334
  ...,
344
- description="The OSS-Review-Toolkit (ORT) provides a possibility to correct metadata and set"
345
- "the concluded license for a specific packages (dependencies) in curation files. A full list of all available"
335
+ description="The OSS-Review-Toolkit (ORT) provides a possibility to correct metadata and set "
336
+ "the concluded license for specific packages (dependencies) in curation files. A full list of all available "
346
337
  "options can be found at https://oss-review-toolkit.org/ort/docs/configuration/package-curations.",
347
338
  title="ORT curations",
348
339
  )
@@ -369,6 +360,18 @@ class OrtRepositoryConfigurationCurations1(BaseModel):
369
360
 
370
361
 
371
362
  class OrtRepositoryConfiguration(BaseModel):
363
+ """
364
+ Represents the configuration for an OSS-Review-Toolkit (ORT) repository.
365
+
366
+ This class defines various configuration options for analyzing, including, excluding,
367
+ resolving, and curating artifacts in a repository. It also provides settings for package
368
+ configurations, license choices, and snippet choices.
369
+
370
+ Usage:
371
+ Instantiate this class to specify repository-level configuration for ORT analysis.
372
+ Each field corresponds to a specific aspect of the repository's configuration.
373
+ """
374
+
372
375
  analyzer: OrtAnalyzerConfigurations | None = None
373
376
  includes: OrtRepositoryConfigurationIncludes | None = Field(
374
377
  None, description="Defines which parts of a repository should be included."
@@ -1,21 +0,0 @@
1
- # SPDX-FileCopyrightText: 2025 Helio Chissini de Castro <heliocastro@gmail.com>
2
- # SPDX-License-Identifier: MIT
3
-
4
-
5
- from typing import Any
6
-
7
- from pydantic import BaseModel, ConfigDict, Field, RootModel
8
-
9
- from .package_managers import OrtPackageManagers
10
-
11
-
12
- class PackageManagerConfigs(BaseModel):
13
- model_config = ConfigDict(
14
- extra="forbid",
15
- )
16
- must_run_after: list[OrtPackageManagers] | None = Field(None, alias="mustRunAfter")
17
- options: Any | None = None
18
-
19
-
20
- class OrtPackageManagerConfigurations(RootModel[dict[str, PackageManagerConfigs]]):
21
- root: dict[str, PackageManagerConfigs]
File without changes
File without changes