You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- The maximum number of concurrent container instances you want to run at any given moment. Stopped containers do not count towards this - you may have more container instances than this number overall, but only this many actively running containers at once. If a request to start a container will exceed this limit, that request will error.
995
+
- The maximum number of concurrent container instances you want to run at any given moment. Stopped containers do not count towards this - you may have more container instances than this number overall, but only this many actively running containers at once. If a request to start a container will exceed this limit, that request will error.
996
996
997
997
- Defaults to 20.
998
998
@@ -1128,6 +1128,28 @@ Any files that match `rules` will also be included as unbundled, external module
1128
1128
1129
1129
See https://developers.cloudflare.com/workers/wrangler/bundling/ for more details and examples.
1130
1130
1131
+
### Python Workers
1132
+
1133
+
By default, Python Workers bundle the files and folders in `python_modules` at the root of your Worker (alongside your wrangler config file).
1134
+
The files in this directory represent your vendored packages and is where the pywrangler tool copies packages into. In some cases, you
1135
+
may find that the files in this folder are too large and if your worker doesn't require them then they just grow your bundle size for
1136
+
no reason.
1137
+
1138
+
To fix this, you can exclude certain files from being included. To do this use the `python_modules.excludes` option, for example:
1139
+
1140
+
<WranglerConfig>
1141
+
1142
+
```toml title="wrangler.toml"
1143
+
[python_modules]
1144
+
excludes = ["**/*.pyc", "**/__pycache__"]
1145
+
```
1146
+
1147
+
</WranglerConfig>
1148
+
1149
+
This will exclude any .pyc files and `__pycache__` directories inside any subdirectory in `python_modules`.
1150
+
1151
+
By default, `python_modules.excludes` is set to `["**/*.pyc"]`, so be sure to include this when setting it to a different value.
0 commit comments