File tree Expand file tree Collapse file tree 5 files changed +22
-2
lines changed Expand file tree Collapse file tree 5 files changed +22
-2
lines changed Original file line number Diff line number Diff line change @@ -4,10 +4,11 @@ All notable changes to this project will be documented in this file.
4
4
The format is based on [ Keep a Changelog] ( http://keepachangelog.com/ )
5
5
and this project adheres to [ Semantic Versioning] ( http://semver.org/ ) .
6
6
7
- ## [ 1.10.1] - Unreleased
7
+ ## [ 1.10.1] - 2023-12-21
8
8
9
9
### Fixed
10
10
11
+ - Call iProvider.shutdown() on program exit.
11
12
- #33 - SIGABRT on interface detach.
12
13
13
14
## [ 1.10.0] - 2023-10-03
Original file line number Diff line number Diff line change 2
2
Changelog
3
3
#########
4
4
5
+ Version 1.10.1
6
+ ==============
7
+
8
+ * Call iProvider.shutdown() on program exit.
9
+ * Fix: #33 - SIGABRT on interface detach.
10
+
5
11
Version 1.10.0
6
12
==============
7
13
Original file line number Diff line number Diff line change @@ -65,6 +65,10 @@ cov-report = [
65
65
" - coverage combine" ,
66
66
" coverage report" ,
67
67
]
68
+ cov-html = [
69
+ " - coverage combine" ,
70
+ " coverage html" ,
71
+ ]
68
72
cov = [
69
73
" test-cov" ,
70
74
" cov-report" ,
Original file line number Diff line number Diff line change 61
61
Server , Statement )
62
62
63
63
#: Current driver version, SEMVER string.
64
- __VERSION__ = '1.10.0 '
64
+ __VERSION__ = '1.10.1 '
Original file line number Diff line number Diff line change 50
50
import struct
51
51
import datetime
52
52
import decimal
53
+ import atexit
53
54
from abc import ABC , abstractmethod
54
55
from warnings import warn
55
56
from pathlib import Path
@@ -150,6 +151,14 @@ def __api_loaded(api: a.FirebirdAPI) -> None:
150
151
151
152
add_hook (APIHook .LOADED , a .FirebirdAPI , __api_loaded )
152
153
154
+ @atexit .register
155
+ def _api_shutdown ():
156
+ """Calls a smart shutdown of various Firebird subsystems (yValve, engine, redirector).
157
+ """
158
+ if _master is not None :
159
+ with _master .get_dispatcher () as provider :
160
+ provider .shutdown (0 , - 3 ) # fb_shutrsn_app_stopped
161
+
153
162
def _create_blob_buffer (size : int = MAX_BLOB_SEGMENT_SIZE ) -> Any :
154
163
if size < MAX_BLOB_SEGMENT_SIZE :
155
164
result = getattr (_thns , 'blob_buf' , None )
You can’t perform that action at this time.
0 commit comments