sqliter-py 0.9.0__py3-none-any.whl → 0.16.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- sqliter/constants.py +4 -3
- sqliter/exceptions.py +43 -0
- sqliter/model/__init__.py +38 -3
- sqliter/model/foreign_key.py +153 -0
- sqliter/model/model.py +42 -3
- sqliter/model/unique.py +20 -11
- sqliter/orm/__init__.py +16 -0
- sqliter/orm/fields.py +412 -0
- sqliter/orm/foreign_key.py +8 -0
- sqliter/orm/model.py +243 -0
- sqliter/orm/query.py +221 -0
- sqliter/orm/registry.py +169 -0
- sqliter/query/query.py +720 -69
- sqliter/sqliter.py +533 -76
- sqliter/tui/__init__.py +62 -0
- sqliter/tui/__main__.py +6 -0
- sqliter/tui/app.py +179 -0
- sqliter/tui/demos/__init__.py +96 -0
- sqliter/tui/demos/base.py +114 -0
- sqliter/tui/demos/caching.py +283 -0
- sqliter/tui/demos/connection.py +150 -0
- sqliter/tui/demos/constraints.py +211 -0
- sqliter/tui/demos/crud.py +154 -0
- sqliter/tui/demos/errors.py +231 -0
- sqliter/tui/demos/field_selection.py +150 -0
- sqliter/tui/demos/filters.py +389 -0
- sqliter/tui/demos/models.py +248 -0
- sqliter/tui/demos/ordering.py +156 -0
- sqliter/tui/demos/orm.py +460 -0
- sqliter/tui/demos/results.py +241 -0
- sqliter/tui/demos/string_filters.py +210 -0
- sqliter/tui/demos/timestamps.py +126 -0
- sqliter/tui/demos/transactions.py +177 -0
- sqliter/tui/runner.py +116 -0
- sqliter/tui/styles/app.tcss +130 -0
- sqliter/tui/widgets/__init__.py +7 -0
- sqliter/tui/widgets/code_display.py +81 -0
- sqliter/tui/widgets/demo_list.py +65 -0
- sqliter/tui/widgets/output_display.py +92 -0
- {sqliter_py-0.9.0.dist-info → sqliter_py-0.16.0.dist-info}/METADATA +27 -11
- sqliter_py-0.16.0.dist-info/RECORD +47 -0
- {sqliter_py-0.9.0.dist-info → sqliter_py-0.16.0.dist-info}/WHEEL +2 -2
- sqliter_py-0.16.0.dist-info/entry_points.txt +3 -0
- sqliter_py-0.9.0.dist-info/RECORD +0 -14
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: sqliter-py
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.16.0
|
|
4
4
|
Summary: Interact with SQLite databases using Python and Pydantic
|
|
5
5
|
Author: Grant Ramsay
|
|
6
6
|
Author-email: Grant Ramsay <grant@gnramsay.com>
|
|
@@ -15,18 +15,24 @@ Classifier: Programming Language :: Python :: 3.10
|
|
|
15
15
|
Classifier: Programming Language :: Python :: 3.11
|
|
16
16
|
Classifier: Programming Language :: Python :: 3.12
|
|
17
17
|
Classifier: Programming Language :: Python :: 3.13
|
|
18
|
+
Classifier: Programming Language :: Python :: 3.14
|
|
18
19
|
Classifier: Topic :: Database :: Front-Ends
|
|
19
20
|
Classifier: Topic :: Software Development
|
|
20
21
|
Classifier: Topic :: Software Development :: Libraries :: Python Modules
|
|
21
|
-
Requires-Dist: pydantic
|
|
22
|
+
Requires-Dist: pydantic>=2.12.5
|
|
23
|
+
Requires-Dist: textual>=7.3.0 ; extra == 'demo'
|
|
22
24
|
Requires-Dist: inflect==7.0.0 ; extra == 'extras'
|
|
25
|
+
Requires-Dist: inflect>=7.0.0 ; extra == 'full'
|
|
26
|
+
Requires-Dist: textual>=7.3.0 ; extra == 'full'
|
|
23
27
|
Requires-Python: >=3.9
|
|
24
|
-
Project-URL: Bug Tracker, https://github.com/seapagan/sqliter-py/issues
|
|
25
|
-
Project-URL: Changelog, https://github.com/seapagan/sqliter-py/blob/main/CHANGELOG.md
|
|
26
28
|
Project-URL: Homepage, http://sqliter.grantramsay.dev
|
|
27
29
|
Project-URL: Pull Requests, https://github.com/seapagan/sqliter-py/pulls
|
|
30
|
+
Project-URL: Bug Tracker, https://github.com/seapagan/sqliter-py/issues
|
|
31
|
+
Project-URL: Changelog, https://github.com/seapagan/sqliter-py/blob/main/CHANGELOG.md
|
|
28
32
|
Project-URL: Repository, https://github.com/seapagan/sqliter-py
|
|
33
|
+
Provides-Extra: demo
|
|
29
34
|
Provides-Extra: extras
|
|
35
|
+
Provides-Extra: full
|
|
30
36
|
Description-Content-Type: text/markdown
|
|
31
37
|
|
|
32
38
|
# SQLiter <!-- omit in toc -->
|
|
@@ -54,9 +60,6 @@ Full documentation is available on the [Website](https://sqliter.grantramsay.dev
|
|
|
54
60
|
|
|
55
61
|
> [!CAUTION]
|
|
56
62
|
>
|
|
57
|
-
> Currently NOT compatible with Python 3.14 (I need to refactor some code d/t
|
|
58
|
-
> changes in the latest Pydantic versions, this is a priority.)
|
|
59
|
-
>
|
|
60
63
|
> This project is still in the early stages of development and is lacking some
|
|
61
64
|
> planned functionality. Please use with caution - Classes and methods may
|
|
62
65
|
> change until a stable release is made. I'll try to keep this to an absolute
|
|
@@ -78,15 +81,18 @@ Full documentation is available on the [Website](https://sqliter.grantramsay.dev
|
|
|
78
81
|
- Supports `date` and `datetime` fields
|
|
79
82
|
- Support for complex data types (`list`, `dict`, `set`, `tuple`) stored as
|
|
80
83
|
BLOBs
|
|
84
|
+
- Foreign key relationships with referential integrity and CASCADE actions
|
|
81
85
|
- Automatic primary key generation
|
|
82
86
|
- User defined indexes on any field
|
|
83
87
|
- Set any field as UNIQUE
|
|
84
88
|
- CRUD operations (Create, Read, Update, Delete)
|
|
85
89
|
- Chained Query building with filtering, ordering, and pagination
|
|
86
90
|
- Transaction support
|
|
91
|
+
- Optional query result caching with LRU eviction, TTL, and memory limits
|
|
87
92
|
- Custom exceptions for better error handling
|
|
88
93
|
- Full type hinting and type checking
|
|
89
94
|
- Detailed documentation and examples
|
|
95
|
+
- Interactive TUI demo for exploring features
|
|
90
96
|
- No external dependencies other than Pydantic
|
|
91
97
|
- Full test coverage
|
|
92
98
|
- Can optionally output the raw SQL queries being executed for debugging
|
|
@@ -122,9 +128,9 @@ Currently by default, the only external dependency is Pydantic. However, there
|
|
|
122
128
|
are some optional dependencies that can be installed to enable additional
|
|
123
129
|
features:
|
|
124
130
|
|
|
125
|
-
- `
|
|
126
|
-
|
|
127
|
-
|
|
131
|
+
- `demo`: Installs the Textual TUI framework for the interactive demo
|
|
132
|
+
- `extras`: Installs Inflect for better pluralization of table names
|
|
133
|
+
- `full`: Installs all optional dependencies (Textual and Inflect)
|
|
128
134
|
|
|
129
135
|
See [Installing Optional
|
|
130
136
|
Dependencies](https://sqliter.grantramsay.dev/installation#optional-dependencies)
|
|
@@ -173,6 +179,16 @@ See the [Guide](https://sqliter.grantramsay.dev/guide/guide/) section of the
|
|
|
173
179
|
documentation for more detailed information on how to use SQLiter, and advanced
|
|
174
180
|
features.
|
|
175
181
|
|
|
182
|
+
You can also run the interactive TUI demo to explore SQLiter features hands-on:
|
|
183
|
+
|
|
184
|
+
```bash
|
|
185
|
+
# Install the demo
|
|
186
|
+
uv add sqliter-py[demo]
|
|
187
|
+
|
|
188
|
+
# Run the demo
|
|
189
|
+
sqliter-demo
|
|
190
|
+
```
|
|
191
|
+
|
|
176
192
|
## Contributing
|
|
177
193
|
|
|
178
194
|
Contributions are welcome! Please feel free to submit a Pull Request.
|
|
@@ -187,7 +203,7 @@ which you can read in the [CODE_OF_CONDUCT](CODE_OF_CONDUCT.md) file.
|
|
|
187
203
|
This project is licensed under the MIT License.
|
|
188
204
|
|
|
189
205
|
```pre
|
|
190
|
-
Copyright (c) 2024-
|
|
206
|
+
Copyright (c) 2024-2026 Grant Ramsay
|
|
191
207
|
|
|
192
208
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
193
209
|
of this software and associated documentation files (the "Software"), to deal
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
sqliter/__init__.py,sha256=ECfn02OPmiMCQvRYbfizKFhVDk00xV-HV1s2cH9037I,244
|
|
2
|
+
sqliter/constants.py,sha256=lZ5PKJRofr9Hh8-R7QFt06DV0LiGb3MGY8D-rTklMCk,1279
|
|
3
|
+
sqliter/exceptions.py,sha256=FCVImm9zpMsAcqApAKPA8KLFLtX2ScGT3sMO1XScRhE,6970
|
|
4
|
+
sqliter/helpers.py,sha256=d6k4oWl43Se_c8rAmX8Zj0_sf2O-bpaaeu33VN2IcsI,3442
|
|
5
|
+
sqliter/model/__init__.py,sha256=IZC6you0Wt2o0OovmgBIszt7JzuIY7kMFBpcLwIhcCI,1304
|
|
6
|
+
sqliter/model/foreign_key.py,sha256=aaUJ-02o2_g9JOaxUoicaGTwNwjFS_Si4eYec0bMrqY,5381
|
|
7
|
+
sqliter/model/model.py,sha256=pFs8xEQANvipT5_vQPyiyxA_WZsiwT1PVdMR9xoT1aI,9643
|
|
8
|
+
sqliter/model/unique.py,sha256=-Jh56jBv5cjWmZpChwm5jDb_hZBvcqP0gy6MeCNyJvk,827
|
|
9
|
+
sqliter/orm/__init__.py,sha256=7cBEjOfPVkwWevAEaHmEwlZgGX4J_kMQukTFgRpSGGQ,565
|
|
10
|
+
sqliter/orm/fields.py,sha256=P5qxVNwNeFgTmO1ctzEUC7GKyCn-MoojYUjyzDU5tkA,14270
|
|
11
|
+
sqliter/orm/foreign_key.py,sha256=vMoI5deMsi34eocIyniAIXuWSf5jyOZ_nh2kCPhrbMc,154
|
|
12
|
+
sqliter/orm/model.py,sha256=FiR6vvFnTuCeUZ_G6t0vrwU23XOeQ6FvA-rRILs0qP4,10195
|
|
13
|
+
sqliter/orm/query.py,sha256=QvOU86c6l_wqKGlCBeGNjkcmTybK0a984eo7pauPngw,5970
|
|
14
|
+
sqliter/orm/registry.py,sha256=NZJZmgumJ4NF2akB1xdPWYNbxxv0s2KG6XU_ts0ezrw,5389
|
|
15
|
+
sqliter/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
16
|
+
sqliter/query/__init__.py,sha256=MRajhjTPJqjbmmrwndVKj8vqMbK5-XufpwoIswQf5z4,239
|
|
17
|
+
sqliter/query/query.py,sha256=8QsXjDsnto2d5O-GNCF1HehudTAPDYHqXKDTQZI3ULA,50759
|
|
18
|
+
sqliter/sqliter.py,sha256=KixFltlcT9fXLqahXnCgupmD-ipEsgF41ckDjoKMorA,41685
|
|
19
|
+
sqliter/tui/__init__.py,sha256=1-WNXJUzPp_y8FZh1XWzSGzCG1gd9-PP8QGZmDJAXl4,1325
|
|
20
|
+
sqliter/tui/__main__.py,sha256=AYPstbNjxExN1BoPOuOvhOzKKZ25uT6y27FMe8UrOYQ,142
|
|
21
|
+
sqliter/tui/app.py,sha256=D-hveUTrqFOjFTfO66SGmy1Xy_13Cbh03WUJVqHjNkw,5689
|
|
22
|
+
sqliter/tui/demos/__init__.py,sha256=sxrpJ0RQTddL-X-nB_TSjS8HNk5kNIgye1YiRdy8dAE,3014
|
|
23
|
+
sqliter/tui/demos/base.py,sha256=p-C2sV3waLKTVYgqSbO87s2mRUngwTvrPdTea1hXUqo,3343
|
|
24
|
+
sqliter/tui/demos/caching.py,sha256=G0-Yx336rVlY_Hwdn6s9eyIoAQ_iyJvkaMPTryTF30o,8602
|
|
25
|
+
sqliter/tui/demos/connection.py,sha256=xHi9nBFy3nCXDOUgAkF1PfdGTVufqMB3ctVvBYunv4E,4378
|
|
26
|
+
sqliter/tui/demos/constraints.py,sha256=E-RuXOTtD7DywsvBd7QSjTAGkTSm8ef15Y1rKHPLRLY,6468
|
|
27
|
+
sqliter/tui/demos/crud.py,sha256=ltuxUgyhWAxt94FpSs9he_P1YBhI6P1OZpI4g3ueHhg,4112
|
|
28
|
+
sqliter/tui/demos/errors.py,sha256=_WC9ngcfa335nBwCJc3q2WWLnEJqZy20yNYN78PG9rY,6990
|
|
29
|
+
sqliter/tui/demos/field_selection.py,sha256=5wzmIRSxE0CiZoRJN4l2SSyAmn8n7vyL26cDrW8SWVs,4211
|
|
30
|
+
sqliter/tui/demos/filters.py,sha256=4k-0NVUPP-12eHMSt1OKHj88eHbiK_95nX2KilObBOo,11193
|
|
31
|
+
sqliter/tui/demos/models.py,sha256=_jhXLvfWiUd3GuHheAMGmi7eK0prpK3hU2fanoAjBKQ,7129
|
|
32
|
+
sqliter/tui/demos/ordering.py,sha256=IU8rrBXja5rS6_tMHTvcLadc3TBXF2lISNFe5dtuS3Y,4200
|
|
33
|
+
sqliter/tui/demos/orm.py,sha256=AUsUschixnwbHRk717RI9N2c7DSFXZKWiDtaX-hMykY,14892
|
|
34
|
+
sqliter/tui/demos/results.py,sha256=lYVRinbMLSnsm-fDqcs-4vXLzS0j1VmwLWWCPUlUiIE,6830
|
|
35
|
+
sqliter/tui/demos/string_filters.py,sha256=ACq0qsXKwyzZDwkyl1l77-A-1f37T59FahooPDWrMmM,6385
|
|
36
|
+
sqliter/tui/demos/timestamps.py,sha256=6UXnzJsLR6nqMLSKNwjpHOeiHbVp7svgNDc8w9kL5gc,3941
|
|
37
|
+
sqliter/tui/demos/transactions.py,sha256=jYotIzwx2dZSb1aYWQMJeLG7WMlEoHJ3JtuWI49xdKQ,5508
|
|
38
|
+
sqliter/tui/runner.py,sha256=r39oyJzMk7TSmmYFNxeA-sZa-plKcmywPcQUNUNQgy0,3254
|
|
39
|
+
sqliter/tui/styles/app.tcss,sha256=mra0V9P9hPoamAWHQCnPFnWufHYXk58XZHfORz47kV0,1868
|
|
40
|
+
sqliter/tui/widgets/__init__.py,sha256=B9xwBki0O0WonVlh-HBNhHzi55rAx34hMv4-T6Ph4oM,296
|
|
41
|
+
sqliter/tui/widgets/code_display.py,sha256=Ctn7LbMEL0yYEbGtQqTv46XPmky_UA1lbBW4c31HI2k,2173
|
|
42
|
+
sqliter/tui/widgets/demo_list.py,sha256=d017WVyFoQ3tYbf_KW251dLRbPS-0lf-yhWzIVZ56mY,1841
|
|
43
|
+
sqliter/tui/widgets/output_display.py,sha256=VDIGMMijI_yDRm5WUCxMA9FoKlL0ezngqJn1SEih7PE,2641
|
|
44
|
+
sqliter_py-0.16.0.dist-info/WHEEL,sha256=XV0cjMrO7zXhVAIyyc8aFf1VjZ33Fen4IiJk5zFlC3g,80
|
|
45
|
+
sqliter_py-0.16.0.dist-info/entry_points.txt,sha256=s5eRk657kq0LNqMwAgNH_F93M8aqMeLt122OZ5CQb9s,50
|
|
46
|
+
sqliter_py-0.16.0.dist-info/METADATA,sha256=iCfpNVPJsVnBsIoBc3BV882QsR2Cv_tb4sR8g27hgiE,8011
|
|
47
|
+
sqliter_py-0.16.0.dist-info/RECORD,,
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
sqliter/__init__.py,sha256=ECfn02OPmiMCQvRYbfizKFhVDk00xV-HV1s2cH9037I,244
|
|
2
|
-
sqliter/constants.py,sha256=pNKalajchG6YvXw0-lTMKOJ_OL2xPSs_3YuOuVsqkVk,1257
|
|
3
|
-
sqliter/exceptions.py,sha256=g-YZaPazBxlYxQ0lVP_MCWC-mQlX_qgyWip5LJCVLV4,5654
|
|
4
|
-
sqliter/helpers.py,sha256=d6k4oWl43Se_c8rAmX8Zj0_sf2O-bpaaeu33VN2IcsI,3442
|
|
5
|
-
sqliter/model/__init__.py,sha256=sBp6HcDZdespSYmA4sCXq9OikCFTNdFFkT-wM3JJ2Mw,396
|
|
6
|
-
sqliter/model/model.py,sha256=UOD5yO5CizHFWye_BlG28keSK6qWRdHQVI79Y7ovQ9o,8058
|
|
7
|
-
sqliter/model/unique.py,sha256=r4CXrW1GXB6OgNoOVDTpTEVZl8_zta3mYbbT5quMc-c,578
|
|
8
|
-
sqliter/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
9
|
-
sqliter/query/__init__.py,sha256=MRajhjTPJqjbmmrwndVKj8vqMbK5-XufpwoIswQf5z4,239
|
|
10
|
-
sqliter/query/query.py,sha256=yQjYtfSWxgEvbxQgQgwpjS6Z9tSFTQ2aISSKoQ9kaGM,25743
|
|
11
|
-
sqliter/sqliter.py,sha256=lPSvBrFrszCGT47CNPssmp4G7NiFccpdas4kpKZQmO0,25173
|
|
12
|
-
sqliter_py-0.9.0.dist-info/WHEEL,sha256=93kfTGt3a0Dykt_T-gsjtyS5_p8F_d6CE1NwmBOirzo,79
|
|
13
|
-
sqliter_py-0.9.0.dist-info/METADATA,sha256=2Rd3ABHO8IG82IZQOlryAOMoSzxYB-D_pPFmrR3SiwA,7566
|
|
14
|
-
sqliter_py-0.9.0.dist-info/RECORD,,
|