Skip to content

Commit bb8d4a3

Browse files
Merge branch 'release/v2.6.0'
2 parents ef2131e + b12aa1e commit bb8d4a3

21 files changed

+490
-156
lines changed

.circleci/config.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,11 @@ workflows:
99
- unit-test:
1010
matrix:
1111
parameters:
12-
python-version: ["3.8", "3.9", "3.10", "3.11"]
12+
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"]
1313
- integration-test:
1414
matrix:
1515
parameters:
16-
python-version: ["3.8", "3.9", "3.10", "3.11"]
16+
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"]
1717
- docset
1818

1919
jobs:

CHANGELOG.md

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,32 @@
11
# Changelog
22

3+
# v2.6.0
4+
5+
<!-- Release notes generated using configuration in .github/release.yml at release/v2.6.0 -->
6+
7+
## What's Changed
8+
### Bugfixes
9+
* fix: no timeout for urlopen issue #526 by @grzracz in https://github.com/algorand/py-algorand-sdk/pull/527
10+
* txns: Uses sp.min_fee if available by @jannotti in https://github.com/algorand/py-algorand-sdk/pull/530
11+
* fix: Fix initialization for `WrongAmountType` error by @algolog in https://github.com/algorand/py-algorand-sdk/pull/532
12+
* Fix: Fix indexer sync issue in cucumber tests by @jasonpaulos in https://github.com/algorand/py-algorand-sdk/pull/533
13+
### Enhancements
14+
* Docs: Add missing pages for source map and dryrun results by @jasonpaulos in https://github.com/algorand/py-algorand-sdk/pull/520
15+
* DX: Keyreg bytes by @jannotti in https://github.com/algorand/py-algorand-sdk/pull/522
16+
* Testing: Add Python 3.12 to test matrix by @jasonpaulos in https://github.com/algorand/py-algorand-sdk/pull/534
17+
* Simulate: Support newer simulate options by @jasonpaulos in https://github.com/algorand/py-algorand-sdk/pull/537
18+
* Tests: Enable min-balance Cucumber tests. by @gmalouf in https://github.com/algorand/py-algorand-sdk/pull/539
19+
### Other
20+
* Fix typographic error when printing offline participation transaction by @hsoerensen in https://github.com/algorand/py-algorand-sdk/pull/524
21+
22+
## New Contributors
23+
* @hsoerensen made their first contribution in https://github.com/algorand/py-algorand-sdk/pull/524
24+
* @grzracz made their first contribution in https://github.com/algorand/py-algorand-sdk/pull/527
25+
* @algolog made their first contribution in https://github.com/algorand/py-algorand-sdk/pull/532
26+
* @gmalouf made their first contribution in https://github.com/algorand/py-algorand-sdk/pull/539
27+
28+
**Full Changelog**: https://github.com/algorand/py-algorand-sdk/compare/v2.5.0...v2.6.0
29+
330
# v2.5.0
431

532
<!-- Release notes generated using configuration in .github/release.yml at release/v2.5.0 -->

algosdk/atomic_transaction_composer.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -272,11 +272,13 @@ def __init__(
272272
max_log_calls: Optional[int] = None,
273273
max_log_size: Optional[int] = None,
274274
allow_empty_signatures: Optional[bool] = None,
275+
allow_unnamed_resources: Optional[bool] = None,
275276
extra_opcode_budget: Optional[int] = None,
276277
) -> None:
277278
self.max_log_calls = max_log_calls
278279
self.max_log_size = max_log_size
279280
self.allow_empty_signatures = allow_empty_signatures
281+
self.allow_unnamed_resources = allow_unnamed_resources
280282
self.extra_opcode_budget = extra_opcode_budget
281283

282284
@staticmethod
@@ -297,6 +299,10 @@ def from_simulation_result(
297299
eval_override.allow_empty_signatures = eval_override_dict[
298300
"allow-empty-signatures"
299301
]
302+
if "allow-unnamed-resources" in eval_override_dict:
303+
eval_override.allow_unnamed_resources = eval_override_dict[
304+
"allow-unnamed-resources"
305+
]
300306
if "extra-opcode-budget" in eval_override_dict:
301307
eval_override.extra_opcode_budget = eval_override_dict[
302308
"extra-opcode-budget"

algosdk/error.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ def __init__(self):
4848

4949

5050
class WrongAmountType(Exception):
51-
def __init(self):
51+
def __init__(self):
5252
Exception.__init__(self, "amount (amt) must be a non-negative integer")
5353

5454

@@ -70,7 +70,7 @@ def __init__(self):
7070
class WrongHashLengthError(Exception):
7171
"""General error that is normally changed to be more specific"""
7272

73-
def __init(self):
73+
def __init__(self):
7474
Exception.__init__(self, "length must be 32 bytes")
7575

7676

@@ -85,22 +85,22 @@ def __init__(self):
8585

8686

8787
class WrongMetadataLengthError(Exception):
88-
def __init(self):
88+
def __init__(self):
8989
Exception.__init__(self, "metadata length must be 32 bytes")
9090

9191

9292
class WrongLeaseLengthError(Exception):
93-
def __init(self):
93+
def __init__(self):
9494
Exception.__init__(self, "lease length must be 32 bytes")
9595

9696

9797
class WrongNoteType(Exception):
98-
def __init(self):
98+
def __init__(self):
9999
Exception.__init__(self, 'note must be of type "bytes"')
100100

101101

102102
class WrongNoteLength(Exception):
103-
def __init(self):
103+
def __init__(self):
104104
Exception.__init__(self, "note length must be at most 1024")
105105

106106

algosdk/kmd.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ def __init__(self, kmd_token, kmd_address):
2626
self.kmd_token = kmd_token
2727
self.kmd_address = kmd_address
2828

29-
def kmd_request(self, method, requrl, params=None, data=None):
29+
def kmd_request(self, method, requrl, params=None, data=None, timeout=30):
3030
"""
3131
Execute a given request.
3232
@@ -35,6 +35,7 @@ def kmd_request(self, method, requrl, params=None, data=None):
3535
requrl (str): url for the request
3636
params (dict, optional): parameters for the request
3737
data (dict, optional): data in the body of the request
38+
timeout (int, optional): request timeout in seconds
3839
3940
Returns:
4041
dict: loaded from json response body
@@ -56,7 +57,7 @@ def kmd_request(self, method, requrl, params=None, data=None):
5657
)
5758
resp = None
5859
try:
59-
resp = urlopen(req)
60+
resp = urlopen(req, timeout=timeout)
6061
except urllib.error.HTTPError as e:
6162
e = e.read().decode("utf-8")
6263
try:

0 commit comments

Comments
 (0)