Skip to content

Commit a76587d

Browse files
committed
Updated docs + new websockets guide
1 parent ffd0f6f commit a76587d

6 files changed

+318
-69
lines changed

Diff for: README.md

+14-44
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ This is a comprehensively updated fork of [Sebastián Ramírez's](https://github
1515
- [Development and installation](./docs/development-guide.md)
1616
- [Deployment for production](./docs/deployment-guide.md)
1717
- [Authentication and magic tokens](./docs/authentication-guide.md)
18+
- [Websockets for interactive communication](./docs/websocket-guide.md)
1819
- [More details](#more-details)
1920
- [Help needed](#help-needed)
2021
- [Release notes](#release-notes)
@@ -78,6 +79,7 @@ This FastAPI, PostgreSQL, Neo4j & Nuxt 3 repo will generate a complete web appli
7879
- [Development and installation](./docs/development-guide.md)
7980
- [Deployment for production](./docs/deployment-guide.md)
8081
- [Authentication and magic tokens](./docs/authentication-guide.md)
82+
- [Websockets for interactive communication](./docs/websocket-guide.md)
8183

8284
## More details
8385

@@ -99,6 +101,18 @@ The tests are broken and it would be great if someone could take that on. Other
99101

100102
## Release Notes
101103

104+
See notes and [releases](https://github.com/whythawk/full-stack-fastapi-postgresql/releases).
105+
106+
## 0.8.2
107+
108+
Fixing [#39](https://github.com/whythawk/full-stack-fastapi-postgresql/issues/39), thanks to @a-vorobyoff:
109+
110+
- Exposing port 24678 for Vite on frontend in development mode.
111+
- Ensuring Nuxt content on /api/_content doesn't interfere with backend /api/v routes.
112+
- Checking for password before hashing on user creation.
113+
- Updating generated README for Hatch (after Poetry deprecation).
114+
- Minor fixes.
115+
102116
### 0.8.1
103117

104118
- Minor updates to Docker scripts for `build`.
@@ -124,50 +138,6 @@ The tests are broken and it would be great if someone could take that on. Other
124138
- Fixed: Updated token url in deps.py [#29](https://github.com/whythawk/full-stack-fastapi-postgresql/pull/29) by @vusa
125139
- Docs: Reorganised documentation [#21](https://github.com/whythawk/full-stack-fastapi-postgresql/pull/21) by @turukawa
126140

127-
### 0.7.3
128-
- @nuxt/content 2.2.1 -> 2.4.3
129-
- Fixed: `@nuxt/content` default api, `/api/_content`, conflicts with the `backend` api url preventing content pages loading.
130-
- Documentation: Complete deployment guide in `DEPLOYMENT-README.md` (this has now been moved to `/docs`)
131-
132-
### 0.7.2
133-
- Fixed: URLs for recreating project in generated `README.md`. PR [#15](https://github.com/whythawk/full-stack-fastapi-postgresql/pull/15) by @FranzForstmayr
134-
- Fixed: Absolute path for mount point in `docker-compose.override.yml`. PR [#16](https://github.com/whythawk/full-stack-fastapi-postgresql/pull/16) by @FranzForstmayr
135-
- Fixed: Login artifacts left over from before switch to magic auth. PR [#18](https://github.com/whythawk/full-stack-fastapi-postgresql/pull/18) by @turukawa and @FranzForstmayr
136-
- New: New floating magic login card. PR [#19](https://github.com/whythawk/full-stack-fastapi-postgresql/pull/19) by @turukawa
137-
- New: New site contact page. PR [#20](https://github.com/whythawk/full-stack-fastapi-postgresql/pull/20) by @turukawa
138-
139-
### 0.7.1
140-
141-
- SQLAlchemy 1.4 -> 2.0
142-
- Nuxt.js 3.0 -> 3.2.2
143-
- Fixed: `tokenUrl` in `app/api/deps.py`. Thanks to @Choiuijin1125.
144-
- Fixed: SMTP options for TLS must be `ssl`. Thanks to @raouldo.
145-
- Fixed: `libgeos` is a dependency for `shapely` which is a dependency for `neomodel`, and which doesn't appear to be installed correctly on Macs. Thanks to @valsha and @Mocha-L.
146-
- Fixed: `frontend` fails to start in development. Thanks to @pabloapast and @dividor.
147-
148-
### 0.7.0
149-
150-
- New feature: magic (email-based) login, with password fallback
151-
- New feature: Time-based One-Time Password (TOTP) authentication
152-
- Security enhancements to improve consistency, safety and reliability of the authentication process (see full description in the frontend app)
153-
- Requires one new `frontend` dependency: [QRcode.vue](https://github.com/scopewu/qrcode.vue)
154-
155-
### 0.6.1
156-
157-
- Corrected error in variable name `ACCESS_TOKEN_EXPIRE_SECONDS`
158-
159-
### 0.6.0
160-
161-
- Inboard 0.10.4 -> 0.37.0, including FastAPI 0.88
162-
- SQLAlchemy 1.3 -> 1.4
163-
- Authentication refresh token tables and schemas for long-term issuing of a new access token.
164-
- Postgresql 12 -> 14
165-
- Neo4j pinned to 5.2.0
166-
- Nuxt.js 2.5 -> 3.0
167-
- Pinia for state management (replaces Vuex)
168-
- Vee-Validate 3 -> 4
169-
- Tailwind 2.2 -> 3.2
170-
171141
[Historic changes from original](https://github.com/tiangolo/full-stack-fastapi-postgresql#release-notes)
172142

173143
## License

Diff for: docs/authentication-guide.md

+1
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
2. [Development and installation](development-guide.md)
55
3. [Deployment for production](deployment-guide.md)
66
4. [Authentication and magic tokens](authentication-guide.md)
7+
5. [Websockets for interactive communication](websocket-guide.md)
78

89
---
910

Diff for: docs/deployment-guide.md

+1
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
2. [Development and installation](development-guide.md)
55
3. [Deployment for production](deployment-guide.md)
66
4. [Authentication and magic tokens](authentication-guide.md)
7+
5. [Websockets for interactive communication](websocket-guide.md)
78

89
---
910

Diff for: docs/development-guide.md

+20-2
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
2. [Development and installation](development-guide.md)
55
3. [Deployment for production](deployment-guide.md)
66
4. [Authentication and magic tokens](authentication-guide.md)
7+
5. [Websockets for interactive communication](websocket-guide.md)
78

89
---
910

@@ -90,6 +91,25 @@ And start them:
9091
docker-compose up -d
9192
```
9293

94+
By default, `backend` Python dependencies are managed with [Hatch](https://hatch.pypa.io/latest/). From `./backend/app/` you can install all the dependencies with:
95+
96+
```console
97+
$ hatch env prune
98+
$ hatch env create production
99+
```
100+
101+
Because Hatch doesn't have a version lock file (like Poetry), it is helpful to `prune` when you rebuild to avoid any sort of dependency hell. Then you can start a shell session with the new environment with:
102+
103+
```console
104+
$ hatch shell
105+
```
106+
107+
Make sure your editor uses the environment you just created with Hatch. For Visual Studio Code, from the shell, launch an appropriate development environment with:
108+
109+
```console
110+
$ code .
111+
```
112+
93113
**NOTE:** The Nuxt image does not automatically refresh while running in development mode. Any changes will need a rebuild. This gets tired fast, so it's easier to run Nuxt outside Docker and call through to the `backend` for API calls. You can then view the frontend at `http://localhost:3000` and the backend api endpoints at `http://localhost/redoc`. This problem won't be a concern in production.
94114

95115
Change into the `/frontend` folder, and:
@@ -99,8 +119,6 @@ yarn install
99119
yarn dev
100120
```
101121

102-
Be careful about the version of `Node.js` you're using. As of today (December 2022), the latest Node version supported by Nuxt is 16.18.1.
103-
104122
FastAPI `backend` updates will refresh automatically, but the `celeryworker` container must be restarted before changes take effect.
105123

106124
## Starting Jupyter Lab

Diff for: docs/getting-started.md

+30-23
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
2. [Development and installation](development-guide.md)
55
3. [Deployment for production](deployment-guide.md)
66
4. [Authentication and magic tokens](authentication-guide.md)
7+
5. [Websockets for interactive communication](websocket-guide.md)
78

89
---
910

@@ -104,35 +105,41 @@ After using this generator, your new project will contain an extensive `README.m
104105

105106
See notes and [releases](https://github.com/whythawk/full-stack-fastapi-postgresql/releases). The last four release notes are listed here:
106107

107-
### 0.7.3
108-
- @nuxt/content 2.2.1 -> 2.4.3
109-
- Fixed: `@nuxt/content` default api, `/api/_content`, conflicts with the `backend` api url preventing content pages loading.
110-
- Documentation: Complete deployment guide in `DEPLOYMENT-README.md` (this has now been moved to `/docs`)
108+
## 0.8.2
111109

112-
### 0.7.2
113-
- Fixed: URLs for recreating project in generated `README.md`. PR [#15](https://github.com/whythawk/full-stack-fastapi-postgresql/pull/15) by @FranzForstmayr
114-
- Fixed: Absolute path for mount point in `docker-compose.override.yml`. PR [#16](https://github.com/whythawk/full-stack-fastapi-postgresql/pull/16) by @FranzForstmayr
115-
- Fixed: Login artifacts left over from before switch to magic auth. PR [#18](https://github.com/whythawk/full-stack-fastapi-postgresql/pull/18) by @turukawa and @FranzForstmayr
116-
- New: New floating magic login card. PR [#19](https://github.com/whythawk/full-stack-fastapi-postgresql/pull/19) by @turukawa
117-
- New: New site contact page. PR [#20](https://github.com/whythawk/full-stack-fastapi-postgresql/pull/20) by @turukawa
110+
Fixing [#39](https://github.com/whythawk/full-stack-fastapi-postgresql/issues/39), thanks to @a-vorobyoff:
118111

119-
### 0.7.1
112+
- Exposing port 24678 for Vite on frontend in development mode.
113+
- Ensuring Nuxt content on /api/_content doesn't interfere with backend /api/v routes.
114+
- Checking for password before hashing on user creation.
115+
- Updating generated README for Hatch (after Poetry deprecation).
116+
- Minor fixes.
120117

121-
- SQLAlchemy 1.4 -> 2.0
122-
- Nuxt.js 3.0 -> 3.2.2
123-
- Fixed: `tokenUrl` in `app/api/deps.py`. Thanks to @Choiuijin1125.
124-
- Fixed: SMTP options for TLS must be `ssl`. Thanks to @raouldo.
125-
- Fixed: `libgeos` is a dependency for `shapely` which is a dependency for `neomodel`, and which doesn't appear to be installed correctly on Macs. Thanks to @valsha and @Mocha-L.
126-
- Fixed: `frontend` fails to start in development. Thanks to @pabloapast and @dividor.
118+
### 0.8.1
127119

128-
### 0.7.0
120+
- Minor updates to Docker scripts for `build`.
129121

130-
- New feature: magic (email-based) login, with password fallback
131-
- New feature: Time-based One-Time Password (TOTP) authentication
132-
- Security enhancements to improve consistency, safety and reliability of the authentication process (see full description in the frontend app)
133-
- Requires one new `frontend` dependency: [QRcode.vue](https://github.com/scopewu/qrcode.vue)
122+
### 0.8.0
134123

135-
[Historic changes from original](https://github.com/tiangolo/full-stack-fastapi-postgresql#release-notes)
124+
- Updates to `frontend`, [#37](https://github.com/whythawk/full-stack-fastapi-postgresql/pull/37) by @turukawa:
125+
- `@nuxtjs/i18n` for internationalisation, along with language selection component.
126+
- `@vite-pwa/nuxt` along with button components for install and refreshing the app and service workers, and a CLI icon generator.
127+
- `@nuxtjs/robots` for simple control of `robots.txt` permissions from `nuxt.config.ts`.
128+
129+
### 0.7.4
130+
131+
- Updates: Complete update of stack to latest long-term releases. [#35](https://github.com/whythawk/full-stack-fastapi-postgresql/pull/35) by @turukawa, review by @br3ndonland
132+
- `frontend`:
133+
- Node 16 -> 18
134+
- Nuxt 3.2 -> 3.6.5
135+
- Latest Pinia requires changes in stores, where imports are not required (cause actual errors), and parameter declaration must happen in functions.
136+
- `backend` and `celeryworker`:
137+
- Python 3.9 -> 3.11
138+
- FastAPI 0.88 -> 0.99 (Inboard 0.37 -> 0.51)
139+
- Poetry -> Hatch
140+
- Postgres 14 -> 15
141+
- Fixed: Updated token url in deps.py [#29](https://github.com/whythawk/full-stack-fastapi-postgresql/pull/29) by @vusa
142+
- Docs: Reorganised documentation [#21](https://github.com/whythawk/full-stack-fastapi-postgresql/pull/21) by @turukawa
136143

137144
## License
138145

0 commit comments

Comments
 (0)