Skip to content

Commit dfec3d3

Browse files
committed
clean up, move env var
1 parent 10d0168 commit dfec3d3

File tree

3 files changed

+3
-6
lines changed

3 files changed

+3
-6
lines changed

CHANGELOG.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
99

1010
### Added
1111
- Environment variable `ENABLE_COLLECTIONS_SEARCH_ROUTE` to turn on/off the `/collections-search` endpoint. [#478](https://github.com/stac-utils/stac-fastapi-elasticsearch-opensearch/pull/478)
12-
- POST and GET `/collections-search` endpoint for collections search queries, needed because POST /collections will not work when the Transactions Extension is enabled. [#478](https://github.com/stac-utils/stac-fastapi-elasticsearch-opensearch/pull/478)
12+
- POST and GET `/collections-search` endpoint for collections search queries, needed because POST /collections search will not work when the Transactions Extension is enabled. Defaults to `False` [#478](https://github.com/stac-utils/stac-fastapi-elasticsearch-opensearch/pull/478)
1313
- GET `/collections` collection search structured filter extension with support for both cql2-json and cql2-text formats. [#475](https://github.com/stac-utils/stac-fastapi-elasticsearch-opensearch/pull/475)
1414
- GET `/collections` collection search query extension. [#477](https://github.com/stac-utils/stac-fastapi-elasticsearch-opensearch/pull/477)
1515
- GET `/collections` collections search datetime filtering support. [#476](https://github.com/stac-utils/stac-fastapi-elasticsearch-opensearch/pull/476)

stac_fastapi/opensearch/stac_fastapi/opensearch/app.py

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -130,9 +130,6 @@
130130
# Collection search related variables
131131
collections_get_request_model = None
132132

133-
# Collection search related variables
134-
collections_get_request_model = None
135-
136133
if ENABLE_COLLECTIONS_SEARCH or ENABLE_COLLECTIONS_SEARCH_ROUTE:
137134
# Create collection search extensions
138135
collection_search_extensions = [

stac_fastapi/tests/conftest.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -316,11 +316,11 @@ def must_be_bob(
316316
async def route_dependencies_app():
317317
"""Fixture to get the FastAPI app with custom route dependencies."""
318318

319+
os.environ["ENABLE_COLLECTIONS_SEARCH_ROUTE"] = "true"
320+
319321
# Create a copy of the app config
320322
test_config = app_config.copy()
321323

322-
os.environ["ENABLE_COLLECTIONS_SEARCH_ROUTE"] = "true"
323-
324324
# Define route dependencies
325325
test_config["route_dependencies"] = [
326326
([{"method": "GET", "path": "/collections"}], [Depends(must_be_bob)])

0 commit comments

Comments
 (0)