Skip to content

Commit ec36a13

Browse files
Fix for gha:validation error in Github actions (RDFLib#2799)
* Quote boolean variables * Update broken poetry.lock * Black reformat * Revert update of lock file, only fix invalid statement * Fix unreachable code block --------- Co-authored-by: Nicholas Car <[email protected]>
1 parent fcfc2aa commit ec36a13

File tree

5 files changed

+31
-32
lines changed

5 files changed

+31
-32
lines changed

Taskfile.yml

+3-3
Original file line numberDiff line numberDiff line change
@@ -139,14 +139,14 @@ tasks:
139139
desc: Fix auto-fixable linting errors
140140
cmds:
141141
- task: ruff
142-
vars: { FIX: true }
142+
vars: { FIX: "true" }
143143
- task: black
144144

145145
lint:
146146
desc: Perform linting
147147
cmds:
148148
- task: black
149-
vars: { CHECK: true }
149+
vars: { CHECK: "true" }
150150
- task: ruff
151151

152152
validate:static:
@@ -250,7 +250,7 @@ tasks:
250250
- task: install:system-deps
251251
- task: install:tox
252252
vars:
253-
WITH_GITHUB_ACTIONS: true
253+
WITH_GITHUB_ACTIONS: "true"
254254
- cmd: "{{.PYTHON}} -m pip install coveralls"
255255
- task: tox
256256
vars:

poetry.lock

+2-6
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

rdflib/namespace/_GEO.py

+25-18
Original file line numberDiff line numberDiff line change
@@ -32,12 +32,11 @@ class GEO(DefinedNamespace):
3232
kmlLiteral: URIRef # A KML serialization of a geometry object.
3333
wktLiteral: URIRef # A Well-known Text serialization of a geometry object.
3434

35-
3635
# http://www.w3.org/2002/07/owl#Class
3736
Feature: URIRef # This class represents the top-level feature type. This class is equivalent to GFI_Feature defined in ISO 19156:2011, and it is superclass of all feature types.
38-
FeatureCollection: URIRef # A collection of individual Features.
37+
FeatureCollection: URIRef # A collection of individual Features.
3938
Geometry: URIRef # The class represents the top-level geometry type. This class is equivalent to the UML class GM_Object defined in ISO 19107, and it is superclass of all geometry types.
40-
GeometryCollection: URIRef # A collection of individual Geometries.
39+
GeometryCollection: URIRef # A collection of individual Geometries.
4140
SpatialObject: URIRef # The class spatial-object represents everything that can have a spatial representation. It is superclass of feature and geometry.
4241
SpatialObjectCollection: URIRef # A collection of individual Spatial Objects. This is the superclass of Feature Collection and Geometry Collection.
4342

@@ -49,13 +48,17 @@ class GEO(DefinedNamespace):
4948
asDGGS: URIRef # The DGGS serialization of a geometry
5049
coordinateDimension: URIRef # The number of measurements or axes needed to describe the position of this geometry in a coordinate system.
5150
dimension: URIRef # The topological dimension of this geometric object, which must be less than or equal to the coordinate dimension. In non-homogeneous collections, this will return the largest topological dimension of the contained objects.
52-
hasMetricArea: URIRef # The area of a Spatial Object in square meters.
53-
hasMetricLength: URIRef # The length of a Spatial Object in meters.
54-
hasMetricPerimeterLength: URIRef # The length of the perimeter of a Spatial Object in meters.
55-
hasMetricSpatialAccuracy: URIRef # The spatial resolution of a Geometry in meters.
56-
hasMetricSpatialResolution: URIRef # The spatial resolution of a Geometry in meters.
57-
hasMetricSize: URIRef # Subproperties of this property are used to indicate the size of a Spatial Object as a measurement or estimate of one or more dimensions of the Spatial Object's spatial presence. Units are always metric (meter, square meter or cubic meter)
58-
hasMetricVolume: URIRef # The volume of a Spatial Object in cubic meters.
51+
hasMetricArea: URIRef # The area of a Spatial Object in square meters.
52+
hasMetricLength: URIRef # The length of a Spatial Object in meters.
53+
hasMetricPerimeterLength: (
54+
URIRef # The length of the perimeter of a Spatial Object in meters.
55+
)
56+
hasMetricSpatialAccuracy: URIRef # The spatial resolution of a Geometry in meters.
57+
hasMetricSpatialResolution: (
58+
URIRef # The spatial resolution of a Geometry in meters.
59+
)
60+
hasMetricSize: URIRef # Subproperties of this property are used to indicate the size of a Spatial Object as a measurement or estimate of one or more dimensions of the Spatial Object's spatial presence. Units are always metric (meter, square meter or cubic meter)
61+
hasMetricVolume: URIRef # The volume of a Spatial Object in cubic meters.
5962
hasSerialization: (
6063
URIRef # Connects a geometry object with its text-based serialization.
6164
)
@@ -73,17 +76,21 @@ class GEO(DefinedNamespace):
7376
ehInside: URIRef # Exists if the subject SpatialObject is spatially inside the object SpatialObject. DE-9IM: TFF*FFT**
7477
ehMeet: URIRef # Exists if the subject SpatialObject spatially meets the object SpatialObject. DE-9IM: FT******* ^ F**T***** ^ F***T****
7578
ehOverlap: URIRef # Exists if the subject SpatialObject spatially overlaps the object SpatialObject. DE-9IM: T*T***T**
76-
hasArea: URIRef # The area of a Spatial Object.
77-
hasBoundingBox: URIRef # The minimum or smallest bounding or enclosing box of a given Feature.
78-
hasCentroid: URIRef # The arithmetic mean position of all the geometry points of a given Feature.
79+
hasArea: URIRef # The area of a Spatial Object.
80+
hasBoundingBox: (
81+
URIRef # The minimum or smallest bounding or enclosing box of a given Feature.
82+
)
83+
hasCentroid: URIRef # The arithmetic mean position of all the geometry points of a given Feature.
7984
hasDefaultGeometry: URIRef # The default geometry to be used in spatial calculations, usually the most detailed geometry.
8085
hasGeometry: URIRef # A spatial representation for a given feature.
81-
hasLength: URIRef # The length of a Spatial Object.
82-
hasPerimeterLength: URIRef # The length of the perimeter of a Spatial Object.
86+
hasLength: URIRef # The length of a Spatial Object.
87+
hasPerimeterLength: URIRef # The length of the perimeter of a Spatial Object.
8388
hasSize: URIRef # Subproperties of this property are used to indicate the size of a Spatial Object as a measurement or estimate of one or more dimensions of the Spatial Object's spatial presence.
84-
hasSpatialAccuracy: URIRef # The positional accuracy of the coordinates of a Geometry.
85-
hasSpatialResolution: URIRef # The spatial resolution of a Geometry.
86-
hasVolume: URIRef # he volume of a three-dimensional Spatial Object.
89+
hasSpatialAccuracy: (
90+
URIRef # The positional accuracy of the coordinates of a Geometry.
91+
)
92+
hasSpatialResolution: URIRef # The spatial resolution of a Geometry.
93+
hasVolume: URIRef # he volume of a three-dimensional Spatial Object.
8794
rcc8dc: URIRef # Exists if the subject SpatialObject is spatially disjoint from the object SpatialObject. DE-9IM: FFTFFTTTT
8895
rcc8ec: URIRef # Exists if the subject SpatialObject spatially meets the object SpatialObject. DE-9IM: FFTFTTTTT
8996
rcc8eq: URIRef # Exists if the subject SpatialObject spatially equals the object SpatialObject. DE-9IM: TFFFTFFFT

rdflib/plugins/parsers/jsonld.py

+1-3
Original file line numberDiff line numberDiff line change
@@ -403,9 +403,7 @@ def _parse_container(
403403
(
404404
dict({GRAPH: o})
405405
if k in context.get_keys(NONE)
406-
else dict({ID: k, GRAPH: o})
407-
if isinstance(o, dict)
408-
else o
406+
else dict({ID: k, GRAPH: o}) if isinstance(o, dict) else o
409407
)
410408
for k, o in obj.items()
411409
]

rdflib/plugins/sparql/algebra.py

-2
Original file line numberDiff line numberDiff line change
@@ -1007,8 +1007,6 @@ def convert_node_arg(
10071007
return node_arg.n3()
10081008
elif isinstance(node_arg, CompValue):
10091009
return "{" + node_arg.name + "}"
1010-
elif isinstance(node_arg, Expr):
1011-
return "{" + node_arg.name + "}"
10121010
elif isinstance(node_arg, str):
10131011
return node_arg
10141012
else:

0 commit comments

Comments
 (0)