Skip to content

Commit 4ceac88

Browse files
committed
Version 1.15.0.0, python 3.9+
1 parent 070e67b commit 4ceac88

File tree

11 files changed

+27
-22
lines changed

11 files changed

+27
-22
lines changed

.circleci/config.yml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ executors:
88
parameters:
99
v:
1010
type: string
11-
default: "3.8"
11+
default: "3.9"
1212

1313
docker:
1414
- image: cimg/python:<< parameters.v >>
@@ -101,7 +101,7 @@ jobs:
101101
deploy:
102102
executor: bitcart/docker-python
103103
docker:
104-
- image: cimg/python:3.8
104+
- image: cimg/python:3.9
105105
steps:
106106
- checkout
107107

@@ -135,7 +135,6 @@ workflows:
135135
matrix:
136136
parameters:
137137
v:
138-
- "3.8"
139138
- "3.9"
140139
- "3.10"
141140
- "3.11"

.pre-commit-config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ repos:
2323
rev: v3.15.1
2424
hooks:
2525
- id: pyupgrade
26-
args: ["--py38-plus"]
26+
args: ["--py39-plus"]
2727
- repo: https://github.com/pre-commit/pre-commit-hooks
2828
rev: v4.5.0
2929
hooks:

.readthedocs.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ version: 2
33
build:
44
os: ubuntu-22.04
55
tools:
6-
python: "3.8"
6+
python: "3.9"
77

88
sphinx:
99
configuration: docs/conf.py

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22

33
## Latest changes
44

5+
## 1.15.0.0
6+
7+
We now support Python >= 3.9 only
8+
59
## 1.14.0.1
610

711
Don't install a separate tests package, but include tests in source tarball

bitcart/coin.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
1-
from typing import Callable, Dict, Optional
1+
from typing import Callable, Optional
22

33

44
class Coin:
55
coin_name: str
66
xpub_name: str
77
friendly_name: str
8-
event_handlers: Dict[str, Callable]
8+
event_handlers: dict[str, Callable]
99
xpub: Optional[str]
1010

1111
def __eq__(self, other: object) -> bool:

bitcart/coins/btc.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import inspect
2+
from collections.abc import Iterable
23
from functools import wraps
3-
from typing import TYPE_CHECKING, Any, Callable, Dict, Iterable, List, Optional, Union
4+
from typing import TYPE_CHECKING, Any, Callable, Optional, Union
45

56
from ..coin import Coin
67
from ..errors import LightningDisabledError
@@ -38,7 +39,7 @@ class BTC(Coin, EventDelivery):
3839
BALANCE_ATTRS = ["confirmed", "unconfirmed", "unmatured", "lightning"]
3940
EXPIRATION_KEY = "expiry"
4041
is_eth_based = False
41-
additional_xpub_fields: List[str] = []
42+
additional_xpub_fields: list[str] = []
4243

4344
def __init__(
4445
self,
@@ -55,7 +56,7 @@ def __init__(
5556
self.rpc_user = rpc_user or self.RPC_USER
5657
self.rpc_pass = rpc_pass or self.RPC_PASS
5758
self.xpub = xpub
58-
self.event_handlers: Dict[str, Callable] = {}
59+
self.event_handlers: dict[str, Callable] = {}
5960
self.amount_field = getattr(self, "AMOUNT_FIELD", f"amount_{self.coin_name}")
6061
self.server = RPCProxy(self.rpc_url, self.rpc_user, self.rpc_pass, self.xpub, session=session, proxy=proxy)
6162

bitcart/event_delivery.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
import asyncio
22
import traceback
3+
from collections.abc import Iterable
34
from json import JSONDecodeError
4-
from typing import TYPE_CHECKING, Callable, Dict, Iterable, Optional, Union
5+
from typing import TYPE_CHECKING, Callable, Optional, Union
56
from urllib.parse import urljoin
67

78
from aiohttp import ClientConnectionError, WSMsgType
@@ -18,7 +19,7 @@
1819

1920
class EventDelivery:
2021
server: "RPCProxy"
21-
event_handlers: Dict[str, Callable]
22+
event_handlers: dict[str, Callable]
2223

2324
async def process_updates(
2425
self, updates: Iterable[dict], currency: Optional[str] = None, wallet: Optional[str] = None

bitcart/manager.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import asyncio
2+
from collections.abc import Iterable
23
from functools import partial
3-
from typing import TYPE_CHECKING, Any, Callable, Dict, Iterable, Optional
4+
from typing import TYPE_CHECKING, Any, Callable, Optional
45
from urllib.parse import urljoin
56

67
from bitcart.errors import CurrencyUnsupportedError, NoCurrenciesRegisteredError
@@ -18,7 +19,7 @@
1819

1920

2021
class APIManager(EventDelivery):
21-
def __init__(self, wallets: Dict[str, Iterable[str]] = {}, custom_params: Dict[str, dict] = {}):
22+
def __init__(self, wallets: dict[str, Iterable[str]] = {}, custom_params: dict[str, dict] = {}):
2223
super().__init__()
2324
self.custom_params = custom_params
2425
self.wallets = ExtendedDefaultDict(

bitcart/providers/jsonrpcrequests.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import asyncio
2-
from typing import Any, Callable, Dict, Optional, Union
2+
from typing import Any, Callable, Optional, Union
33
from urllib.parse import urljoin
44

55
import aiohttp
@@ -44,7 +44,7 @@ def __init__(
4444
self._connector_init = dict(ssl=self.verify)
4545
self._spec = {"exceptions": {"-32600": {"exc_name": "UnauthorizedError", "docstring": "Unauthorized"}}}
4646
self._spec_valid = False
47-
self._sessions: Dict[asyncio.AbstractEventLoop, aiohttp.ClientSession] = {}
47+
self._sessions: dict[asyncio.AbstractEventLoop, aiohttp.ClientSession] = {}
4848
if session is not None:
4949
self._sessions[get_event_loop()] = session
5050

examples/atomic_tipbot/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ The bot is available in telegram at @bitcart_atomic_tipbot
66

77
Used tools:
88

9-
- Python 3.8+
9+
- Python 3.9+
1010
- Mongo DB
1111
- Pyrogram(for bot)
1212
- qrcode library for generating qr codes
@@ -17,7 +17,7 @@ This bot is rewritten in my style, using modern python 3.6+ f-strings, and of co
1717

1818
## Installation
1919

20-
To get started, you will need to have [Python 3.8+](https://python.org) installed, of course. Using virtualenv is recommended.
20+
To get started, you will need to have [Python 3.9+](https://python.org) installed, of course. Using virtualenv is recommended.
2121
Install Mongo DB using it's installation [guide](https://docs.mongodb.com/manual/administration/install-community)
2222
After that, install dependencies of this example using:
2323

@@ -72,7 +72,7 @@ If you will later need to stop them, run `./stop.sh`
7272

7373
### Manual way
7474

75-
As for this example, Python 3.8+ is required. Using virtualenv is recommended.
75+
As for this example, Python 3.9+ is required. Using virtualenv is recommended.
7676

7777
Clone Bitcart repository:
7878

setup.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
setup(
44
name="bitcart",
55
packages=find_packages(exclude=["tests", "tests.*"]),
6-
version="1.14.0.1",
6+
version="1.15.0.0",
77
license="MIT",
88
description="Bitcart coins support library",
99
long_description=open("README.md").read(),
@@ -21,11 +21,10 @@
2121
"Topic :: Software Development :: Build Tools",
2222
"License :: OSI Approved :: MIT License",
2323
"Programming Language :: Python :: 3",
24-
"Programming Language :: Python :: 3.8",
2524
"Programming Language :: Python :: 3.9",
2625
"Programming Language :: Python :: 3.10",
2726
"Programming Language :: Python :: 3.11",
2827
"Programming Language :: Python :: 3.12",
2928
],
30-
python_requires=">=3.8",
29+
python_requires=">=3.9",
3130
)

0 commit comments

Comments
 (0)