Skip to content

Commit

Permalink
Update to 2.1.0 (#243)
Browse files Browse the repository at this point in the history
* Add note in README about using Docker for Windows with --platform

* Add CI to test generating docs.

This will catch errors around doc build failures on PRs.

This generates docs through a containerized environment, as opposed to
the GitHub Action, which builds it's own environment. We may want to
consider utilizing the dockerized environment for the action as well
to reduce any sync issues

* Add brotli_asgi to stac_fastapi.api

* Add pull request template.

* Update pypi shield in README

* Fix alt text for license sheild

* Refactor changelog

This commit modifies the changelog to be more in line with changelogs
of other stac-utils projects, and fit more to the 'keep a changelog' pattern.

* Update CHANGELOG for 2.1.0

* Update versions to 2.1.0
  • Loading branch information
lossyrob authored Aug 27, 2021
1 parent 285e24f commit b29d171
Show file tree
Hide file tree
Showing 13 changed files with 142 additions and 21 deletions.
12 changes: 12 additions & 0 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
**Related Issue(s):** #


**Description:**


**PR Checklist:**

- [ ] Code is formatted and linted (run `pre-commit run --all-files`)
- [ ] Tests pass (run `make test`)
- [ ] Documentation has been updated to reflect changes, if applicable, and docs build successfully (run `make docs`)
- [ ] Changes are added to the [CHANGELOG](https://github.com/stac-utils/pystac/blob/master/CHANGES.md).
6 changes: 6 additions & 0 deletions .github/workflows/cicd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -100,3 +100,9 @@ jobs:
POSTGRES_HOST_READER: localhost
POSTGRES_HOST_WRITER: localhost
POSTGRES_PORT: 5432
test-docs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Test generating docs
run: make docs
75 changes: 61 additions & 14 deletions CHANGES.md
Original file line number Diff line number Diff line change
@@ -1,22 +1,69 @@
## UNRELEASED
# Changelog

* remove shapely from stac_fastapi.pgstac requirements (https://github.com/stac-utils/stac-fastapi/pull/225)
## [Unreleased]

## 2.0.0 (2021-07)
### Added

* Refactor stac-fastapi into submodules (https://github.com/stac-utils/stac-fastapi/pull/106)
* Add pgstac backend (https://github.com/stac-utils/stac-fastapi/pull/126)
* Upgrade to stac-pydantic 2.0.0 and stac-spec 1.0.0 (https://github.com/stac-utils/stac-fastapi/pull/181)
### Removed

## 1.1.0 (2021-01-28)
### Changed

* Improve how the library declares API extensions (https://github.com/stac-utils/arturo-stac-api/pull/54)
* Add postgres bulk transactions client (https://github.com/stac-utils/arturo-stac-api/pull/59)
* Update TiTiler version (https://github.com/stac-utils/arturo-stac-api/pull/61)
* Use attrs instead of dataclasses (https://github.com/stac-utils/arturo-stac-api/pull/73)
* Remove postgres database connection from API layer (https://github.com/stac-utils/arturo-stac-api/pull/74)
* Fix `pre-commit` config (https://github.com/stac-utils/arturo-stac-api/pull/75)
### Fixed

## 1.0.0 (2020-09-25)
## [2.1.0]

### Added

* Added filter extension. ([#165](https://github.com/stac-utils/stac-fastapi/pull/165))
* Add Support for CQL JSON to PGStac Backend ([#209](https://github.com/stac-utils/stac-fastapi/pull/209))
* Added item_serializer and item_table to BulkTransactionsClient in sqlalchemy backend ([#210](https://github.com/stac-utils/stac-fastapi/pull/210))
* Enable conformance class configuration ([#214](https://github.com/stac-utils/stac-fastapi/pull/214))
* Add/fix landing page links ([#229](https://github.com/stac-utils/stac-fastapi/pull/229))
* Correct response codes for bad/unusable bboxes ([#235](https://github.com/stac-utils/stac-fastapi/pull/235))
* Add a "method" field for search links ([#236](https://github.com/stac-utils/stac-fastapi/pull/236))
* Add extension schemas to landing ([#237](https://github.com/stac-utils/stac-fastapi/pull/237))

### Removed

* Remove shapely from stac_fastapi.pgstac requirements ([#225](https://github.com/stac-utils/stac-fastapi/pull/225))

### Changed

* Update to STAC API 1.0.0-beta.3 ([#239](https://github.com/stac-utils/stac-fastapi/pull/239))

### Fixed

* Make collection title is optional in landing page links ([#198](https://github.com/stac-utils/stac-fastapi/pull/198))
* Preserve relative paths on link generation ([#199](https://github.com/stac-utils/stac-fastapi/pull/199))
* Fix collection endpoint return value to match spec (fixes regression) ([#232](https://github.com/stac-utils/stac-fastapi/pull/232))
* Return empty item collection instead of error when searching ([#233](https://github.com/stac-utils/stac-fastapi/pull/233))
* Correct response codes for bad/unusable bboxes ([#235](https://github.com/stac-utils/stac-fastapi/pull/235))
* Update pgstac to return 400 on invalid date parameter ([#240](https://github.com/stac-utils/stac-fastapi/pull/240))

## [2.0.0]
_2021-07_

* Refactor stac-fastapi into submodules ([#106](https://github.com/)stac-utils/stac-fastapi/pull/106)
* Add pgstac backend ([#126](https://github.com/stac-utils/stac-fastapi/pull/126))
* Upgrade to stac-pydantic 2.0.0 and stac-spec 1.0.0 ([#181](https://github.com/stac-utils/stac-fastapi/pull/181))

## [1.1.0]
_2021-01-28_

* Improve how the library declares API extensions ([#54](https://github.com/stac-utils/arturo-stac-api/pull/54))
* Add postgres bulk transactions client ([#59](https://github.com/stac-utils/arturo-stac-api/pull/59))
* Update TiTiler version ([#61](https://github.com/stac-utils/arturo-stac-api/pull/61))
* Use attrs instead of dataclasses ([#73](https://github.com/stac-utils/arturo-stac-api/pull/73))
* Remove postgres database connection from API layer ([#74](https://github.com/stac-utils/arturo-stac-api/pull/74))
* Fix `pre-commit` config ([#75](https://github.com/stac-utils/arturo-stac-api/pull/75))

## [1.0.0]
_2020-09-25_

* First PyPi release!

[Unreleased]: <https://github.com/stac-utils/stac-fastapi/compare/2.1.0..main>
[2.1.0]: <https://github.com/stac-utils/stac-fastapi/compare/2.1.0..main>
[2.0.0]: <https://github.com/stac-utils/stac-fastapi/compare/1.1.0..2.0.0>
[1.1.0]: <https://github.com/stac-utils/stac-fastapi/compare/1.0.0..1.1.0>
[1.0.0]: <https://github.com/stac-utils/stac-fastapi/tree/1.0.0>
23 changes: 23 additions & 0 deletions Dockerfile.docs
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
FROM python:3.8-slim

RUN python -m pip install --upgrade pip
RUN python -m pip install mkdocs mkdocs-material pdocs

COPY . /opt/src

WORKDIR /opt/src

RUN python -m pip install -e \
stac_fastapi/api \
stac_fastapi/types \
stac_fastapi/extensions \
stac_fastapi/sqlalchemy


CMD ["pdocs", \
"as_markdown", \
"--output_dir", \
"docs/api/", \
"--exclude_source", \
"--overwrite", \
"stac_fastapi"]
10 changes: 10 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -67,3 +67,13 @@ pgstac-install: pybase-install
.PHONY: sqlalchemy-install
sqlalchemy-install: pybase-install
pip install -e ./stac_fastapi/sqlalchemy[dev,server]

.PHONY: docs-image
docs-image:
docker-compose -f docker-compose.docs.yml \
build

.PHONY: docs
docs: docs-image
docker-compose -f docker-compose.docs.yml \
run docs
8 changes: 6 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@
<img src="https://github.com/stac-utils/stac-fastapi/workflows/stac-fastapi/badge.svg" alt="Test">
</a>
<a href="https://pypi.org/project/stac-fastapi" target="_blank">
<img src="https://img.shields.io/pypi/v/stac-fastapi?color=%2334D058&label=pypi%20package" alt="Package version">
<img src="https://img.shields.io/pypi/v/stac-fastapi.api?color=%2334D058&label=pypi%20package" alt="Package version">
</a>
<a href="https://github.com/stac-utils/stac-fastapi/blob/master/LICENSE" target="_blank">
<img src="https://img.shields.io/github/license/stac-utils/stac-fastapi.svg" alt="Downloads">
<img src="https://img.shields.io/github/license/stac-utils/stac-fastapi.svg" alt="License">
</a>
</p>

Expand Down Expand Up @@ -78,6 +78,10 @@ For local development it is often more convenient to run the application outside
make docker-run
```

#### Note to Docker for Windows users

You'll need to enable experimental features on Docker for Windows in order to run the docker-compose, due to the "--platform" flag that is required to allow the project to run on some Apple architectures. To do this, open Docker Desktop, go to settings, select "Docker Engine", and modify the configuration JSON to have `"experimental": true`.

### Testing
The database container provided by the docker-compose stack must be running. Run all tests:
```bash
Expand Down
18 changes: 18 additions & 0 deletions docker-compose.docs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
version: '3'

services:
docs:
container_name: stac-fastapi-docs-dev
build:
context: .
dockerfile: Dockerfile.docs
platform: linux/amd64
environment:
- POSTGRES_USER=username
- POSTGRES_PASS=password
- POSTGRES_DBNAME=postgis
- POSTGRES_HOST_READER=database
- POSTGRES_HOST_WRITER=database
- POSTGRES_PORT=5432
volumes:
- .:/opt/src
1 change: 1 addition & 0 deletions stac_fastapi/api/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
"attrs",
"pydantic[dotenv]",
"stac_pydantic==2.0.*",
"brotli_asgi",
]

extra_reqs = {
Expand Down
2 changes: 1 addition & 1 deletion stac_fastapi/api/stac_fastapi/api/version.py
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
"""library version."""
__version__ = "2.0.0"
__version__ = "2.1.0"
2 changes: 1 addition & 1 deletion stac_fastapi/extensions/stac_fastapi/extensions/version.py
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
"""library version."""
__version__ = "2.0.0"
__version__ = "2.1.0"
2 changes: 1 addition & 1 deletion stac_fastapi/pgstac/stac_fastapi/pgstac/version.py
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
"""library version."""
__version__ = "2.0.0"
__version__ = "2.1.0"
2 changes: 1 addition & 1 deletion stac_fastapi/sqlalchemy/stac_fastapi/sqlalchemy/version.py
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
"""library version."""
__version__ = "2.0.0"
__version__ = "2.1.0"
2 changes: 1 addition & 1 deletion stac_fastapi/types/stac_fastapi/types/version.py
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
"""library version."""
__version__ = "2.0.0"
__version__ = "2.1.0"

0 comments on commit b29d171

Please sign in to comment.