Skip to content

Commit efe3c77

Browse files
committed
MOD: Restore codespell to pre-commit
1 parent f5ddca8 commit efe3c77

File tree

4 files changed

+7
-6
lines changed

4 files changed

+7
-6
lines changed

databento/common/enums.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ def coercible(enum_type: type[M]) -> type[M]:
4040
4141
Notes
4242
-----
43-
This decorator makes some assuptions about your Enum class.
43+
This decorator makes some assumptions about your Enum class.
4444
1. Your attribute names are all UPPERCASE
4545
2. Your attribute values are all lowercase
4646
@@ -100,6 +100,7 @@ def __str__(self) -> str:
100100
return getattr(self, "name").lower()
101101
return getattr(self, "value")
102102

103+
103104
@unique
104105
@coercible
105106
class HistoricalGateway(StringyMixin, str, Enum):

databento/common/validation.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -215,7 +215,7 @@ def validate_semantic_string(value: str, param: str) -> str:
215215
if not value:
216216
raise ValueError(f"The `{param}` cannot be an empty string.")
217217
if str.isspace(value):
218-
raise ValueError(f"The `{param}` cannot contain only whitepsace.")
218+
raise ValueError(f"The `{param}` cannot contain only whitespace.")
219219
if not str.isprintable(value):
220220
raise ValueError(f"The `{param}` cannot contain unprintable characters.")
221221
return value

tests/mock_live_server.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -181,7 +181,7 @@ def peer(self) -> str:
181181
def user_api_keys(self) -> dict[str, str]:
182182
"""
183183
Return a dictionary of user api keys for testing. The keys to this
184-
dictionary are the bucket_ids. The value shoud be a single user API
184+
dictionary are the bucket_ids. The value should be a single user API
185185
key.
186186
187187
Returns
@@ -475,7 +475,7 @@ class MockLiveServer:
475475
-------
476476
create(host="localhost", port=0)
477477
Factory method to create a new MockLiveServer instance.
478-
This is the prefered way to create an instance of
478+
This is the preferred way to create an instance of
479479
this class.
480480
481481
See Also

tests/test_common_symbology.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -321,6 +321,7 @@ def test_instrument_map_insert_metadata_empty_mappings(
321321
# Assert
322322
assert instrument_map._data == {}
323323

324+
324325
@pytest.mark.parametrize(
325326
"stype_in,symbol_in,stype_out,symbol_out,instrument_id,expected_symbol",
326327
[
@@ -374,7 +375,6 @@ def test_instrument_map_insert_symbol_mapping_message_v1(
374375
assert instrument_map.resolve(instrument_id, start_date.date()) == expected_symbol
375376

376377

377-
378378
@pytest.mark.parametrize(
379379
"stype_in,symbol_in,stype_out,symbol_out,instrument_id,expected_symbol",
380380
[
@@ -931,7 +931,7 @@ def test_instrument_map_symbols_json(
931931
schema: Schema,
932932
) -> None:
933933
"""
934-
Test that a JSON file without mapped symbols is equivelant to a JSON file
934+
Test that a JSON file without mapped symbols is equivalent to a JSON file
935935
with mapped symbols after processing with map_symbols_json.
936936
"""
937937
# Arrange, Act

0 commit comments

Comments
 (0)