Skip to content

Commit

Permalink
Make sure black formatting is 3.8 compatible
Browse files Browse the repository at this point in the history
  • Loading branch information
MKuranowski committed Jul 18, 2024
1 parent cbc9e91 commit d0f1085
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 6 deletions.
4 changes: 1 addition & 3 deletions pyroutelib3/osm/graph.py
Original file line number Diff line number Diff line change
Expand Up @@ -311,9 +311,7 @@ def _is_mandatory_restriction(self, relation: reader.Relation) -> bool:
):
return kind == "only"
# fmt: on
raise _InvalidTurnRestriction(
relation, f'unknown "restriction" tag value: {restriction!r}'
)
raise _InvalidTurnRestriction(relation, f'unknown "restriction" tag value: {restriction!r}')

def _get_restriction_nodes(self, r: reader.Relation) -> List[int]:
"""_get_turn_restriction_nodes return a sequence of nodes representing the route
Expand Down
4 changes: 1 addition & 3 deletions pyroutelib3/osm/test_profile.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,7 @@ def test_way_penalty(self) -> None:
self.assertEqual(TEST_HIGHWAY_PROFILE.way_penalty({"highway": "footway"}), 1.0)
self.assertEqual(TEST_HIGHWAY_PROFILE.way_penalty({"highway": "path"}), 2.0)
self.assertIsNone(TEST_HIGHWAY_PROFILE.way_penalty({"highway": "motorway"}))
self.assertIsNone(
TEST_HIGHWAY_PROFILE.way_penalty({"highway": "motorway", "access": "no"})
)
self.assertIsNone(TEST_HIGHWAY_PROFILE.way_penalty({"highway": "motorway", "access": "no"}))
self.assertEqual(
TEST_HIGHWAY_PROFILE.way_penalty(
{"highway": "footway", "access": "private", "cat": "yes"},
Expand Down

0 comments on commit d0f1085

Please sign in to comment.