plain.dev 0.39.1__tar.gz → 0.41.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.
- {plain_dev-0.39.1 → plain_dev-0.41.0}/PKG-INFO +2 -3
- {plain_dev-0.39.1 → plain_dev-0.41.0}/plain/dev/CHANGELOG.md +22 -0
- {plain_dev-0.39.1 → plain_dev-0.41.0}/plain/dev/README.md +1 -1
- {plain_dev-0.39.1 → plain_dev-0.41.0}/plain/dev/core.py +36 -26
- {plain_dev-0.39.1 → plain_dev-0.41.0}/pyproject.toml +1 -2
- plain_dev-0.39.1/plain/dev/gunicorn_logging.json +0 -40
- {plain_dev-0.39.1 → plain_dev-0.41.0}/.gitignore +0 -0
- {plain_dev-0.39.1 → plain_dev-0.41.0}/LICENSE +0 -0
- {plain_dev-0.39.1 → plain_dev-0.41.0}/README.md +0 -0
- {plain_dev-0.39.1 → plain_dev-0.41.0}/plain/dev/AGENTS.md +0 -0
- {plain_dev-0.39.1 → plain_dev-0.41.0}/plain/dev/__init__.py +0 -0
- {plain_dev-0.39.1 → plain_dev-0.41.0}/plain/dev/alias.py +0 -0
- {plain_dev-0.39.1 → plain_dev-0.41.0}/plain/dev/cli.py +0 -0
- {plain_dev-0.39.1 → plain_dev-0.41.0}/plain/dev/contribute/README.md +0 -0
- {plain_dev-0.39.1 → plain_dev-0.41.0}/plain/dev/contribute/__init__.py +0 -0
- {plain_dev-0.39.1 → plain_dev-0.41.0}/plain/dev/contribute/cli.py +0 -0
- {plain_dev-0.39.1 → plain_dev-0.41.0}/plain/dev/debug.py +0 -0
- {plain_dev-0.39.1 → plain_dev-0.41.0}/plain/dev/default_settings.py +0 -0
- {plain_dev-0.39.1 → plain_dev-0.41.0}/plain/dev/entrypoints.py +0 -0
- {plain_dev-0.39.1 → plain_dev-0.41.0}/plain/dev/mkcert.py +0 -0
- {plain_dev-0.39.1 → plain_dev-0.41.0}/plain/dev/pdb.py +0 -0
- {plain_dev-0.39.1 → plain_dev-0.41.0}/plain/dev/poncho/__init__.py +0 -0
- {plain_dev-0.39.1 → plain_dev-0.41.0}/plain/dev/poncho/color.py +0 -0
- {plain_dev-0.39.1 → plain_dev-0.41.0}/plain/dev/poncho/compat.py +0 -0
- {plain_dev-0.39.1 → plain_dev-0.41.0}/plain/dev/poncho/manager.py +0 -0
- {plain_dev-0.39.1 → plain_dev-0.41.0}/plain/dev/poncho/printer.py +0 -0
- {plain_dev-0.39.1 → plain_dev-0.41.0}/plain/dev/poncho/process.py +0 -0
- {plain_dev-0.39.1 → plain_dev-0.41.0}/plain/dev/precommit/__init__.py +0 -0
- {plain_dev-0.39.1 → plain_dev-0.41.0}/plain/dev/precommit/cli.py +0 -0
- {plain_dev-0.39.1 → plain_dev-0.41.0}/plain/dev/process.py +0 -0
- {plain_dev-0.39.1 → plain_dev-0.41.0}/plain/dev/services.py +0 -0
- {plain_dev-0.39.1 → plain_dev-0.41.0}/plain/dev/utils.py +0 -0
- {plain_dev-0.39.1 → plain_dev-0.41.0}/tests/settings.py +0 -0
@@ -1,13 +1,12 @@
|
|
1
1
|
Metadata-Version: 2.4
|
2
2
|
Name: plain.dev
|
3
|
-
Version: 0.
|
3
|
+
Version: 0.41.0
|
4
4
|
Summary: A single command that runs everything you need for local development.
|
5
5
|
Author-email: Dave Gaeddert <dave.gaeddert@dropseed.dev>
|
6
6
|
License-Expression: BSD-3-Clause
|
7
7
|
License-File: LICENSE
|
8
8
|
Requires-Python: >=3.13
|
9
9
|
Requires-Dist: click>=8.0.0
|
10
|
-
Requires-Dist: gunicorn>20
|
11
10
|
Requires-Dist: inotify
|
12
11
|
Requires-Dist: plain<1.0.0
|
13
12
|
Requires-Dist: python-dotenv~=1.0.0
|
@@ -78,7 +77,7 @@ postgres = {cmd = "docker run --name app-postgres --rm -p 54321:5432 -v $(pwd)/.
|
|
78
77
|
|
79
78
|
#### Custom processes
|
80
79
|
|
81
|
-
Unlike [services](#services), custom processes are _only_ run during `plain dev`. This is a good place to run something like [ngrok](https://ngrok.com/) or a [Plain worker](../../../plain-
|
80
|
+
Unlike [services](#services), custom processes are _only_ run during `plain dev`. This is a good place to run something like [ngrok](https://ngrok.com/) or a [Plain job worker](../../../plain-jobs), which you might need to use your local site, but don't need running for executing tests, for example.
|
82
81
|
|
83
82
|
```toml
|
84
83
|
# pyproject.toml
|
@@ -1,5 +1,27 @@
|
|
1
1
|
# plain-dev changelog
|
2
2
|
|
3
|
+
## [0.41.0](https://github.com/dropseed/plain/releases/plain-dev@0.41.0) (2025-10-12)
|
4
|
+
|
5
|
+
### What's changed
|
6
|
+
|
7
|
+
- The `plain dev` command now uses the new `plain server` command instead of `gunicorn` for running the development server ([f9dc2867c7](https://github.com/dropseed/plain/commit/f9dc2867c7))
|
8
|
+
- Removed `gunicorn` as a dependency - the development server now uses Plain's built-in HTTP server ([f9dc2867c7](https://github.com/dropseed/plain/commit/f9dc2867c7))
|
9
|
+
- Removed gunicorn-specific logging configuration file in favor of simplified log formatting ([fb8a00ca73](https://github.com/dropseed/plain/commit/fb8a00ca73))
|
10
|
+
|
11
|
+
### Upgrade instructions
|
12
|
+
|
13
|
+
- No changes required
|
14
|
+
|
15
|
+
## [0.40.0](https://github.com/dropseed/plain/releases/plain-dev@0.40.0) (2025-10-10)
|
16
|
+
|
17
|
+
### What's changed
|
18
|
+
|
19
|
+
- Updated documentation to reference `plain-jobs` instead of the deprecated `plain-worker` package name ([24219856e0](https://github.com/dropseed/plain/commit/24219856e0))
|
20
|
+
|
21
|
+
### Upgrade instructions
|
22
|
+
|
23
|
+
- No changes required
|
24
|
+
|
3
25
|
## [0.39.1](https://github.com/dropseed/plain/releases/plain-dev@0.39.1) (2025-10-06)
|
4
26
|
|
5
27
|
### What's changed
|
@@ -61,7 +61,7 @@ postgres = {cmd = "docker run --name app-postgres --rm -p 54321:5432 -v $(pwd)/.
|
|
61
61
|
|
62
62
|
#### Custom processes
|
63
63
|
|
64
|
-
Unlike [services](#services), custom processes are _only_ run during `plain dev`. This is a good place to run something like [ngrok](https://ngrok.com/) or a [Plain worker](../../../plain-
|
64
|
+
Unlike [services](#services), custom processes are _only_ run during `plain dev`. This is a good place to run something like [ngrok](https://ngrok.com/) or a [Plain job worker](../../../plain-jobs), which you might need to use your local site, but don't need running for executing tests, for example.
|
65
65
|
|
66
66
|
```toml
|
67
67
|
# pyproject.toml
|
@@ -167,7 +167,7 @@ class DevProcess(ProcessManager):
|
|
167
167
|
# another thread checking db stuff...
|
168
168
|
self.console_status.start()
|
169
169
|
|
170
|
-
self.
|
170
|
+
self.add_server()
|
171
171
|
self.add_entrypoints()
|
172
172
|
self.add_pyproject_run()
|
173
173
|
|
@@ -271,18 +271,16 @@ class DevProcess(ProcessManager):
|
|
271
271
|
click.secho("Preflight check failed!", fg="red")
|
272
272
|
sys.exit(1)
|
273
273
|
|
274
|
-
def
|
275
|
-
|
276
|
-
|
277
|
-
|
278
|
-
|
279
|
-
|
280
|
-
|
281
|
-
|
282
|
-
|
283
|
-
|
284
|
-
gunicorn_cmd = [
|
285
|
-
"gunicorn",
|
274
|
+
def add_server(self) -> None:
|
275
|
+
"""Add the Plain HTTP server process."""
|
276
|
+
# Build the server command using plain's internal server
|
277
|
+
# Note: We can't use reload here because watchfiles is handled at a higher level
|
278
|
+
# The server command will use gunicorn's built-in reload capability
|
279
|
+
server_cmd = [
|
280
|
+
sys.executable,
|
281
|
+
"-m",
|
282
|
+
"plain",
|
283
|
+
"server",
|
286
284
|
"--bind",
|
287
285
|
f"{self.hostname}:{self.port}",
|
288
286
|
"--certfile",
|
@@ -291,25 +289,37 @@ class DevProcess(ProcessManager):
|
|
291
289
|
str(self.ssl_key_path),
|
292
290
|
"--threads",
|
293
291
|
"4",
|
294
|
-
"--reload",
|
295
|
-
"plain.wsgi:app",
|
296
292
|
"--timeout",
|
297
293
|
"60",
|
298
294
|
"--log-level",
|
299
295
|
self.log_level or "info",
|
300
|
-
"--
|
301
|
-
"-",
|
302
|
-
"--error-logfile",
|
303
|
-
"-",
|
304
|
-
*reload_extra.split(),
|
305
|
-
"--access-logformat",
|
306
|
-
"'\"%(r)s\" status=%(s)s length=%(b)s time=%(M)sms'",
|
307
|
-
"--log-config-json",
|
308
|
-
str(Path(__file__).parent / "gunicorn_logging.json"),
|
296
|
+
"--reload", # Enable auto-reload for development
|
309
297
|
]
|
310
|
-
gunicorn = " ".join(gunicorn_cmd)
|
311
298
|
|
312
|
-
|
299
|
+
# Watch .env files for reload
|
300
|
+
extra_watch_files = []
|
301
|
+
for f in os.listdir(APP_PATH.parent):
|
302
|
+
if f.startswith(".env"):
|
303
|
+
# Needs to be absolute or "./" for inotify to work on Linux...
|
304
|
+
# https://github.com/dropseed/plain/issues/26
|
305
|
+
extra_watch_files.append(str(Path(APP_PATH.parent) / f))
|
306
|
+
|
307
|
+
# Add extra watch files
|
308
|
+
for watch_file in extra_watch_files:
|
309
|
+
server_cmd.extend(["--reload-extra-file", watch_file])
|
310
|
+
|
311
|
+
# Add logging configuration
|
312
|
+
server_cmd.extend(
|
313
|
+
[
|
314
|
+
"--log-format",
|
315
|
+
"'[%(levelname)s] %(message)s'",
|
316
|
+
"--access-log-format",
|
317
|
+
"'\"%(r)s\" status=%(s)s length=%(b)s time=%(M)sms'",
|
318
|
+
]
|
319
|
+
)
|
320
|
+
|
321
|
+
server = " ".join(server_cmd)
|
322
|
+
self.poncho.add_process("plain", server, env=self.plain_env)
|
313
323
|
|
314
324
|
def add_entrypoints(self) -> None:
|
315
325
|
for entry_point in entry_points().select(group=ENTRYPOINT_GROUP):
|
@@ -1,6 +1,6 @@
|
|
1
1
|
[project]
|
2
2
|
name = "plain.dev"
|
3
|
-
version = "0.
|
3
|
+
version = "0.41.0"
|
4
4
|
description = "A single command that runs everything you need for local development."
|
5
5
|
authors = [{name = "Dave Gaeddert", email = "dave.gaeddert@dropseed.dev"}]
|
6
6
|
license = "BSD-3-Clause"
|
@@ -10,7 +10,6 @@ dependencies = [
|
|
10
10
|
"plain<1.0.0",
|
11
11
|
"click>=8.0.0",
|
12
12
|
"python-dotenv~=1.0.0",
|
13
|
-
"gunicorn>20",
|
14
13
|
"requests>=2.0.0",
|
15
14
|
"rich",
|
16
15
|
"inotify",
|
@@ -1,40 +0,0 @@
|
|
1
|
-
{
|
2
|
-
"version": 1,
|
3
|
-
"disable_existing_loggers": false,
|
4
|
-
"root": {
|
5
|
-
"level": "INFO",
|
6
|
-
"handlers": ["console"]
|
7
|
-
},
|
8
|
-
"loggers": {
|
9
|
-
"gunicorn.error": {
|
10
|
-
"level": "INFO",
|
11
|
-
"handlers": ["error_console"],
|
12
|
-
"propagate": false,
|
13
|
-
"qualname": "gunicorn.error"
|
14
|
-
},
|
15
|
-
"gunicorn.access": {
|
16
|
-
"level": "INFO",
|
17
|
-
"handlers": ["console"],
|
18
|
-
"propagate": false,
|
19
|
-
"qualname": "gunicorn.access"
|
20
|
-
}
|
21
|
-
},
|
22
|
-
"handlers": {
|
23
|
-
"console": {
|
24
|
-
"class": "logging.StreamHandler",
|
25
|
-
"formatter": "generic",
|
26
|
-
"stream": "ext://sys.stdout"
|
27
|
-
},
|
28
|
-
"error_console": {
|
29
|
-
"class": "logging.StreamHandler",
|
30
|
-
"formatter": "generic",
|
31
|
-
"stream": "ext://sys.stderr"
|
32
|
-
}
|
33
|
-
},
|
34
|
-
"formatters": {
|
35
|
-
"generic": {
|
36
|
-
"format": "[%(process)d] [%(levelname)s] %(message)s",
|
37
|
-
"class": "logging.Formatter"
|
38
|
-
}
|
39
|
-
}
|
40
|
-
}
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|