Skip to content

Commit

Permalink
Allow dependencies/optional-dependencies to use file directives (#37)
Browse files Browse the repository at this point in the history
  • Loading branch information
abravalheri committed Apr 8, 2022
2 parents 7b23a78 + 61b668f commit a765300
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/validate_pyproject/plugins/setuptools.schema.json
Expand Up @@ -199,7 +199,14 @@
},
"classifiers": {"$ref": "#/definitions/file-directive"},
"description": {"$ref": "#/definitions/file-directive"},
"dependencies": {"$ref": "#/definitions/file-directive"},
"entry-points": {"$ref": "#/definitions/file-directive"},
"optional-dependencies": {
"type": "object",
"propertyNames": {"format": "pep508-identifier"},
"additionalProperties": false,
"patternProperties": {".+": {"$ref": "#/definitions/file-directive"}}
},
"readme": {
"anyOf": [
{"$ref": "#/definitions/file-directive"},
Expand Down
@@ -0,0 +1,3 @@
`tool.setuptools.dynamic.optional-dependencies` keys must be named by:

{format: 'pep508-identifier'}
@@ -0,0 +1,7 @@
[project]
name = "myproj"
version = "42"
dynamic = ["optional-dependencies"]

[tool.setuptools.dynamic.optional-dependencies."non pep508 compliant"]
file = "extra.txt"

0 comments on commit a765300

Please sign in to comment.