sqlalchemy-searchable 2.0.0__tar.gz
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.
- sqlalchemy_searchable-2.0.0/.gitignore +36 -0
- sqlalchemy_searchable-2.0.0/CHANGES.rst +345 -0
- sqlalchemy_searchable-2.0.0/LICENSE +27 -0
- sqlalchemy_searchable-2.0.0/PKG-INFO +47 -0
- sqlalchemy_searchable-2.0.0/README.rst +20 -0
- sqlalchemy_searchable-2.0.0/docs/Makefile +153 -0
- sqlalchemy_searchable-2.0.0/docs/alembic_migrations.rst +12 -0
- sqlalchemy_searchable-2.0.0/docs/conf.py +272 -0
- sqlalchemy_searchable-2.0.0/docs/configuration.rst +140 -0
- sqlalchemy_searchable-2.0.0/docs/index.rst +23 -0
- sqlalchemy_searchable-2.0.0/docs/integrations.rst +46 -0
- sqlalchemy_searchable-2.0.0/docs/make.bat +190 -0
- sqlalchemy_searchable-2.0.0/docs/quickstart.rst +99 -0
- sqlalchemy_searchable-2.0.0/docs/requirements.in +2 -0
- sqlalchemy_searchable-2.0.0/docs/requirements.txt +70 -0
- sqlalchemy_searchable-2.0.0/docs/search_query_parser.rst +49 -0
- sqlalchemy_searchable-2.0.0/docs/vectorizers.rst +103 -0
- sqlalchemy_searchable-2.0.0/pyproject.toml +58 -0
- sqlalchemy_searchable-2.0.0/sqlalchemy_searchable/__init__.py +468 -0
- sqlalchemy_searchable-2.0.0/sqlalchemy_searchable/expressions.sql +27 -0
- sqlalchemy_searchable-2.0.0/sqlalchemy_searchable/vectorizers.py +80 -0
- sqlalchemy_searchable-2.0.0/tests/__init__.py +0 -0
- sqlalchemy_searchable-2.0.0/tests/conftest.py +196 -0
- sqlalchemy_searchable-2.0.0/tests/schema_test_case.py +42 -0
- sqlalchemy_searchable-2.0.0/tests/test_class_configuration.py +19 -0
- sqlalchemy_searchable-2.0.0/tests/test_drop_trigger.py +97 -0
- sqlalchemy_searchable-2.0.0/tests/test_multiple_vectors_per_class.py +69 -0
- sqlalchemy_searchable-2.0.0/tests/test_schema_creation.py +44 -0
- sqlalchemy_searchable-2.0.0/tests/test_searchable.py +115 -0
- sqlalchemy_searchable-2.0.0/tests/test_single_table_inheritance.py +31 -0
- sqlalchemy_searchable-2.0.0/tests/test_sql_functions.py +134 -0
- sqlalchemy_searchable-2.0.0/tests/test_sync_trigger.py +138 -0
- sqlalchemy_searchable-2.0.0/tests/test_vectorizers.py +95 -0
- sqlalchemy_searchable-2.0.0/tests/test_weighted_search_vector.py +68 -0
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
*.py[cod]
|
|
2
|
+
|
|
3
|
+
# C extensions
|
|
4
|
+
*.so
|
|
5
|
+
|
|
6
|
+
# Packages
|
|
7
|
+
*.egg
|
|
8
|
+
*.egg-info
|
|
9
|
+
dist
|
|
10
|
+
build
|
|
11
|
+
eggs
|
|
12
|
+
parts
|
|
13
|
+
bin
|
|
14
|
+
var
|
|
15
|
+
sdist
|
|
16
|
+
develop-eggs
|
|
17
|
+
.installed.cfg
|
|
18
|
+
lib
|
|
19
|
+
lib64
|
|
20
|
+
docs/_build
|
|
21
|
+
|
|
22
|
+
# Installer logs
|
|
23
|
+
pip-log.txt
|
|
24
|
+
|
|
25
|
+
# Unit test / coverage reports
|
|
26
|
+
.coverage
|
|
27
|
+
.tox
|
|
28
|
+
nosetests.xml
|
|
29
|
+
|
|
30
|
+
# Translations
|
|
31
|
+
*.mo
|
|
32
|
+
|
|
33
|
+
# Mr Developer
|
|
34
|
+
.mr.developer.cfg
|
|
35
|
+
.project
|
|
36
|
+
.pydevproject
|
|
@@ -0,0 +1,345 @@
|
|
|
1
|
+
Changelog
|
|
2
|
+
---------
|
|
3
|
+
|
|
4
|
+
Here you can see the full list of changes between each SQLAlchemy-Searchable release.
|
|
5
|
+
|
|
6
|
+
2.0.0 (2023-08-28)
|
|
7
|
+
^^^^^^^^^^^^^^^^^^
|
|
8
|
+
|
|
9
|
+
- **BREAKING CHANGE**: Drop support for Python 3.6 and 3.7.
|
|
10
|
+
- **BREAKING CHANGE**: Drop support for SQLAlchemy 1.3.
|
|
11
|
+
- **BREAKING CHANGE**: Remove ``quote_identifier`` function.
|
|
12
|
+
- **BREAKING CHANGE**: Remove ``SearchManager.search_function_ddl`` method. Use
|
|
13
|
+
``CreateSearchFunctionSQL(column)`` instead.
|
|
14
|
+
- **BREAKING CHANGE**: Remove ``SearchManager.search_trigger_ddl`` method. Use
|
|
15
|
+
``CreateSearchTriggerSQL(column)`` instead.
|
|
16
|
+
- Migrate from Travis CI to Github workflows in order to have a working CI
|
|
17
|
+
again.
|
|
18
|
+
- Remove ``validators`` dependency
|
|
19
|
+
- Add support for Python 3.10 and 3.11.
|
|
20
|
+
- Use the ``pyproject.toml`` standard to specify project metadata, dependencies
|
|
21
|
+
and tool configuration. Use Hatch to build the project.
|
|
22
|
+
- Use Ruff for linting the project, replacing both isort and flake8.
|
|
23
|
+
- Upgrade Python syntax with pyupgrade to the minimum Python version supported.
|
|
24
|
+
- Use Black to format Python code.
|
|
25
|
+
- Add support for SQLAlchemy 2.0.
|
|
26
|
+
- Use SQLAlchemy's compilation extension to build the SQL for creating and
|
|
27
|
+
dropping the search functions and triggers.
|
|
28
|
+
- Update SQLAlchemy-Utils dependency to >=0.40.0.
|
|
29
|
+
- Fix the deprecation warning for ``sqlalchemy.orm.mapper()`` in
|
|
30
|
+
``make_searchable()`` and ``remove_listeners()``.
|
|
31
|
+
- Migrate the Read the Docs configuration to use `.readthedocs.yaml`
|
|
32
|
+
configuration file.
|
|
33
|
+
- Rewrite the test suite to use pytest fixtures ove classic xunit-style set-up.
|
|
34
|
+
- Fix ``parse_websearch`` tests on PostgreSQL 14 and later.
|
|
35
|
+
- Add PostgreSQL versions 11, 13, 14 and 15 to the CI build matrix. Previously,
|
|
36
|
+
the tests were only run on PostgreSQL 12.
|
|
37
|
+
- Rewrite the documentation to be up-to-date with the codebase, to fix the
|
|
38
|
+
grammar and formatting issues, and to ensure the code examples are correct.
|
|
39
|
+
- The query interface is considered legacy in SQLAlchemy 2.0. Migrate the tests
|
|
40
|
+
and documentation to use ``Session.execute()`` in conjunction with ``select()`` to
|
|
41
|
+
run ORM queries.
|
|
42
|
+
|
|
43
|
+
1.4.1 (2021-06-15)
|
|
44
|
+
^^^^^^^^^^^^^^^^^^
|
|
45
|
+
|
|
46
|
+
- Added auto_index option
|
|
47
|
+
|
|
48
|
+
|
|
49
|
+
1.4.0 (2021-06-13)
|
|
50
|
+
^^^^^^^^^^^^^^^^^^
|
|
51
|
+
|
|
52
|
+
- Simplify search parsing
|
|
53
|
+
- Fix parser errors with search keywords containing special characters such as underscores
|
|
54
|
+
|
|
55
|
+
|
|
56
|
+
1.3.0 (2021-06-02)
|
|
57
|
+
^^^^^^^^^^^^^^^^^^
|
|
58
|
+
|
|
59
|
+
- Raise PostgreSQL requirement to version 11
|
|
60
|
+
- Use websearch_to_tsquery internally rather than own parsing functions
|
|
61
|
+
- Drop py34, py35 support
|
|
62
|
+
|
|
63
|
+
|
|
64
|
+
1.2.0 (2020-07-10)
|
|
65
|
+
^^^^^^^^^^^^^^^^^^
|
|
66
|
+
|
|
67
|
+
- Fixed 'or' keyword parsing (#93)
|
|
68
|
+
- Dropped py27 support
|
|
69
|
+
|
|
70
|
+
|
|
71
|
+
1.1.0 (2019-07-05)
|
|
72
|
+
^^^^^^^^^^^^^^^^^^
|
|
73
|
+
|
|
74
|
+
- Fixed some issues with query parsing
|
|
75
|
+
- Fixed 'or' keyword parsing (#85)
|
|
76
|
+
- Dropped py33 support
|
|
77
|
+
- Fixed deprecation warnings (#81, pull request courtesy of Le-Stagiaire)
|
|
78
|
+
|
|
79
|
+
|
|
80
|
+
1.0.3 (2018-02-22)
|
|
81
|
+
^^^^^^^^^^^^^^^^^^
|
|
82
|
+
|
|
83
|
+
- Add missing expressions.sql
|
|
84
|
+
|
|
85
|
+
|
|
86
|
+
1.0.2 (2018-02-22)
|
|
87
|
+
^^^^^^^^^^^^^^^^^^
|
|
88
|
+
|
|
89
|
+
- Fixed import issue with expressions.sql
|
|
90
|
+
|
|
91
|
+
|
|
92
|
+
1.0.1 (2018-02-20)
|
|
93
|
+
^^^^^^^^^^^^^^^^^^
|
|
94
|
+
|
|
95
|
+
- Made all parser functions immutable
|
|
96
|
+
|
|
97
|
+
|
|
98
|
+
1.0 (2018-02-20)
|
|
99
|
+
^^^^^^^^^^^^^^^^
|
|
100
|
+
|
|
101
|
+
- Added pure PostgreSQL search query parsing (faster and can be used on SQL level)
|
|
102
|
+
- PostgreSQL >= 9.6 required
|
|
103
|
+
- Added support for phrase searching
|
|
104
|
+
- Removed python search query parsing
|
|
105
|
+
- Removed pyparsing from requirements
|
|
106
|
+
- Removed symbol removal (now handled implicitly on PostgreSQL side)
|
|
107
|
+
|
|
108
|
+
|
|
109
|
+
0.10.6 (2017-10-12)
|
|
110
|
+
^^^^^^^^^^^^^^^^^^^
|
|
111
|
+
|
|
112
|
+
- Fixed Flask-SQLAlchemy support (#63, pull request by quantus)
|
|
113
|
+
|
|
114
|
+
|
|
115
|
+
0.10.5 (2017-07-25)
|
|
116
|
+
^^^^^^^^^^^^^^^^^^^
|
|
117
|
+
|
|
118
|
+
- Added drop_trigger utility function (#58, pull request by ilya-chistyakov)
|
|
119
|
+
|
|
120
|
+
|
|
121
|
+
0.10.4 (2017-06-28)
|
|
122
|
+
^^^^^^^^^^^^^^^^^^^
|
|
123
|
+
|
|
124
|
+
- Index generation no longer manipulates table args (#55, pull request by jmuhlich)
|
|
125
|
+
|
|
126
|
+
|
|
127
|
+
0.10.3 (2017-01-26)
|
|
128
|
+
^^^^^^^^^^^^^^^^^^^
|
|
129
|
+
|
|
130
|
+
- Fixed 'Lo' unicode letter parsing (#50, pull request courtesy by StdCarrot)
|
|
131
|
+
|
|
132
|
+
|
|
133
|
+
0.10.2 (2016-09-02)
|
|
134
|
+
^^^^^^^^^^^^^^^^^^^
|
|
135
|
+
|
|
136
|
+
- Fixed vector matching to use global configuration regconfig as fallback
|
|
137
|
+
|
|
138
|
+
|
|
139
|
+
0.10.1 (2016-04-14)
|
|
140
|
+
^^^^^^^^^^^^^^^^^^^
|
|
141
|
+
|
|
142
|
+
- Use identifier quoting for reserved keywords (#45, pull request by cristen)
|
|
143
|
+
|
|
144
|
+
|
|
145
|
+
0.10.0 (2016-03-31)
|
|
146
|
+
^^^^^^^^^^^^^^^^^^
|
|
147
|
+
|
|
148
|
+
- Fixed unicode parsing in search query parser, #42
|
|
149
|
+
- Removed Python 2.6 support
|
|
150
|
+
|
|
151
|
+
|
|
152
|
+
0.9.3 (2015-05-31)
|
|
153
|
+
^^^^^^^^^^^^^^^^^^
|
|
154
|
+
|
|
155
|
+
- Added support for search term weights
|
|
156
|
+
|
|
157
|
+
|
|
158
|
+
0.9.2 (2015-04-01)
|
|
159
|
+
^^^^^^^^^^^^^^^^^^
|
|
160
|
+
|
|
161
|
+
- Fixed listener configuration (#31)
|
|
162
|
+
|
|
163
|
+
|
|
164
|
+
0.9.1 (2015-03-25)
|
|
165
|
+
^^^^^^^^^^^^^^^^^^
|
|
166
|
+
|
|
167
|
+
- Added sort param to search function for ordering search results by relevance
|
|
168
|
+
|
|
169
|
+
|
|
170
|
+
0.9.0 (2015-03-19)
|
|
171
|
+
^^^^^^^^^^^^^^^^^^
|
|
172
|
+
|
|
173
|
+
- Added PyPy support
|
|
174
|
+
- Added isort and flake8 checks
|
|
175
|
+
- Added support for custom vectorizers in sync_trigger, #25
|
|
176
|
+
- Fixed and / or parsing where search word started with keyword, #22
|
|
177
|
+
- Removed 'and' as keyword from search query parser (spaces are always considered as 'and' keywords)
|
|
178
|
+
|
|
179
|
+
|
|
180
|
+
0.8.0 (2015-01-03)
|
|
181
|
+
^^^^^^^^^^^^^^^^^^
|
|
182
|
+
|
|
183
|
+
- Made search function support for queries without entity_zero
|
|
184
|
+
- Changed catalog configuration option name to regconfig to be compatible with the PostgreSQL and SQLAlchemy naming
|
|
185
|
+
- Added custom type and column vectorizers
|
|
186
|
+
- SQLAlchemy requirement updated to 0.9.0
|
|
187
|
+
- SQLAlchemy-Utils requirement updated to 0.29.0
|
|
188
|
+
|
|
189
|
+
|
|
190
|
+
0.7.1 (2014-12-16)
|
|
191
|
+
^^^^^^^^^^^^^^^^^^
|
|
192
|
+
|
|
193
|
+
- Changed GIN indexes to table args Index constructs. This means current version of alembic should be able to create these indexes automatically.
|
|
194
|
+
- Changed GIN index naming to adhere to SQLAlchemy index naming conventions
|
|
195
|
+
|
|
196
|
+
|
|
197
|
+
0.7.0 (2014-11-17)
|
|
198
|
+
^^^^^^^^^^^^^^^^^^
|
|
199
|
+
|
|
200
|
+
- Replaced remove_hyphens configuration option by more generic remove_symbols configuration option
|
|
201
|
+
- Emails are no longer considered as special tokens by default.
|
|
202
|
+
|
|
203
|
+
|
|
204
|
+
0.6.0 (2014-09-21)
|
|
205
|
+
^^^^^^^^^^^^^^^^^^
|
|
206
|
+
|
|
207
|
+
- Added sync_trigger alembic helper function
|
|
208
|
+
|
|
209
|
+
|
|
210
|
+
0.5.0 (2014-03-19)
|
|
211
|
+
^^^^^^^^^^^^^^^^^^
|
|
212
|
+
|
|
213
|
+
- Python 3 support
|
|
214
|
+
- Enhanced email token handling
|
|
215
|
+
- New configuration option: remove_hyphens
|
|
216
|
+
|
|
217
|
+
|
|
218
|
+
0.4.5 (2013-10-22)
|
|
219
|
+
^^^^^^^^^^^^^^^^^^
|
|
220
|
+
|
|
221
|
+
- Updated validators dependency to 0.2.0
|
|
222
|
+
|
|
223
|
+
|
|
224
|
+
0.4.4 (2013-10-17)
|
|
225
|
+
^^^^^^^^^^^^^^^^^^
|
|
226
|
+
|
|
227
|
+
- Search query string parser now notices emails and leaves them as they are (same behavious as in PostgreSQL tsvector parser)
|
|
228
|
+
|
|
229
|
+
|
|
230
|
+
0.4.3 (2013-10-07)
|
|
231
|
+
^^^^^^^^^^^^^^^^^^
|
|
232
|
+
|
|
233
|
+
- Fixed index/trigger creation when multiple vectors attached to single class
|
|
234
|
+
- Search vector without columns do not generate triggers anymore
|
|
235
|
+
|
|
236
|
+
|
|
237
|
+
0.4.2 (2013-10-07)
|
|
238
|
+
^^^^^^^^^^^^^^^^^^
|
|
239
|
+
|
|
240
|
+
- Fixed single table inheritance handling in define_triggers_and_indexes manager method.
|
|
241
|
+
|
|
242
|
+
|
|
243
|
+
0.4.1 (2013-10-04)
|
|
244
|
+
^^^^^^^^^^^^^^^^^^
|
|
245
|
+
|
|
246
|
+
- Fixed negation operator parsing
|
|
247
|
+
|
|
248
|
+
|
|
249
|
+
0.4.0 (2013-10-04)
|
|
250
|
+
^^^^^^^^^^^^^^^^^^
|
|
251
|
+
|
|
252
|
+
- Completely rewritten search API
|
|
253
|
+
- Renamed SearchQueryMixin.search and main module search function's 'language' parameter to 'catalog'
|
|
254
|
+
- Support for multiple search vectors per class
|
|
255
|
+
|
|
256
|
+
|
|
257
|
+
0.3.3 (2013-10-03)
|
|
258
|
+
^^^^^^^^^^^^^^^^^^
|
|
259
|
+
|
|
260
|
+
- Fixed support for numbers in parse_search_query
|
|
261
|
+
|
|
262
|
+
|
|
263
|
+
0.3.2 (2013-10-03)
|
|
264
|
+
^^^^^^^^^^^^^^^^^^
|
|
265
|
+
|
|
266
|
+
- Added support for hyphens between words
|
|
267
|
+
|
|
268
|
+
|
|
269
|
+
0.3.1 (2013-10-02)
|
|
270
|
+
^^^^^^^^^^^^^^^^^^
|
|
271
|
+
|
|
272
|
+
- Fixed parse_search_query to support nested parenthesis and negation operator
|
|
273
|
+
|
|
274
|
+
|
|
275
|
+
0.3.0 (2013-10-01)
|
|
276
|
+
^^^^^^^^^^^^^^^^^^
|
|
277
|
+
|
|
278
|
+
- Added better search query parsing capabilities (support for nested parenthesis, or operator and negation operator)
|
|
279
|
+
|
|
280
|
+
|
|
281
|
+
0.2.1 (2013-08-01)
|
|
282
|
+
^^^^^^^^^^^^^^^^^^
|
|
283
|
+
|
|
284
|
+
- Made psycopg dependency more permissive
|
|
285
|
+
|
|
286
|
+
|
|
287
|
+
0.2.0 (2013-08-01)
|
|
288
|
+
^^^^^^^^^^^^^^^^^^
|
|
289
|
+
|
|
290
|
+
- Added dependency to SQLAlchemy-Utils
|
|
291
|
+
- Search vectors must be added manually to each class
|
|
292
|
+
|
|
293
|
+
|
|
294
|
+
0.1.8 (2013-07-30)
|
|
295
|
+
^^^^^^^^^^^^^^^^^^
|
|
296
|
+
|
|
297
|
+
- Fixed safe_search_terms single quote handling
|
|
298
|
+
|
|
299
|
+
|
|
300
|
+
0.1.7 (2013-05-22)
|
|
301
|
+
^^^^^^^^^^^^^^^^^^
|
|
302
|
+
|
|
303
|
+
- Language set explicitly on each query condition
|
|
304
|
+
|
|
305
|
+
|
|
306
|
+
0.1.6 (2013-04-17)
|
|
307
|
+
^^^^^^^^^^^^^^^^^^
|
|
308
|
+
|
|
309
|
+
- Fixed search function when using session based queries
|
|
310
|
+
|
|
311
|
+
|
|
312
|
+
0.1.5 (2013-04-03)
|
|
313
|
+
^^^^^^^^^^^^^^^^^^
|
|
314
|
+
|
|
315
|
+
- Added table name identifier quoting
|
|
316
|
+
|
|
317
|
+
|
|
318
|
+
0.1.4 (2013-01-30)
|
|
319
|
+
^^^^^^^^^^^^^^^^^^
|
|
320
|
+
|
|
321
|
+
- Fixed search_filter func when using empty or undefined search options
|
|
322
|
+
|
|
323
|
+
|
|
324
|
+
0.1.3 (2013-01-30)
|
|
325
|
+
^^^^^^^^^^^^^^^^^^
|
|
326
|
+
|
|
327
|
+
- Added support for custom language parameter in query search functions
|
|
328
|
+
|
|
329
|
+
|
|
330
|
+
0.1.2 (2013-01-30)
|
|
331
|
+
^^^^^^^^^^^^^^^^^^
|
|
332
|
+
|
|
333
|
+
- Added psycopg2 to requirements, fixed travis.yml
|
|
334
|
+
|
|
335
|
+
|
|
336
|
+
0.1.1 (2013-01-12)
|
|
337
|
+
^^^^^^^^^^^^^^^^^^
|
|
338
|
+
|
|
339
|
+
- safe_search_terms support for other than english catalogs
|
|
340
|
+
|
|
341
|
+
|
|
342
|
+
0.1.0 (2013-01-12)
|
|
343
|
+
^^^^^^^^^^^^^^^^^^
|
|
344
|
+
|
|
345
|
+
- Initial public release
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
Copyright (c) 2012, Konsta Vesterinen
|
|
2
|
+
|
|
3
|
+
All rights reserved.
|
|
4
|
+
|
|
5
|
+
Redistribution and use in source and binary forms, with or without
|
|
6
|
+
modification, are permitted provided that the following conditions are met:
|
|
7
|
+
|
|
8
|
+
* Redistributions of source code must retain the above copyright notice, this
|
|
9
|
+
list of conditions and the following disclaimer.
|
|
10
|
+
|
|
11
|
+
* Redistributions in binary form must reproduce the above copyright notice,
|
|
12
|
+
this list of conditions and the following disclaimer in the documentation
|
|
13
|
+
and/or other materials provided with the distribution.
|
|
14
|
+
|
|
15
|
+
* The names of the contributors may not be used to endorse or promote products
|
|
16
|
+
derived from this software without specific prior written permission.
|
|
17
|
+
|
|
18
|
+
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
|
|
19
|
+
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
|
|
20
|
+
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
|
21
|
+
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER BE LIABLE FOR ANY DIRECT,
|
|
22
|
+
INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
|
|
23
|
+
BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
|
24
|
+
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
|
|
25
|
+
LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
|
|
26
|
+
OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
|
|
27
|
+
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
Metadata-Version: 2.1
|
|
2
|
+
Name: sqlalchemy-searchable
|
|
3
|
+
Version: 2.0.0
|
|
4
|
+
Summary: Provides fulltext search capabilities for declarative SQLAlchemy models.
|
|
5
|
+
Project-URL: Code, https://github.com/kvesteri/sqlalchemy-searchable
|
|
6
|
+
Project-URL: Documentation, https://sqlalchemy-searchable.readthedocs.io/
|
|
7
|
+
Project-URL: Issue Tracker, http://github.com/kvesteri/sqlalchemy-searchable/issues
|
|
8
|
+
Author-email: Konsta Vesterinen <konsta@fastmonkeys.com>
|
|
9
|
+
License-Expression: BSD-3-Clause
|
|
10
|
+
License-File: LICENSE
|
|
11
|
+
Classifier: Environment :: Web Environment
|
|
12
|
+
Classifier: Intended Audience :: Developers
|
|
13
|
+
Classifier: License :: OSI Approved :: BSD License
|
|
14
|
+
Classifier: Operating System :: OS Independent
|
|
15
|
+
Classifier: Programming Language :: Python
|
|
16
|
+
Classifier: Programming Language :: Python :: 3
|
|
17
|
+
Classifier: Programming Language :: Python :: 3.8
|
|
18
|
+
Classifier: Programming Language :: Python :: 3.9
|
|
19
|
+
Classifier: Programming Language :: Python :: 3.10
|
|
20
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
21
|
+
Classifier: Topic :: Internet :: WWW/HTTP :: Dynamic Content
|
|
22
|
+
Classifier: Topic :: Software Development :: Libraries :: Python Modules
|
|
23
|
+
Requires-Python: >=3.8
|
|
24
|
+
Requires-Dist: sqlalchemy-utils>=0.40.0
|
|
25
|
+
Requires-Dist: sqlalchemy>=1.4
|
|
26
|
+
Description-Content-Type: text/x-rst
|
|
27
|
+
|
|
28
|
+
SQLAlchemy-Searchable
|
|
29
|
+
=====================
|
|
30
|
+
|
|
31
|
+
|Version Status| |Downloads|
|
|
32
|
+
|
|
33
|
+
Fulltext searchable models for SQLAlchemy. Only supports PostgreSQL
|
|
34
|
+
|
|
35
|
+
|
|
36
|
+
Resources
|
|
37
|
+
---------
|
|
38
|
+
|
|
39
|
+
- `Documentation <https://sqlalchemy-searchable.readthedocs.io/>`_
|
|
40
|
+
- `Issue Tracker <http://github.com/kvesteri/sqlalchemy-searchable/issues>`_
|
|
41
|
+
- `Code <http://github.com/kvesteri/sqlalchemy-searchable/>`_
|
|
42
|
+
|
|
43
|
+
|
|
44
|
+
.. |Version Status| image:: https://img.shields.io/pypi/v/SQLAlchemy-Searchable.svg
|
|
45
|
+
:target: https://pypi.python.org/pypi/SQLAlchemy-Searchable/
|
|
46
|
+
.. |Downloads| image:: https://img.shields.io/pypi/dm/SQLAlchemy-Searchable.svg
|
|
47
|
+
:target: https://pypi.python.org/pypi/SQLAlchemy-Searchable/
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
SQLAlchemy-Searchable
|
|
2
|
+
=====================
|
|
3
|
+
|
|
4
|
+
|Version Status| |Downloads|
|
|
5
|
+
|
|
6
|
+
Fulltext searchable models for SQLAlchemy. Only supports PostgreSQL
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
Resources
|
|
10
|
+
---------
|
|
11
|
+
|
|
12
|
+
- `Documentation <https://sqlalchemy-searchable.readthedocs.io/>`_
|
|
13
|
+
- `Issue Tracker <http://github.com/kvesteri/sqlalchemy-searchable/issues>`_
|
|
14
|
+
- `Code <http://github.com/kvesteri/sqlalchemy-searchable/>`_
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
.. |Version Status| image:: https://img.shields.io/pypi/v/SQLAlchemy-Searchable.svg
|
|
18
|
+
:target: https://pypi.python.org/pypi/SQLAlchemy-Searchable/
|
|
19
|
+
.. |Downloads| image:: https://img.shields.io/pypi/dm/SQLAlchemy-Searchable.svg
|
|
20
|
+
:target: https://pypi.python.org/pypi/SQLAlchemy-Searchable/
|
|
@@ -0,0 +1,153 @@
|
|
|
1
|
+
# Makefile for Sphinx documentation
|
|
2
|
+
#
|
|
3
|
+
|
|
4
|
+
# You can set these variables from the command line.
|
|
5
|
+
SPHINXOPTS =
|
|
6
|
+
SPHINXBUILD = sphinx-build
|
|
7
|
+
PAPER =
|
|
8
|
+
BUILDDIR = _build
|
|
9
|
+
|
|
10
|
+
# Internal variables.
|
|
11
|
+
PAPEROPT_a4 = -D latex_paper_size=a4
|
|
12
|
+
PAPEROPT_letter = -D latex_paper_size=letter
|
|
13
|
+
ALLSPHINXOPTS = -d $(BUILDDIR)/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) .
|
|
14
|
+
# the i18n builder cannot share the environment and doctrees with the others
|
|
15
|
+
I18NSPHINXOPTS = $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) .
|
|
16
|
+
|
|
17
|
+
.PHONY: help clean html dirhtml singlehtml pickle json htmlhelp qthelp devhelp epub latex latexpdf text man changes linkcheck doctest gettext
|
|
18
|
+
|
|
19
|
+
help:
|
|
20
|
+
@echo "Please use \`make <target>' where <target> is one of"
|
|
21
|
+
@echo " html to make standalone HTML files"
|
|
22
|
+
@echo " dirhtml to make HTML files named index.html in directories"
|
|
23
|
+
@echo " singlehtml to make a single large HTML file"
|
|
24
|
+
@echo " pickle to make pickle files"
|
|
25
|
+
@echo " json to make JSON files"
|
|
26
|
+
@echo " htmlhelp to make HTML files and a HTML help project"
|
|
27
|
+
@echo " qthelp to make HTML files and a qthelp project"
|
|
28
|
+
@echo " devhelp to make HTML files and a Devhelp project"
|
|
29
|
+
@echo " epub to make an epub"
|
|
30
|
+
@echo " latex to make LaTeX files, you can set PAPER=a4 or PAPER=letter"
|
|
31
|
+
@echo " latexpdf to make LaTeX files and run them through pdflatex"
|
|
32
|
+
@echo " text to make text files"
|
|
33
|
+
@echo " man to make manual pages"
|
|
34
|
+
@echo " texinfo to make Texinfo files"
|
|
35
|
+
@echo " info to make Texinfo files and run them through makeinfo"
|
|
36
|
+
@echo " gettext to make PO message catalogs"
|
|
37
|
+
@echo " changes to make an overview of all changed/added/deprecated items"
|
|
38
|
+
@echo " linkcheck to check all external links for integrity"
|
|
39
|
+
@echo " doctest to run all doctests embedded in the documentation (if enabled)"
|
|
40
|
+
|
|
41
|
+
clean:
|
|
42
|
+
-rm -rf $(BUILDDIR)/*
|
|
43
|
+
|
|
44
|
+
html:
|
|
45
|
+
$(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html
|
|
46
|
+
@echo
|
|
47
|
+
@echo "Build finished. The HTML pages are in $(BUILDDIR)/html."
|
|
48
|
+
|
|
49
|
+
dirhtml:
|
|
50
|
+
$(SPHINXBUILD) -b dirhtml $(ALLSPHINXOPTS) $(BUILDDIR)/dirhtml
|
|
51
|
+
@echo
|
|
52
|
+
@echo "Build finished. The HTML pages are in $(BUILDDIR)/dirhtml."
|
|
53
|
+
|
|
54
|
+
singlehtml:
|
|
55
|
+
$(SPHINXBUILD) -b singlehtml $(ALLSPHINXOPTS) $(BUILDDIR)/singlehtml
|
|
56
|
+
@echo
|
|
57
|
+
@echo "Build finished. The HTML page is in $(BUILDDIR)/singlehtml."
|
|
58
|
+
|
|
59
|
+
pickle:
|
|
60
|
+
$(SPHINXBUILD) -b pickle $(ALLSPHINXOPTS) $(BUILDDIR)/pickle
|
|
61
|
+
@echo
|
|
62
|
+
@echo "Build finished; now you can process the pickle files."
|
|
63
|
+
|
|
64
|
+
json:
|
|
65
|
+
$(SPHINXBUILD) -b json $(ALLSPHINXOPTS) $(BUILDDIR)/json
|
|
66
|
+
@echo
|
|
67
|
+
@echo "Build finished; now you can process the JSON files."
|
|
68
|
+
|
|
69
|
+
htmlhelp:
|
|
70
|
+
$(SPHINXBUILD) -b htmlhelp $(ALLSPHINXOPTS) $(BUILDDIR)/htmlhelp
|
|
71
|
+
@echo
|
|
72
|
+
@echo "Build finished; now you can run HTML Help Workshop with the" \
|
|
73
|
+
".hhp project file in $(BUILDDIR)/htmlhelp."
|
|
74
|
+
|
|
75
|
+
qthelp:
|
|
76
|
+
$(SPHINXBUILD) -b qthelp $(ALLSPHINXOPTS) $(BUILDDIR)/qthelp
|
|
77
|
+
@echo
|
|
78
|
+
@echo "Build finished; now you can run "qcollectiongenerator" with the" \
|
|
79
|
+
".qhcp project file in $(BUILDDIR)/qthelp, like this:"
|
|
80
|
+
@echo "# qcollectiongenerator $(BUILDDIR)/qthelp/SQLAlchemy-Searchable.qhcp"
|
|
81
|
+
@echo "To view the help file:"
|
|
82
|
+
@echo "# assistant -collectionFile $(BUILDDIR)/qthelp/SQLAlchemy-Searchable.qhc"
|
|
83
|
+
|
|
84
|
+
devhelp:
|
|
85
|
+
$(SPHINXBUILD) -b devhelp $(ALLSPHINXOPTS) $(BUILDDIR)/devhelp
|
|
86
|
+
@echo
|
|
87
|
+
@echo "Build finished."
|
|
88
|
+
@echo "To view the help file:"
|
|
89
|
+
@echo "# mkdir -p $$HOME/.local/share/devhelp/SQLAlchemy-Searchable"
|
|
90
|
+
@echo "# ln -s $(BUILDDIR)/devhelp $$HOME/.local/share/devhelp/SQLAlchemy-Searchable"
|
|
91
|
+
@echo "# devhelp"
|
|
92
|
+
|
|
93
|
+
epub:
|
|
94
|
+
$(SPHINXBUILD) -b epub $(ALLSPHINXOPTS) $(BUILDDIR)/epub
|
|
95
|
+
@echo
|
|
96
|
+
@echo "Build finished. The epub file is in $(BUILDDIR)/epub."
|
|
97
|
+
|
|
98
|
+
latex:
|
|
99
|
+
$(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex
|
|
100
|
+
@echo
|
|
101
|
+
@echo "Build finished; the LaTeX files are in $(BUILDDIR)/latex."
|
|
102
|
+
@echo "Run \`make' in that directory to run these through (pdf)latex" \
|
|
103
|
+
"(use \`make latexpdf' here to do that automatically)."
|
|
104
|
+
|
|
105
|
+
latexpdf:
|
|
106
|
+
$(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex
|
|
107
|
+
@echo "Running LaTeX files through pdflatex..."
|
|
108
|
+
$(MAKE) -C $(BUILDDIR)/latex all-pdf
|
|
109
|
+
@echo "pdflatex finished; the PDF files are in $(BUILDDIR)/latex."
|
|
110
|
+
|
|
111
|
+
text:
|
|
112
|
+
$(SPHINXBUILD) -b text $(ALLSPHINXOPTS) $(BUILDDIR)/text
|
|
113
|
+
@echo
|
|
114
|
+
@echo "Build finished. The text files are in $(BUILDDIR)/text."
|
|
115
|
+
|
|
116
|
+
man:
|
|
117
|
+
$(SPHINXBUILD) -b man $(ALLSPHINXOPTS) $(BUILDDIR)/man
|
|
118
|
+
@echo
|
|
119
|
+
@echo "Build finished. The manual pages are in $(BUILDDIR)/man."
|
|
120
|
+
|
|
121
|
+
texinfo:
|
|
122
|
+
$(SPHINXBUILD) -b texinfo $(ALLSPHINXOPTS) $(BUILDDIR)/texinfo
|
|
123
|
+
@echo
|
|
124
|
+
@echo "Build finished. The Texinfo files are in $(BUILDDIR)/texinfo."
|
|
125
|
+
@echo "Run \`make' in that directory to run these through makeinfo" \
|
|
126
|
+
"(use \`make info' here to do that automatically)."
|
|
127
|
+
|
|
128
|
+
info:
|
|
129
|
+
$(SPHINXBUILD) -b texinfo $(ALLSPHINXOPTS) $(BUILDDIR)/texinfo
|
|
130
|
+
@echo "Running Texinfo files through makeinfo..."
|
|
131
|
+
make -C $(BUILDDIR)/texinfo info
|
|
132
|
+
@echo "makeinfo finished; the Info files are in $(BUILDDIR)/texinfo."
|
|
133
|
+
|
|
134
|
+
gettext:
|
|
135
|
+
$(SPHINXBUILD) -b gettext $(I18NSPHINXOPTS) $(BUILDDIR)/locale
|
|
136
|
+
@echo
|
|
137
|
+
@echo "Build finished. The message catalogs are in $(BUILDDIR)/locale."
|
|
138
|
+
|
|
139
|
+
changes:
|
|
140
|
+
$(SPHINXBUILD) -b changes $(ALLSPHINXOPTS) $(BUILDDIR)/changes
|
|
141
|
+
@echo
|
|
142
|
+
@echo "The overview file is in $(BUILDDIR)/changes."
|
|
143
|
+
|
|
144
|
+
linkcheck:
|
|
145
|
+
$(SPHINXBUILD) -b linkcheck $(ALLSPHINXOPTS) $(BUILDDIR)/linkcheck
|
|
146
|
+
@echo
|
|
147
|
+
@echo "Link check complete; look for any errors in the above output " \
|
|
148
|
+
"or in $(BUILDDIR)/linkcheck/output.txt."
|
|
149
|
+
|
|
150
|
+
doctest:
|
|
151
|
+
$(SPHINXBUILD) -b doctest $(ALLSPHINXOPTS) $(BUILDDIR)/doctest
|
|
152
|
+
@echo "Testing of doctests in the sources finished, look at the " \
|
|
153
|
+
"results in $(BUILDDIR)/doctest/output.txt."
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
Alembic migrations
|
|
2
|
+
------------------
|
|
3
|
+
|
|
4
|
+
.. currentmodule:: sqlalchemy_searchable
|
|
5
|
+
|
|
6
|
+
When making changes to your database schema, you have to ensure the associated
|
|
7
|
+
search triggers and trigger functions get updated also. SQLAlchemy-Searchable
|
|
8
|
+
offers two helper functions for this: :func:`sync_trigger` and
|
|
9
|
+
:func:`drop_trigger`.
|
|
10
|
+
|
|
11
|
+
.. autofunction:: sync_trigger
|
|
12
|
+
.. autofunction:: drop_trigger
|