nitro-framework 0.3.1__tar.gz → 0.3.2__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 (142) hide show
  1. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/Cargo.lock +37 -37
  2. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/Cargo.toml +4 -4
  3. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/PKG-INFO +1 -1
  4. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/__init__.py +1 -1
  5. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/sessions.py +37 -1
  6. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/settings/__init__.py +9 -10
  7. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/pyproject.toml +1 -1
  8. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/LICENSE-APACHE +0 -0
  9. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/LICENSE-MIT +0 -0
  10. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/README.md +0 -0
  11. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/intercom-core/Cargo.toml +0 -0
  12. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/intercom-core/LICENSE-APACHE +0 -0
  13. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/intercom-core/LICENSE-MIT +0 -0
  14. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/intercom-core/src/channel.rs +0 -0
  15. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/intercom-core/src/codec.rs +0 -0
  16. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/intercom-core/src/intercom_core.rs +0 -0
  17. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/intercom-core/src/redis.rs +0 -0
  18. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/intercom-core/tests/redis_backend.rs +0 -0
  19. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-core/Cargo.toml +0 -0
  20. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-core/LICENSE-APACHE +0 -0
  21. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-core/LICENSE-MIT +0 -0
  22. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-core/examples/floor.rs +0 -0
  23. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-core/src/config.rs +0 -0
  24. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-core/src/disconnect.rs +0 -0
  25. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-core/src/files.rs +0 -0
  26. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-core/src/headers.rs +0 -0
  27. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-core/src/hosts.rs +0 -0
  28. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-core/src/lifecycle/drain.rs +0 -0
  29. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-core/src/lifecycle/signals.rs +0 -0
  30. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-core/src/lifecycle.rs +0 -0
  31. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-core/src/nitro_core.rs +0 -0
  32. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-core/src/router/matcher.rs +0 -0
  33. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-core/src/router/route.rs +0 -0
  34. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-core/src/router.rs +0 -0
  35. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-core/src/streaming.rs +0 -0
  36. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-core/src/transport/accept.rs +0 -0
  37. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-core/src/transport/connection.rs +0 -0
  38. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-core/src/transport/quic.rs +0 -0
  39. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-core/src/transport/tls.rs +0 -0
  40. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-core/src/transport.rs +0 -0
  41. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-core/src/websocket.rs +0 -0
  42. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-core/src/webtransport.rs +0 -0
  43. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-core/tests/observability.rs +0 -0
  44. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-core/tests/serving.rs +0 -0
  45. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-core/tests/signals.rs +0 -0
  46. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-core/tests/webtransport.rs +0 -0
  47. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-observability/Cargo.toml +0 -0
  48. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-observability/LICENSE-APACHE +0 -0
  49. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-observability/LICENSE-MIT +0 -0
  50. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-observability/src/exporter.rs +0 -0
  51. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-observability/src/metrics.rs +0 -0
  52. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-observability/src/nitro_observability.rs +0 -0
  53. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-py/Cargo.toml +0 -0
  54. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-py/LICENSE-APACHE +0 -0
  55. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-py/LICENSE-MIT +0 -0
  56. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-py/src/config.rs +0 -0
  57. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-py/src/dispatch.rs +0 -0
  58. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-py/src/handoff.rs +0 -0
  59. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-py/src/headers.rs +0 -0
  60. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-py/src/intercom_bridge.rs +0 -0
  61. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-py/src/lifecycle.rs +0 -0
  62. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-py/src/nitro_py.rs +0 -0
  63. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-py/src/protocol.rs +0 -0
  64. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-py/src/scope.rs +0 -0
  65. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/crates/nitro-py/src/server.rs +0 -0
  66. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/app.py +0 -0
  67. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/cache/__init__.py +0 -0
  68. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/cache/backends/__init__.py +0 -0
  69. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/cache/backends/memcached.py +0 -0
  70. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/cache/backends/memory.py +0 -0
  71. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/cache/backends/redis.py +0 -0
  72. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/cache/base.py +0 -0
  73. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/cache/handler.py +0 -0
  74. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/cli/__init__.py +0 -0
  75. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/cli/__main__.py +0 -0
  76. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/cli/commands/__init__.py +0 -0
  77. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/cli/commands/check.py +0 -0
  78. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/cli/commands/shell.py +0 -0
  79. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/cli/commands/static.py +0 -0
  80. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/cli/commands/version.py +0 -0
  81. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/cli/serve.py +0 -0
  82. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/di/__init__.py +0 -0
  83. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/endpoints.py +0 -0
  84. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/intercom/__init__.py +0 -0
  85. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/intercom/backends.py +0 -0
  86. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/log.py +0 -0
  87. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/mail/__init__.py +0 -0
  88. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/mail/backends/__init__.py +0 -0
  89. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/mail/backends/base.py +0 -0
  90. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/mail/backends/console.py +0 -0
  91. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/mail/backends/oauth_smtp.py +0 -0
  92. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/mail/backends/sendgrid.py +0 -0
  93. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/mail/backends/ses.py +0 -0
  94. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/mail/backends/smtp.py +0 -0
  95. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/mail/message.py +0 -0
  96. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/mail/utils.py +0 -0
  97. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/middleware/__init__.py +0 -0
  98. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/middleware/base.py +0 -0
  99. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/middleware/common.py +0 -0
  100. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/middleware/stack.py +0 -0
  101. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/protocols/__init__.py +0 -0
  102. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/protocols/exceptions.py +0 -0
  103. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/protocols/http.py +0 -0
  104. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/protocols/websocket.py +0 -0
  105. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/protocols/webtransport.py +0 -0
  106. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/reload.py +0 -0
  107. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/routing/__init__.py +0 -0
  108. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/routing/converters.py +0 -0
  109. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/routing/mount.py +0 -0
  110. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/routing/parameters.py +0 -0
  111. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/routing/patterns.py +0 -0
  112. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/routing/reverse.py +0 -0
  113. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/routing/router.py +0 -0
  114. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/settings/defaults.py +0 -0
  115. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/shortcuts.py +0 -0
  116. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/staticfiles.py +0 -0
  117. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/storage/__init__.py +0 -0
  118. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/storage/backends/__init__.py +0 -0
  119. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/storage/backends/azure.py +0 -0
  120. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/storage/backends/filesystem.py +0 -0
  121. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/storage/backends/memory.py +0 -0
  122. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/storage/backends/s3.py +0 -0
  123. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/storage/base.py +0 -0
  124. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/storage/handler.py +0 -0
  125. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/templates/__init__.py +0 -0
  126. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/templates/engine.py +0 -0
  127. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/templates/exceptions.py +0 -0
  128. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/templates/templates.py +0 -0
  129. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/testing.py +0 -0
  130. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/utils/__init__.py +0 -0
  131. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/utils/archives.py +0 -0
  132. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/utils/content.py +0 -0
  133. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/utils/crypto.py +0 -0
  134. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/utils/datetime.py +0 -0
  135. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/utils/decorators.py +0 -0
  136. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/utils/http.py +0 -0
  137. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/utils/json.py +0 -0
  138. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/utils/modules.py +0 -0
  139. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/views/__init__.py +0 -0
  140. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/views/debug.py +0 -0
  141. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/views/templates/error_404.html +0 -0
  142. {nitro_framework-0.3.1 → nitro_framework-0.3.2}/nitro/views/templates/error_500.html +0 -0
@@ -333,7 +333,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
333
333
  checksum = "39cab71617ae0d63f51a36d69f866391735b51691dbda63cf6f96d042b63efeb"
334
334
  dependencies = [
335
335
  "libc",
336
- "windows-sys 0.61.2",
336
+ "windows-sys 0.52.0",
337
337
  ]
338
338
 
339
339
  [[package]]
@@ -653,9 +653,9 @@ dependencies = [
653
653
 
654
654
  [[package]]
655
655
  name = "hyper"
656
- version = "1.11.1"
656
+ version = "1.12.0"
657
657
  source = "registry+https://github.com/rust-lang/crates.io-index"
658
- checksum = "27b501faa50e7a26c3d3560ca625132f4078a17771f4810baf70475ae48cbe43"
658
+ checksum = "2c3e324da4c95177d6291d4c8730197c0d1822f8a9766814a4a44fa5ab797c9c"
659
659
  dependencies = [
660
660
  "atomic-waker",
661
661
  "bytes",
@@ -827,7 +827,7 @@ dependencies = [
827
827
 
828
828
  [[package]]
829
829
  name = "intercom-core"
830
- version = "0.3.1"
830
+ version = "0.3.2"
831
831
  dependencies = [
832
832
  "bytes",
833
833
  "futures-util",
@@ -842,7 +842,7 @@ dependencies = [
842
842
 
843
843
  [[package]]
844
844
  name = "intercom-py"
845
- version = "0.3.1"
845
+ version = "0.3.2"
846
846
  dependencies = [
847
847
  "bytes",
848
848
  "futures-util",
@@ -943,9 +943,9 @@ checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe"
943
943
 
944
944
  [[package]]
945
945
  name = "libc"
946
- version = "0.2.189"
946
+ version = "0.2.191"
947
947
  source = "registry+https://github.com/rust-lang/crates.io-index"
948
- checksum = "3eaf3ede3fee6db1a4c2ee091bf8a8b4dccdc6d17f656fb07896ee72867612f2"
948
+ checksum = "65cd87c9a6d60536580b316ad985726104730a5151c99845f2490428ef91240a"
949
949
 
950
950
  [[package]]
951
951
  name = "linux-raw-sys"
@@ -1030,7 +1030,7 @@ dependencies = [
1030
1030
 
1031
1031
  [[package]]
1032
1032
  name = "nitro-core"
1033
- version = "0.3.1"
1033
+ version = "0.3.2"
1034
1034
  dependencies = [
1035
1035
  "base64 0.23.1",
1036
1036
  "bytes",
@@ -1072,7 +1072,7 @@ dependencies = [
1072
1072
 
1073
1073
  [[package]]
1074
1074
  name = "nitro-observability"
1075
- version = "0.3.1"
1075
+ version = "0.3.2"
1076
1076
  dependencies = [
1077
1077
  "bytes",
1078
1078
  "futures-util",
@@ -1090,7 +1090,7 @@ dependencies = [
1090
1090
 
1091
1091
  [[package]]
1092
1092
  name = "nitro-py"
1093
- version = "0.3.1"
1093
+ version = "0.3.2"
1094
1094
  dependencies = [
1095
1095
  "bytes",
1096
1096
  "futures-util",
@@ -1298,9 +1298,9 @@ dependencies = [
1298
1298
 
1299
1299
  [[package]]
1300
1300
  name = "pyo3"
1301
- version = "0.29.2"
1301
+ version = "0.29.3"
1302
1302
  source = "registry+https://github.com/rust-lang/crates.io-index"
1303
- checksum = "4688ddedf473e32662b9b067670129a8afb8c18e351482c70d62ba4a88171e8b"
1303
+ checksum = "700d18fa267b73b9b521fd7e13580e2f446916f176cacee1ab63fcc8191f1655"
1304
1304
  dependencies = [
1305
1305
  "libc",
1306
1306
  "once_cell",
@@ -1326,18 +1326,18 @@ dependencies = [
1326
1326
 
1327
1327
  [[package]]
1328
1328
  name = "pyo3-build-config"
1329
- version = "0.29.2"
1329
+ version = "0.29.3"
1330
1330
  source = "registry+https://github.com/rust-lang/crates.io-index"
1331
- checksum = "f41027e41b4bd03f6e60f9f417fe24a6341a6bb744edd62b6f709f2a52ea30e9"
1331
+ checksum = "7b3fc0c4d08f6bb10e71fe39dfb9e2f59c6eb6854e22ec8092f50c69a4499adb"
1332
1332
  dependencies = [
1333
1333
  "target-lexicon",
1334
1334
  ]
1335
1335
 
1336
1336
  [[package]]
1337
1337
  name = "pyo3-ffi"
1338
- version = "0.29.2"
1338
+ version = "0.29.3"
1339
1339
  source = "registry+https://github.com/rust-lang/crates.io-index"
1340
- checksum = "e591a95526fead067432c3b3a33fc74770b87b1e04e73671090d9c2055a2b327"
1340
+ checksum = "dfc0b8e19df29aad7086cf977bb0c2a2f143e30567eb113e9cf72b62ca698330"
1341
1341
  dependencies = [
1342
1342
  "libc",
1343
1343
  "pyo3-build-config",
@@ -1345,9 +1345,9 @@ dependencies = [
1345
1345
 
1346
1346
  [[package]]
1347
1347
  name = "pyo3-macros"
1348
- version = "0.29.2"
1348
+ version = "0.29.3"
1349
1349
  source = "registry+https://github.com/rust-lang/crates.io-index"
1350
- checksum = "73225868fc1cd84eef2c3c230ddb91273bf1de46aeb8a4248da76d32a0924a1c"
1350
+ checksum = "6100e8a4b5eba53afaa5ed078364851a0b2499c553a44c31026b929049b49dc6"
1351
1351
  dependencies = [
1352
1352
  "proc-macro2",
1353
1353
  "pyo3-macros-backend",
@@ -1357,9 +1357,9 @@ dependencies = [
1357
1357
 
1358
1358
  [[package]]
1359
1359
  name = "pyo3-macros-backend"
1360
- version = "0.29.2"
1360
+ version = "0.29.3"
1361
1361
  source = "registry+https://github.com/rust-lang/crates.io-index"
1362
- checksum = "571575aa3749fa6216757dd47d2a3e7ef360f329a40f0666a9fbd14889024952"
1362
+ checksum = "6143877a16e82b5a727b7127ff4cd86858a24a28d745d72f43e6f227c7b1bdb3"
1363
1363
  dependencies = [
1364
1364
  "heck",
1365
1365
  "proc-macro2",
@@ -1421,7 +1421,7 @@ dependencies = [
1421
1421
  "once_cell",
1422
1422
  "socket2",
1423
1423
  "tracing",
1424
- "windows-sys 0.61.2",
1424
+ "windows-sys 0.52.0",
1425
1425
  ]
1426
1426
 
1427
1427
  [[package]]
@@ -1481,9 +1481,9 @@ dependencies = [
1481
1481
 
1482
1482
  [[package]]
1483
1483
  name = "redis"
1484
- version = "1.7.1"
1484
+ version = "1.8.1"
1485
1485
  source = "registry+https://github.com/rust-lang/crates.io-index"
1486
- checksum = "ed5b98ae99461e02895c3a96a25dbe4d852a3d5e5b815d31d5d9e4b5344d99e9"
1486
+ checksum = "db7f3d75b5a3301746bff39a767bf4c5c42506b08513527308b3875bfb64a031"
1487
1487
  dependencies = [
1488
1488
  "arc-swap",
1489
1489
  "arcstr",
@@ -1657,14 +1657,14 @@ dependencies = [
1657
1657
  "errno",
1658
1658
  "libc",
1659
1659
  "linux-raw-sys",
1660
- "windows-sys 0.61.2",
1660
+ "windows-sys 0.52.0",
1661
1661
  ]
1662
1662
 
1663
1663
  [[package]]
1664
1664
  name = "rustls"
1665
- version = "0.23.45"
1665
+ version = "0.23.46"
1666
1666
  source = "registry+https://github.com/rust-lang/crates.io-index"
1667
- checksum = "0d41d731c7d2f962d1ccc364cec258de3c0e93b38c2fb3ba97ac74513048d634"
1667
+ checksum = "48e13bd8c0e9365c43cfa5c9e8f9ad49d3c8444926c9aac819e0e4dc503c8fdf"
1668
1668
  dependencies = [
1669
1669
  "aws-lc-rs",
1670
1670
  "log",
@@ -1725,7 +1725,7 @@ dependencies = [
1725
1725
  "security-framework",
1726
1726
  "security-framework-sys",
1727
1727
  "webpki-root-certs",
1728
- "windows-sys 0.61.2",
1728
+ "windows-sys 0.52.0",
1729
1729
  ]
1730
1730
 
1731
1731
  [[package]]
@@ -1843,9 +1843,9 @@ dependencies = [
1843
1843
 
1844
1844
  [[package]]
1845
1845
  name = "serde_json"
1846
- version = "1.0.151"
1846
+ version = "1.0.154"
1847
1847
  source = "registry+https://github.com/rust-lang/crates.io-index"
1848
- checksum = "c841b55ecdae098c80dcae9cf767f6f8a0c2cdb3416bbef72181df4d0fe73f14"
1848
+ checksum = "e7e9cc8b1b85264074fbcc02a88680c4096b1e47df8f739dceb03bf482f04bd6"
1849
1849
  dependencies = [
1850
1850
  "itoa",
1851
1851
  "memchr",
@@ -2009,7 +2009,7 @@ dependencies = [
2009
2009
  "getrandom 0.4.3",
2010
2010
  "once_cell",
2011
2011
  "rustix",
2012
- "windows-sys 0.61.2",
2012
+ "windows-sys 0.52.0",
2013
2013
  ]
2014
2014
 
2015
2015
  [[package]]
@@ -2098,9 +2098,9 @@ checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20"
2098
2098
 
2099
2099
  [[package]]
2100
2100
  name = "tokio"
2101
- version = "1.53.1"
2101
+ version = "1.54.1"
2102
2102
  source = "registry+https://github.com/rust-lang/crates.io-index"
2103
- checksum = "202caea871b69668250d242070849eb495be178ed697a3e98aebce5bc81a0bed"
2103
+ checksum = "b52fd3255258d26fac7264ab5a76b53c13367136dc011d3d6ad4f8ed070396a3"
2104
2104
  dependencies = [
2105
2105
  "bytes",
2106
2106
  "libc",
@@ -2152,9 +2152,9 @@ dependencies = [
2152
2152
 
2153
2153
  [[package]]
2154
2154
  name = "tokio-util"
2155
- version = "0.7.19"
2155
+ version = "0.7.20"
2156
2156
  source = "registry+https://github.com/rust-lang/crates.io-index"
2157
- checksum = "494815d09bf52b5548659851081238f0ca39ff638363907596da739561c62c52"
2157
+ checksum = "e464cf451ba96ebfc6f9b6542f17ee8b8956e33f1e40d9690624e59d7a7f8a4b"
2158
2158
  dependencies = [
2159
2159
  "bytes",
2160
2160
  "futures-core",
@@ -2369,9 +2369,9 @@ dependencies = [
2369
2369
 
2370
2370
  [[package]]
2371
2371
  name = "want"
2372
- version = "0.3.1"
2372
+ version = "0.3.2"
2373
2373
  source = "registry+https://github.com/rust-lang/crates.io-index"
2374
- checksum = "bfa7760aed19e106de2c7c0b581b509f2f25d3dacaf737cb82ac61bc6d760b0e"
2374
+ checksum = "ec4cdd0dd910afe868b7ef477227d8d538b46b3075031afee8a9f2acb0a2ed0b"
2375
2375
  dependencies = [
2376
2376
  "try-lock",
2377
2377
  ]
@@ -2503,7 +2503,7 @@ version = "0.1.11"
2503
2503
  source = "registry+https://github.com/rust-lang/crates.io-index"
2504
2504
  checksum = "c2a7b1c03c876122aa43f3020e6c3c3ee5c05081c9a00739faf7503aeba10d22"
2505
2505
  dependencies = [
2506
- "windows-sys 0.61.2",
2506
+ "windows-sys 0.52.0",
2507
2507
  ]
2508
2508
 
2509
2509
  [[package]]
@@ -5,14 +5,14 @@ members = ["crates/nitro-core", "crates/nitro-observability", "crates/nitro-py",
5
5
  [workspace.package]
6
6
  edition = "2024"
7
7
  license = "MIT OR Apache-2.0"
8
- version = "0.3.1"
8
+ version = "0.3.2"
9
9
  authors = ["Mario Ritzerfeld <oss@jaldis.com>"]
10
10
  repository = "https://github.com/jaldisdev/nitro"
11
11
 
12
12
  [workspace.dependencies]
13
- nitro-core = { path = "crates/nitro-core", version = "0.3.1" }
14
- nitro-observability = { path = "crates/nitro-observability", version = "0.3.1" }
15
- intercom-core = { path = "crates/intercom-core", version = "0.3.1" }
13
+ nitro-core = { path = "crates/nitro-core", version = "0.3.2" }
14
+ nitro-observability = { path = "crates/nitro-observability", version = "0.3.2" }
15
+ intercom-core = { path = "crates/intercom-core", version = "0.3.2" }
16
16
 
17
17
  # Async runtime
18
18
  tokio = { version = "1.53.1", features = ["full"] }
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: nitro-framework
3
- Version: 0.3.1
3
+ Version: 0.3.2
4
4
  Classifier: Development Status :: 3 - Alpha
5
5
  Classifier: Framework :: AsyncIO
6
6
  Classifier: Intended Audience :: Developers
@@ -21,6 +21,6 @@
21
21
 
22
22
  from nitro.app import Nitro
23
23
 
24
- __version__ = "0.3.1"
24
+ __version__ = "0.3.2"
25
25
 
26
26
  __all__ = ["Nitro", "__version__"]
@@ -81,6 +81,13 @@ class SessionStore(Protocol):
81
81
  outlives an eviction, or one an application already queries for its own
82
82
  reasons. :class:`CacheSessionStore` is the default and is enough for state
83
83
  that may be lost.
84
+
85
+ A store whose sessions are created elsewhere — rows an application writes
86
+ at sign-in and nowhere else — says so with an ``allocates_keys = False``
87
+ attribute, and :meth:`Session.set` then refuses a bag with no key at the
88
+ write instead of reaching a :meth:`create` that cannot answer. The
89
+ attribute is optional and taken as true when it is absent, since a store
90
+ predating it had no way to get a key but `create`.
84
91
  """
85
92
 
86
93
  async def read(self, key: str) -> dict[str, Any] | None:
@@ -193,6 +200,23 @@ class Session:
193
200
  """Whether the bag has been read. A session nothing touched has not."""
194
201
  return self._data is not None
195
202
 
203
+ async def writable(self) -> bool:
204
+ """Whether something stored in this bag could be read back.
205
+
206
+ False for a bag with no key in a store that does not allocate them:
207
+ the application creates its sessions itself and this connection is not
208
+ in one. An API token naming no session, and a key whose session has
209
+ expired or been revoked, both arrive here — so a handler storing
210
+ something a later request has to find asks this first.
211
+
212
+ A coroutine rather than a property because the answer is not in the
213
+ key: a key the store has nothing under is dropped when the bag is read,
214
+ and reading it is what settles the question.
215
+ """
216
+ await self._load()
217
+
218
+ return self._key is not None or getattr(self._store, "allocates_keys", True)
219
+
196
220
  async def _load(self) -> dict[str, Any]:
197
221
  if self._data is not None:
198
222
  return self._data
@@ -218,7 +242,19 @@ class Session:
218
242
  return data.get(name, default)
219
243
 
220
244
  async def set(self, name: str, value: Any) -> None:
221
- """Store `value` under `name`."""
245
+ """Store `value` under `name`.
246
+
247
+ Raises :class:`SessionError` when the bag has nowhere to be written
248
+ back to, which :meth:`writable` answers without raising. The refusal
249
+ belongs here rather than at the save that would otherwise fail: by then
250
+ the handler has answered the request and the frame that wrote is gone.
251
+ """
252
+ if not await self.writable():
253
+ raise SessionError(
254
+ f"nothing can be stored under {name!r}: this connection carries no session key, "
255
+ f"and {type(self._store).__name__} does not allocate one"
256
+ )
257
+
222
258
  data = await self._load()
223
259
  data[name] = value
224
260
  self._modified = True
@@ -82,26 +82,25 @@ class LazySettings:
82
82
  _wrapped: Settings | None
83
83
 
84
84
  def __init__(self) -> None:
85
- object.__setattr__(self, "_wrapped", None)
85
+ self._wrapped = None
86
86
 
87
87
  def _setup(self) -> Settings:
88
88
  resolved = Settings(os.environ.get(ENVIRONMENT_VARIABLE))
89
- object.__setattr__(self, "_wrapped", resolved)
89
+ self._wrapped = resolved
90
90
  return resolved
91
91
 
92
+ # An assignment is kept on the proxy, where it shadows the resolved value,
93
+ # rather than written through to the resolved settings. Deleting it then
94
+ # restores what resolution produced, instead of leaving a hole where a
95
+ # default was: `Settings` copies the defaults onto itself, so a name
96
+ # deleted there is gone for the rest of the process. That is what undoing
97
+ # a `monkeypatch.setattr` does, since the name is not one the proxy held.
92
98
  def __getattr__(self, name: str) -> Any:
93
99
  if name.startswith("_"):
94
100
  raise AttributeError(f"{type(self).__name__!r} object has no attribute {name!r}")
95
101
  resolved = self._wrapped or self._setup()
96
102
  return getattr(resolved, name)
97
103
 
98
- def __setattr__(self, name: str, value: Any) -> None:
99
- if name.startswith("_"):
100
- object.__setattr__(self, name, value)
101
- return
102
- resolved = self._wrapped or self._setup()
103
- setattr(resolved, name, value)
104
-
105
104
  @property
106
105
  def configured(self) -> bool:
107
106
  """Whether the settings have been resolved yet."""
@@ -112,7 +111,7 @@ class LazySettings:
112
111
 
113
112
  Intended for tests that change the environment between cases.
114
113
  """
115
- object.__setattr__(self, "_wrapped", None)
114
+ self._wrapped = None
116
115
 
117
116
  def __repr__(self) -> str:
118
117
  if self._wrapped is None:
@@ -4,7 +4,7 @@ build-backend = "maturin"
4
4
 
5
5
  [project]
6
6
  name = "nitro-framework"
7
- version = "0.3.1"
7
+ version = "0.3.2"
8
8
  description = "Async-first Python web framework with a bundled Rust server"
9
9
  readme = "README.md"
10
10
  requires-python = ">=3.13"