microbootstrap 1.4.2__tar.gz → 1.4.3__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.
Files changed (38) hide show
  1. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/PKG-INFO +1 -1
  2. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/microbootstrap/granian_server.py +3 -1
  3. microbootstrap-1.4.3/pyproject.toml +173 -0
  4. microbootstrap-1.4.2/pyproject.toml → microbootstrap-1.4.3/pyproject.toml.orig +4 -1
  5. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/README.md +0 -0
  6. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/microbootstrap/__init__.py +0 -0
  7. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/microbootstrap/bootstrappers/__init__.py +0 -0
  8. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/microbootstrap/bootstrappers/base.py +0 -0
  9. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/microbootstrap/bootstrappers/fastapi.py +0 -0
  10. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/microbootstrap/bootstrappers/fastmcp.py +0 -0
  11. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/microbootstrap/bootstrappers/faststream.py +0 -0
  12. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/microbootstrap/bootstrappers/litestar.py +0 -0
  13. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/microbootstrap/config/__init__.py +0 -0
  14. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/microbootstrap/config/fastapi.py +0 -0
  15. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/microbootstrap/config/fastmcp.py +0 -0
  16. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/microbootstrap/config/faststream.py +0 -0
  17. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/microbootstrap/config/litestar.py +0 -0
  18. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/microbootstrap/console_writer.py +0 -0
  19. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/microbootstrap/exceptions.py +0 -0
  20. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/microbootstrap/helpers.py +0 -0
  21. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/microbootstrap/instruments/__init__.py +0 -0
  22. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/microbootstrap/instruments/base.py +0 -0
  23. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/microbootstrap/instruments/cors_instrument.py +0 -0
  24. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/microbootstrap/instruments/health_checks_instrument.py +0 -0
  25. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/microbootstrap/instruments/instrument_box.py +0 -0
  26. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/microbootstrap/instruments/logging_instrument.py +0 -0
  27. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/microbootstrap/instruments/opentelemetry_instrument.py +0 -0
  28. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/microbootstrap/instruments/prometheus_instrument.py +0 -0
  29. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/microbootstrap/instruments/pyroscope_instrument.py +0 -0
  30. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/microbootstrap/instruments/sentry_instrument.py +0 -0
  31. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/microbootstrap/instruments/swagger_instrument.py +0 -0
  32. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/microbootstrap/instruments_setupper.py +0 -0
  33. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/microbootstrap/middlewares/__init__.py +0 -0
  34. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/microbootstrap/middlewares/fastapi.py +0 -0
  35. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/microbootstrap/middlewares/fastmcp.py +0 -0
  36. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/microbootstrap/middlewares/litestar.py +0 -0
  37. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/microbootstrap/py.typed +0 -0
  38. {microbootstrap-1.4.2 → microbootstrap-1.4.3}/microbootstrap/settings.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: microbootstrap
3
- Version: 1.4.2
3
+ Version: 1.4.3
4
4
  Summary: Package for bootstrapping new micro-services
5
5
  Keywords: python,microservice,bootstrap,opentelemetry,logging,error-tracing,litestar,fastapi,fastmcp,mcp
6
6
  Author: community-of-python
@@ -27,13 +27,15 @@ GRANIAN_LOG_LEVELS_MAP = {
27
27
  def create_granian_server(
28
28
  target: str,
29
29
  settings: ServerConfig,
30
+ *,
31
+ interface: Interfaces = Interfaces.ASGI,
30
32
  **granian_options: typing.Any, # noqa: ANN401
31
33
  ) -> GranianServer[typing.Any]:
32
34
  return granian.Granian(
33
35
  target=target,
34
36
  address=settings.server_host,
35
37
  port=settings.server_port,
36
- interface=Interfaces.ASGI,
38
+ interface=interface,
37
39
  workers=settings.server_workers_count,
38
40
  log_level=GRANIAN_LOG_LEVELS_MAP[getattr(settings, "logging_log_level", logging.INFO)],
39
41
  reload=settings.server_reload,
@@ -0,0 +1,173 @@
1
+ [project]
2
+ name = "microbootstrap"
3
+ description = "Package for bootstrapping new micro-services"
4
+ readme = "README.md"
5
+ requires-python = ">=3.10,<4"
6
+ keywords = [
7
+ "python",
8
+ "microservice",
9
+ "bootstrap",
10
+ "opentelemetry",
11
+ "logging",
12
+ "error-tracing",
13
+ "litestar",
14
+ "fastapi",
15
+ "fastmcp",
16
+ "mcp",
17
+ ]
18
+ classifiers = [
19
+ "Typing :: Typed",
20
+ "Topic :: Software Development :: Build Tools",
21
+ "Operating System :: MacOS",
22
+ "Operating System :: Microsoft",
23
+ "Operating System :: POSIX :: Linux",
24
+ "Intended Audience :: Developers",
25
+ "Programming Language :: Python",
26
+ "Programming Language :: Python :: 3",
27
+ "Programming Language :: Python :: 3 :: Only",
28
+ "Programming Language :: Python :: 3.10",
29
+ "Programming Language :: Python :: 3.11",
30
+ "Programming Language :: Python :: 3.12",
31
+ "Programming Language :: Python :: 3.13",
32
+ "Programming Language :: Python :: 3.14",
33
+ ]
34
+ dependencies = [
35
+ "eval-type-backport>=0.2",
36
+ "opentelemetry-api>=1.30.0",
37
+ "opentelemetry-exporter-otlp>=1.15.0",
38
+ "opentelemetry-exporter-prometheus-remote-write>=0.46b0",
39
+ "opentelemetry-instrumentation>=0.46b0",
40
+ "opentelemetry-instrumentation-system-metrics>=0.46b0",
41
+ "opentelemetry-sdk>=1.30.0",
42
+ "pydantic-settings>=2",
43
+ "rich>=13",
44
+ "sentry-sdk>=2.7",
45
+ "structlog>=24",
46
+ "pyroscope-io>=1.0.0; platform_system != 'Windows'",
47
+ "opentelemetry-distro[otlp]>=0.54b1",
48
+ "opentelemetry-instrumentation-aio-pika>=0.54b1",
49
+ "opentelemetry-instrumentation-aiohttp-client>=0.54b1",
50
+ "opentelemetry-instrumentation-aiokafka>=0.54b1",
51
+ "opentelemetry-instrumentation-asyncpg>=0.54b1",
52
+ "opentelemetry-instrumentation-httpx>=0.54b1",
53
+ "opentelemetry-instrumentation-logging>=0.54b1",
54
+ "opentelemetry-instrumentation-redis>=0.54b1",
55
+ "opentelemetry-instrumentation-psycopg>=0.54b1",
56
+ "opentelemetry-instrumentation-sqlalchemy>=0.54b1",
57
+ "opentelemetry-instrumentation-asyncio>=0.54b1",
58
+ "opentelemetry-instrumentation-asgi>=0.46b0",
59
+ "orjson>=3.10.18",
60
+ ]
61
+ version = "1.4.3"
62
+
63
+ [[project.authors]]
64
+ name = "community-of-python"
65
+
66
+ [project.optional-dependencies]
67
+ fastapi = [
68
+ "fastapi>=0.100",
69
+ "fastapi-offline-docs>=1",
70
+ "opentelemetry-instrumentation-fastapi>=0.46b0",
71
+ "prometheus-fastapi-instrumentator>=6.1",
72
+ ]
73
+ litestar = [
74
+ "litestar>=2.9",
75
+ "litestar-offline-docs>=1",
76
+ "prometheus-client>=0.20",
77
+ ]
78
+ granian = ["granian[reload]>=1"]
79
+ faststream = [
80
+ "faststream~=0.6.2",
81
+ "prometheus-client>=0.20",
82
+ ]
83
+ fastmcp = [
84
+ "fastmcp>=2,<4",
85
+ "prometheus-client>=0.20",
86
+ ]
87
+
88
+ [dependency-groups]
89
+ dev = [
90
+ "anyio>=4.8.0",
91
+ "httpx>=0.28.1",
92
+ "mypy>=1.14.1",
93
+ "pre-commit>=4.0.1",
94
+ "pytest>=8.3.4",
95
+ "pytest-cov>=6.0.0",
96
+ "pytest-mock>=3.14.0",
97
+ "pytest-xdist>=3.6.1",
98
+ "redis>=5.2.1",
99
+ "ruff>=0.9.1",
100
+ "trio>=0.28.0",
101
+ "typing-extensions>=4.12.2",
102
+ ]
103
+
104
+ [build-system]
105
+ requires = ["uv_build"]
106
+ build-backend = "uv_build"
107
+
108
+ [tool.uv.build-backend]
109
+ module-name = "microbootstrap"
110
+ module-root = ""
111
+
112
+ [tool.mypy]
113
+ plugins = ["pydantic.mypy"]
114
+ files = [
115
+ "microbootstrap",
116
+ "tests",
117
+ ]
118
+ python_version = "3.10"
119
+ strict = true
120
+ pretty = true
121
+ show_error_codes = true
122
+
123
+ [tool.ruff]
124
+ target-version = "py310"
125
+ line-length = 120
126
+
127
+ [tool.ruff.format]
128
+ exclude = ["README.md"]
129
+ docstring-code-format = true
130
+
131
+ [tool.ruff.lint]
132
+ select = ["ALL"]
133
+ ignore = [
134
+ "CPY001",
135
+ "EM",
136
+ "FBT",
137
+ "TRY003",
138
+ "FIX002",
139
+ "TD003",
140
+ "D1",
141
+ "D106",
142
+ "D203",
143
+ "D213",
144
+ "G004",
145
+ "FA",
146
+ "COM812",
147
+ "ISC001",
148
+ "PLR0917",
149
+ ]
150
+
151
+ [tool.ruff.lint.isort]
152
+ no-lines-before = [
153
+ "standard-library",
154
+ "local-folder",
155
+ ]
156
+ lines-after-imports = 2
157
+
158
+ [tool.ruff.lint.extend-per-file-ignores]
159
+ "tests/*.py" = [
160
+ "S101",
161
+ "S311",
162
+ ]
163
+ "examples/*.py" = ["INP001"]
164
+
165
+ [tool.coverage.report]
166
+ exclude_also = [
167
+ "if typing.TYPE_CHECKING:",
168
+ 'class \w+\(typing.Protocol\):',
169
+ ]
170
+ omit = ["tests/*"]
171
+
172
+ [tool.pytest.ini_options]
173
+ addopts = "--cov=. -p no:warnings --cov-report term-missing"
@@ -58,7 +58,7 @@ dependencies = [
58
58
  "opentelemetry-instrumentation-asgi>=0.46b0",
59
59
  "orjson>=3.10.18",
60
60
  ]
61
- version = "1.4.2"
61
+ version = "1.4.3"
62
62
  authors = [{ name = "community-of-python" }]
63
63
 
64
64
  [project.optional-dependencies]
@@ -114,11 +114,13 @@ target-version = "py310"
114
114
  line-length = 120
115
115
 
116
116
  [tool.ruff.format]
117
+ exclude = ["README.md"]
117
118
  docstring-code-format = true
118
119
 
119
120
  [tool.ruff.lint]
120
121
  select = ["ALL"]
121
122
  ignore = [
123
+ "CPY001",
122
124
  "EM",
123
125
  "FBT",
124
126
  "TRY003",
@@ -132,6 +134,7 @@ ignore = [
132
134
  "FA",
133
135
  "COM812",
134
136
  "ISC001",
137
+ "PLR0917",
135
138
  ]
136
139
 
137
140
  [tool.ruff.lint.isort]
File without changes