Skip to content

Commit

Permalink
Drop support for Python 3.8 (#2172)
Browse files Browse the repository at this point in the history
* Drop support for Python 3.8

* Also drop typing_extensions

---------

Co-authored-by: Flavio Curella <[email protected]>
  • Loading branch information
knyghty and fcurella authored Feb 10, 2025
1 parent 18feafc commit be43d1a
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 20 deletions.
4 changes: 1 addition & 3 deletions faker/providers/address/en_IN/__init__.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
from typing import Dict, List, Optional, Tuple

from typing_extensions import TypeAlias

from faker.providers.address import Provider as AddressProvider

Range: TypeAlias = Tuple[int, int]
Range = Tuple[int, int]


class Provider(AddressProvider):
Expand Down
7 changes: 1 addition & 6 deletions faker/providers/ssn/es_MX/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,10 @@
import random
import string

from typing import Optional
from typing import Literal, Optional

from .. import Provider as BaseProvider

try:
from typing import Literal # type: ignore
except ImportError:
from typing_extensions import Literal # type: ignore


ALPHABET = string.ascii_uppercase
ALPHANUMERIC = string.digits + ALPHABET
Expand Down
10 changes: 2 additions & 8 deletions faker/typing.py
Original file line number Diff line number Diff line change
@@ -1,16 +1,10 @@
import dataclasses

Check failure on line 1 in faker/typing.py

View workflow job for this annotation

GitHub Actions / isort

Imports are incorrectly sorted and/or formatted.

from collections import OrderedDict as OrderedDictType
from datetime import date, datetime, timedelta
from typing import Sequence, Union

try:
from typing import List, Literal, TypeVar # type: ignore
except ImportError:
from typing import List

from typing_extensions import Literal, TypeVar # type: ignore

from collections import OrderedDict as OrderedDictType
from typing import List, Literal, TypeVar


class CreditCard:
Expand Down
4 changes: 1 addition & 3 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@
"Development Status :: 5 - Production/Stable",
"Environment :: Console",
"Intended Audience :: Developers",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
Expand Down Expand Up @@ -68,9 +67,8 @@
},
platforms=["any"],
zip_safe=zip_safe,
python_requires=">=3.8",
python_requires=">=3.9",
install_requires=[
"python-dateutil>=2.4",
"typing_extensions",
],
)

0 comments on commit be43d1a

Please sign in to comment.