Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
4 changes: 2 additions & 2 deletions pydantic_extra_types/color.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
"""Color definitions are used as per the CSS3
[CSS Color Module Level 3](http://www.w3.org/TR/css3-color/#svg-color) specification.

A few colors have multiple names referring to the sames colors, eg. `grey` and `gray` or `aqua` and `cyan`.
A few colors have multiple names referring to the same colors, e.g. `grey` and `gray` or `aqua` and `cyan`.

In these cases the _last_ color when sorted alphabetically takes preferences,
In these cases the _last_ color when sorted alphabetically takes precedence.
eg. `Color((0, 255, 255)).as_named() == 'cyan'` because "cyan" comes after "aqua".
"""

Expand Down
2 changes: 1 addition & 1 deletion pydantic_extra_types/s3.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
class S3Path(str):
"""An object representing a valid S3 path.
This type also allows you to access the `bucket` and `key` component of the S3 path.
It also contains the `last_key` which represents the last part of the path (tipically a file).
It also contains the `last_key` which represents the last part of the path (typically a file).

```python
from pydantic import BaseModel
Expand Down
4 changes: 2 additions & 2 deletions tests/test_coordinate.py
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ def test_limit_for_coordinate(coord: (Any, Any), error: Optional[Pattern]):
('-90.0', True),
(Decimal('90.0'), True),
(Decimal('-90.0'), True),
# Unvalid latitude
# Invalid latitude
(91.0, False),
(-91.0, False),
(Decimal('91.0'), False),
Expand Down Expand Up @@ -144,7 +144,7 @@ def test_format_latitude(latitude: float, valid: bool):
(-180.0, True),
(Decimal('180.0'), True),
(Decimal('-180.0'), True),
# Unvalid latitude
# Invalid latitude
(181.0, False),
(-181.0, False),
(Decimal('181.0'), False),
Expand Down
2 changes: 1 addition & 1 deletion tests/test_pendulum_dt.py
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@ def test_pendulum_dt_from_serialized_preserves_timezones(dt):
pendulum.now().to_iso8601_string(),
pendulum.now().to_w3c_string(),
'Sat Oct 11 17:13:46 UTC 2003', # date util parsing
pendulum.now().to_iso8601_string()[:5], # actualy valid or pendulum.parse(dt, strict=False) would fail here
pendulum.now().to_iso8601_string()[:5], # actually valid or pendulum.parse(dt, strict=False) would fail here
],
)
def test_pendulum_dt_not_strict_from_serialized(dt):
Expand Down