Skip to content

Commit d7d184e

Browse files
committed
Release 2.0.2
1 parent 93110a3 commit d7d184e

File tree

5 files changed

+23
-9
lines changed

5 files changed

+23
-9
lines changed

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,12 @@ All notable changes to this project will be documented in this file.
44
The format is based on [Keep a Changelog](http://keepachangelog.com/)
55
and this project adheres to [Semantic Versioning](http://semver.org/).
66

7+
## [2.0.2] - 2025-05-21
8+
9+
### Fixed
10+
11+
- #49: database host configuration not work with version 2
12+
713
## [2.0.1] - 2025-05-05
814

915
### Fixed

docs/changelog.txt

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,11 @@
22
Changelog
33
#########
44

5+
Version 2.0.2
6+
=============
7+
8+
- #49: database host configuration not work with version 2
9+
510
Version 2.0.1
611
=============
712

pyproject.toml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,9 @@ dependencies = [
5757

5858
[tool.hatch.envs.hatch-test]
5959
extra-args = ["--host=localhost"]
60+
extra-dependencies = [
61+
"packaging>=25.0",
62+
]
6063

6164
[[tool.hatch.envs.hatch-test.matrix]]
6265
python = ["3.11", "3.12", "3.13"]
@@ -119,7 +122,7 @@ ban-relative-imports = "all"
119122

120123
[tool.ruff.lint.per-file-ignores]
121124
# Tests can use magic values, assertions, and relative imports
122-
"tests/**/*" = ["PLR2004", "S101", "TID252"]
125+
"test_*" = ["PLR2004", "S101", "TID252"]
123126
"fbapi.py" = ["N801", "E501"]
124127
"interfaces.py" = ["ARG001", "ARG002", "N801", "N803", "E501", "FBT001"]
125128
"hooks.py" = ["F401"]

src/firebird/driver/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -133,4 +133,4 @@
133133
)
134134

135135
#: Current driver version, SEMVER string.
136-
__VERSION__ = '2.0.1'
136+
__VERSION__ = '2.0.2'

tests/test_insert_data.py

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ def utf8_connection(dsn):
4949

5050
def test_insert_integers(db_connection):
5151
with db_connection.cursor() as cur:
52-
cur.execute('insert into T2 (C1,C2,C3) values (?,?,?)', [1, 1, 1])
52+
cur.execute('insert into T2 (C1,C2,C3) values (?,?,?)', ['1', '1', '1'])
5353
db_connection.commit()
5454
cur.execute('select C1,C2,C3 from T2 where C1 = 1')
5555
rows = cur.fetchall()
@@ -97,12 +97,12 @@ def test_insert_datetime(db_connection):
9797

9898
# Insert from string (driver handles conversion if possible, though explicit types are better)
9999
# Note: Microsecond separator might vary based on driver/server locale. Use types.
100-
# cur.execute('insert into T2 (C1,C6,C7,C8) values (?,?,?,?)', [4, '2011-11-13', '15:0:1.200', '2011-11-13 15:0:1.2000'])
101-
# db_connection.commit()
102-
# cur.execute('select C1,C6,C7,C8 from T2 where C1 = 4')
103-
# rows = cur.fetchall()
104-
# assert rows == [(4, datetime.date(2011, 11, 13), datetime.time(15, 0, 1, 200000),
105-
# datetime.datetime(2011, 11, 13, 15, 0, 1, 200000))]
100+
cur.execute('insert into T2 (C1,C6,C7,C8) values (?,?,?,?)', [4, '2011-11-13', '15:0:1.200', '2011-11-13 15:0:1.2000'])
101+
db_connection.commit()
102+
cur.execute('select C1,C6,C7,C8 from T2 where C1 = 4')
103+
rows = cur.fetchall()
104+
assert rows == [(4, datetime.date(2011, 11, 13), datetime.time(15, 0, 1, 200000),
105+
datetime.datetime(2011, 11, 13, 15, 0, 1, 200000))]
106106

107107

108108
# encode date before 1859-11-17 produce a negative number

0 commit comments

Comments
 (0)