sharedbox 0.5.0__tar.gz → 0.7.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.
Files changed (307) hide show
  1. {sharedbox-0.5.0 → sharedbox-0.7.0}/.github/dependabot.yml +2 -0
  2. sharedbox-0.7.0/.github/pull_request_template.md +3 -0
  3. sharedbox-0.7.0/.github/workflows/check-changelog.yaml +47 -0
  4. {sharedbox-0.5.0 → sharedbox-0.7.0}/.github/workflows/ci.yaml +37 -7
  5. sharedbox-0.7.0/.github/workflows/ops.yaml +108 -0
  6. sharedbox-0.7.0/.github/workflows/prepare-release.yaml +78 -0
  7. sharedbox-0.7.0/.github/workflows/streams.yaml +85 -0
  8. {sharedbox-0.5.0 → sharedbox-0.7.0}/.gitignore +2 -1
  9. sharedbox-0.7.0/CHANGELOG.md +555 -0
  10. {sharedbox-0.5.0 → sharedbox-0.7.0}/CLAUDE.md +119 -56
  11. {sharedbox-0.5.0 → sharedbox-0.7.0}/CMakeLists.txt +6 -0
  12. {sharedbox-0.5.0 → sharedbox-0.7.0}/PKG-INFO +38 -25
  13. {sharedbox-0.5.0 → sharedbox-0.7.0}/README.md +36 -23
  14. sharedbox-0.7.0/benchmarks/test_bench_box.py +440 -0
  15. sharedbox-0.7.0/benchmarks/test_bench_stream.py +31 -0
  16. sharedbox-0.7.0/docs/assets/benchmarks/ops.json +1 -0
  17. sharedbox-0.7.0/docs/assets/benchmarks/roundtrip.json +1 -0
  18. sharedbox-0.7.0/docs/assets/benchmarks/stream-matrix.json +1 -0
  19. sharedbox-0.7.0/docs/assets/benchmarks/stream-throughput.json +1 -0
  20. sharedbox-0.7.0/docs/examples/change_several_fields_at_once.py +44 -0
  21. sharedbox-0.7.0/docs/examples/clean_up_segments.py +38 -0
  22. sharedbox-0.7.0/docs/examples/follow_a_whole_reference_graph.py +46 -0
  23. sharedbox-0.7.0/docs/examples/name_a_box.py +45 -0
  24. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/examples/send_a_box_to_another_process.py +14 -14
  25. sharedbox-0.7.0/docs/examples/send_items_through_a_stream.py +129 -0
  26. sharedbox-0.7.0/docs/examples/set_defaults_and_check_values.py +79 -0
  27. sharedbox-0.7.0/docs/examples/store_a_large_list.py +81 -0
  28. sharedbox-0.7.0/docs/examples/store_a_large_set_or_dict.py +107 -0
  29. sharedbox-0.7.0/docs/examples/store_arrays.py +87 -0
  30. sharedbox-0.7.0/docs/examples/store_collections.py +40 -0
  31. sharedbox-0.7.0/docs/examples/store_numpy_numbers.py +82 -0
  32. sharedbox-0.7.0/docs/examples/store_records.py +53 -0
  33. sharedbox-0.7.0/docs/examples/store_text_and_bytes.py +46 -0
  34. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/explanation/closing-and-lifetime.md +15 -15
  35. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/explanation/field-types.md +25 -1
  36. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/explanation/glossary.md +40 -1
  37. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/explanation/how-a-box-is-stored.md +41 -39
  38. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/explanation/limits.md +5 -6
  39. sharedbox-0.7.0/docs/explanation/performance.md +221 -0
  40. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/explanation/references.md +24 -24
  41. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/explanation/waiting-for-changes.md +35 -26
  42. sharedbox-0.7.0/docs/explanation/when-to-use-sharedbox.md +59 -0
  43. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/how-to/accept-a-box-in-c.md +11 -9
  44. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/how-to/accept-a-box-in-cpp.md +24 -24
  45. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/how-to/change-several-fields-at-once.md +3 -3
  46. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/how-to/clean-up-segments.md +3 -3
  47. sharedbox-0.7.0/docs/how-to/commits-and-prs.md +103 -0
  48. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/how-to/follow-a-whole-reference-graph.md +8 -8
  49. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/how-to/index.md +7 -2
  50. sharedbox-0.7.0/docs/how-to/make-a-release.md +76 -0
  51. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/how-to/name-a-box.md +5 -3
  52. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/how-to/open-a-box-from-a-program.md +5 -5
  53. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/how-to/run-benchmarks.md +61 -17
  54. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/how-to/send-a-box-to-another-process.md +3 -3
  55. sharedbox-0.7.0/docs/how-to/send-items-through-a-stream.md +293 -0
  56. sharedbox-0.7.0/docs/how-to/store-a-large-list.md +152 -0
  57. sharedbox-0.7.0/docs/how-to/store-a-large-set-or-dict.md +235 -0
  58. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/how-to/store-arrays.md +82 -24
  59. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/how-to/store-collections.md +9 -1
  60. sharedbox-0.7.0/docs/how-to/store-numpy-numbers.md +107 -0
  61. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/how-to/store-text-and-bytes.md +7 -1
  62. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/how-to/write-docs.md +2 -2
  63. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/index.md +64 -59
  64. sharedbox-0.7.0/docs/javascripts/charts.js +88 -0
  65. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/reference/api/arrays.md +2 -2
  66. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/reference/api/box.md +18 -0
  67. sharedbox-0.7.0/docs/reference/api/errors.md +73 -0
  68. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/reference/api/events.md +8 -1
  69. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/reference/api/index.md +2 -1
  70. sharedbox-0.7.0/docs/reference/api/streams.md +44 -0
  71. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/reference/cpp-and-c-api.md +8 -5
  72. sharedbox-0.7.0/docs/reference/segment-layout.md +1521 -0
  73. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/tutorials/index.md +1 -1
  74. sharedbox-0.7.0/docs/tutorials/mailbox.py +102 -0
  75. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/tutorials/react-to-changes.md +29 -29
  76. sharedbox-0.7.0/docs/tutorials/refer-to-another-box.md +106 -0
  77. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/tutorials/share-a-record.md +21 -21
  78. sharedbox-0.7.0/include/sharedbox/box.hpp +1140 -0
  79. sharedbox-0.5.0/include/sharedbox/sharedbox.hpp → sharedbox-0.7.0/include/sharedbox/core.hpp +755 -1554
  80. sharedbox-0.7.0/include/sharedbox/sharedbox.hpp +21 -0
  81. {sharedbox-0.5.0 → sharedbox-0.7.0}/include/sharedbox/sharedbox_c.cpp +47 -13
  82. {sharedbox-0.5.0 → sharedbox-0.7.0}/include/sharedbox/sharedbox_c.h +10 -0
  83. sharedbox-0.7.0/include/sharedbox/stream.hpp +1038 -0
  84. {sharedbox-0.5.0 → sharedbox-0.7.0}/pyproject.toml +44 -3
  85. sharedbox-0.7.0/scripts/release_notes.py +52 -0
  86. sharedbox-0.7.0/scripts/stream_compare.py +101 -0
  87. {sharedbox-0.5.0 → sharedbox-0.7.0}/src/sharedbox/__init__.py +34 -1
  88. {sharedbox-0.5.0 → sharedbox-0.7.0}/src/sharedbox/_arrays.py +9 -2
  89. sharedbox-0.7.0/src/sharedbox/_bounded.py +354 -0
  90. {sharedbox-0.5.0 → sharedbox-0.7.0}/src/sharedbox/_box.py +48 -20
  91. {sharedbox-0.5.0 → sharedbox-0.7.0}/src/sharedbox/_events.py +71 -100
  92. {sharedbox-0.5.0 → sharedbox-0.7.0}/src/sharedbox/_layout.py +93 -10
  93. {sharedbox-0.5.0 → sharedbox-0.7.0}/src/sharedbox/_native/codec.cpp +38 -19
  94. {sharedbox-0.5.0 → sharedbox-0.7.0}/src/sharedbox/_native/codec.hpp +56 -0
  95. sharedbox-0.7.0/src/sharedbox/_native/collection.cpp +662 -0
  96. sharedbox-0.7.0/src/sharedbox/_native/collection.hpp +226 -0
  97. sharedbox-0.7.0/src/sharedbox/_native/dict.cpp +386 -0
  98. sharedbox-0.7.0/src/sharedbox/_native/dict.hpp +88 -0
  99. sharedbox-0.7.0/src/sharedbox/_native/keys.cpp +369 -0
  100. sharedbox-0.7.0/src/sharedbox/_native/keys.hpp +130 -0
  101. {sharedbox-0.5.0 → sharedbox-0.7.0}/src/sharedbox/_native/module.cpp +397 -65
  102. {sharedbox-0.5.0 → sharedbox-0.7.0}/src/sharedbox/_native/scalars.cpp +253 -41
  103. {sharedbox-0.5.0 → sharedbox-0.7.0}/src/sharedbox/_native/scalars.hpp +13 -5
  104. {sharedbox-0.5.0 → sharedbox-0.7.0}/src/sharedbox/_native/segment.cpp +59 -53
  105. {sharedbox-0.5.0 → sharedbox-0.7.0}/src/sharedbox/_native/segment.hpp +12 -12
  106. sharedbox-0.7.0/src/sharedbox/_native/set.cpp +335 -0
  107. sharedbox-0.7.0/src/sharedbox/_native/set.hpp +87 -0
  108. sharedbox-0.7.0/src/sharedbox/_native/stream.cpp +676 -0
  109. sharedbox-0.7.0/src/sharedbox/_native/stream.hpp +10 -0
  110. {sharedbox-0.5.0 → sharedbox-0.7.0}/src/sharedbox/_native/types.cpp +520 -68
  111. sharedbox-0.7.0/src/sharedbox/_native/types.hpp +250 -0
  112. sharedbox-0.7.0/src/sharedbox/_native.pyi +1259 -0
  113. {sharedbox-0.5.0 → sharedbox-0.7.0}/src/sharedbox/_refs.py +15 -6
  114. sharedbox-0.7.0/src/sharedbox/_stream.py +1614 -0
  115. {sharedbox-0.5.0 → sharedbox-0.7.0}/src/sharedbox/_types.py +512 -53
  116. {sharedbox-0.5.0 → sharedbox-0.7.0}/src/sharedbox/_version.py +3 -3
  117. sharedbox-0.7.0/src/sharedbox/benchmarks/__init__.py +3 -0
  118. {sharedbox-0.5.0 → sharedbox-0.7.0}/src/sharedbox/benchmarks/_app.py +40 -6
  119. {sharedbox-0.5.0 → sharedbox-0.7.0}/src/sharedbox/benchmarks/ops.py +323 -3
  120. sharedbox-0.7.0/src/sharedbox/benchmarks/plot.py +331 -0
  121. {sharedbox-0.5.0 → sharedbox-0.7.0}/src/sharedbox/benchmarks/roundtrip.py +51 -2
  122. sharedbox-0.7.0/src/sharedbox/benchmarks/stream.py +906 -0
  123. sharedbox-0.7.0/src/sharedbox/py.typed +0 -0
  124. sharedbox-0.7.0/stubtest-allowlist.txt +47 -0
  125. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/conftest.py +7 -3
  126. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/cpp/CMakeLists.txt +6 -2
  127. sharedbox-0.7.0/tests/cpp/bench_stream.cpp +83 -0
  128. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/cpp/compile_fail.cpp +1 -1
  129. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/cpp/consumer/consumer.c +4 -0
  130. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/cpp/test_c_smoke.c +8 -0
  131. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/cpp/test_c_smoke_box.cpp +4 -5
  132. sharedbox-0.7.0/tests/cpp/test_core_alone.cpp +10 -0
  133. sharedbox-0.7.0/tests/cpp/test_layout3.cpp +188 -0
  134. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/cpp/test_lock.cpp +8 -8
  135. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/cpp/test_mapping.cpp +83 -60
  136. sharedbox-0.7.0/tests/cpp/test_result.cpp +171 -0
  137. sharedbox-0.7.0/tests/cpp/test_slots.cpp +302 -0
  138. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/cpp/test_small_shm.cpp +1 -2
  139. sharedbox-0.7.0/tests/cpp/test_stream.cpp +965 -0
  140. sharedbox-0.7.0/tests/cpp/test_stream_layout.cpp +167 -0
  141. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/cpp/test_types.cpp +67 -27
  142. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/cpp/test_values.cpp +45 -15
  143. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/cpp/test_wait.cpp +80 -5
  144. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/cpp/test_write_in_place.cpp +3 -3
  145. sharedbox-0.7.0/tests/crossproc.py +71 -0
  146. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/forged_open.py +35 -10
  147. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/forged_types.py +5 -4
  148. sharedbox-0.7.0/tests/os_names.py +8 -0
  149. sharedbox-0.7.0/tests/streamproc.py +179 -0
  150. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/stress/stress_helpers.py +3 -3
  151. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/stress/test_stress_read_into.py +1 -1
  152. sharedbox-0.7.0/tests/test_benchbox_all.py +62 -0
  153. sharedbox-0.7.0/tests/test_benchbox_plot.py +154 -0
  154. sharedbox-0.7.0/tests/test_benchbox_roundtrip.py +8 -0
  155. sharedbox-0.7.0/tests/test_benchbox_stream.py +149 -0
  156. sharedbox-0.7.0/tests/test_bounded_dict.py +728 -0
  157. sharedbox-0.7.0/tests/test_bounded_list.py +944 -0
  158. sharedbox-0.7.0/tests/test_bounded_set.py +873 -0
  159. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_box.py +34 -1
  160. sharedbox-0.7.0/tests/test_box_sync_async.py +62 -0
  161. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_capsule.py +41 -6
  162. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_doc_examples.py +5 -2
  163. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_doc_tutorials.py +11 -9
  164. sharedbox-0.7.0/tests/test_events_future.py +281 -0
  165. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_fields.py +50 -1
  166. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_fork.py +1 -9
  167. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_layout.py +38 -2
  168. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_native_segment.py +88 -53
  169. sharedbox-0.7.0/tests/test_native_stream.py +383 -0
  170. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_native_types.py +0 -20
  171. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_native_waiters.py +5 -4
  172. sharedbox-0.7.0/tests/test_properties_bounded.py +286 -0
  173. sharedbox-0.7.0/tests/test_properties_bounded_dict.py +250 -0
  174. sharedbox-0.7.0/tests/test_properties_bounded_set.py +249 -0
  175. sharedbox-0.7.0/tests/test_properties_numpy.py +99 -0
  176. sharedbox-0.7.0/tests/test_properties_stream.py +121 -0
  177. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_refs.py +49 -3
  178. sharedbox-0.7.0/tests/test_stream.py +676 -0
  179. sharedbox-0.7.0/tests/test_stream_async.py +480 -0
  180. sharedbox-0.7.0/tests/test_stream_events.py +488 -0
  181. sharedbox-0.7.0/tests/test_stream_fork.py +72 -0
  182. sharedbox-0.7.0/tests/test_stream_processes.py +268 -0
  183. sharedbox-0.7.0/tests/test_stream_writing.py +350 -0
  184. sharedbox-0.7.0/tests/test_types_arrays.py +598 -0
  185. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_types_collections.py +43 -0
  186. sharedbox-0.7.0/tests/test_types_numpy.py +456 -0
  187. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_types_records.py +101 -5
  188. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_types_records_attrs.py +18 -0
  189. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_types_unions.py +14 -0
  190. sharedbox-0.7.0/tests/type_checks/array_types.py +20 -0
  191. sharedbox-0.7.0/tests/type_checks/bounded_types.py +36 -0
  192. sharedbox-0.7.0/tests/type_checks/stream_types.py +58 -0
  193. {sharedbox-0.5.0 → sharedbox-0.7.0}/uv.lock +43 -547
  194. {sharedbox-0.5.0 → sharedbox-0.7.0}/zensical.toml +8 -1
  195. sharedbox-0.5.0/.claude/settings.json +0 -33
  196. sharedbox-0.5.0/CHANGELOG.md +0 -340
  197. sharedbox-0.5.0/benchmarks/test_bench_box.py +0 -98
  198. sharedbox-0.5.0/docs/assets/benchmarks/ops-dark.svg +0 -1209
  199. sharedbox-0.5.0/docs/assets/benchmarks/ops-light.svg +0 -1209
  200. sharedbox-0.5.0/docs/assets/benchmarks/roundtrip-dark.svg +0 -334
  201. sharedbox-0.5.0/docs/assets/benchmarks/roundtrip-light.svg +0 -334
  202. sharedbox-0.5.0/docs/examples/change_several_fields_at_once.py +0 -44
  203. sharedbox-0.5.0/docs/examples/clean_up_segments.py +0 -38
  204. sharedbox-0.5.0/docs/examples/follow_a_whole_reference_graph.py +0 -46
  205. sharedbox-0.5.0/docs/examples/name_a_box.py +0 -45
  206. sharedbox-0.5.0/docs/examples/set_defaults_and_check_values.py +0 -79
  207. sharedbox-0.5.0/docs/examples/store_arrays.py +0 -52
  208. sharedbox-0.5.0/docs/examples/store_collections.py +0 -39
  209. sharedbox-0.5.0/docs/examples/store_records.py +0 -52
  210. sharedbox-0.5.0/docs/examples/store_text_and_bytes.py +0 -46
  211. sharedbox-0.5.0/docs/explanation/performance.md +0 -82
  212. sharedbox-0.5.0/docs/explanation/when-to-use-sharedbox.md +0 -46
  213. sharedbox-0.5.0/docs/how-to/commits-and-prs.md +0 -72
  214. sharedbox-0.5.0/docs/how-to/make-a-release.md +0 -88
  215. sharedbox-0.5.0/docs/reference/api/errors.md +0 -43
  216. sharedbox-0.5.0/docs/reference/segment-layout.md +0 -983
  217. sharedbox-0.5.0/docs/tutorials/motor.py +0 -102
  218. sharedbox-0.5.0/docs/tutorials/refer-to-another-box.md +0 -104
  219. sharedbox-0.5.0/src/sharedbox/_native/types.hpp +0 -125
  220. sharedbox-0.5.0/src/sharedbox/_native.pyi +0 -425
  221. sharedbox-0.5.0/src/sharedbox/benchmarks/__init__.py +0 -5
  222. sharedbox-0.5.0/src/sharedbox/benchmarks/plot.py +0 -161
  223. sharedbox-0.5.0/stubtest-allowlist.txt +0 -19
  224. sharedbox-0.5.0/tests/cpp/test_layout2.cpp +0 -126
  225. sharedbox-0.5.0/tests/cpp/test_result.cpp +0 -121
  226. sharedbox-0.5.0/tests/cpp/test_slots.cpp +0 -157
  227. sharedbox-0.5.0/tests/crossproc.py +0 -36
  228. sharedbox-0.5.0/tests/test_benchbox_plot.py +0 -63
  229. sharedbox-0.5.0/tests/test_layout_v1.py +0 -50
  230. sharedbox-0.5.0/tests/test_types_arrays.py +0 -212
  231. {sharedbox-0.5.0 → sharedbox-0.7.0}/.clang-format +0 -0
  232. {sharedbox-0.5.0 → sharedbox-0.7.0}/.github/workflows/check-docs.yaml +0 -0
  233. {sharedbox-0.5.0 → sharedbox-0.7.0}/.github/workflows/codspeed.yml +0 -0
  234. {sharedbox-0.5.0 → sharedbox-0.7.0}/.github/workflows/contention.yaml +0 -0
  235. {sharedbox-0.5.0 → sharedbox-0.7.0}/.github/workflows/publish-docs.yaml +0 -0
  236. {sharedbox-0.5.0 → sharedbox-0.7.0}/LICENSE +0 -0
  237. /sharedbox-0.5.0/src/sharedbox/py.typed → /sharedbox-0.7.0/changelog.d/.gitkeep +0 -0
  238. {sharedbox-0.5.0 → sharedbox-0.7.0}/cmake/sharedbox-config.cmake +0 -0
  239. {sharedbox-0.5.0 → sharedbox-0.7.0}/cmake/sharedbox-require-cxx.cmake +0 -0
  240. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/diagrams/style.d2 +0 -0
  241. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/explanation/checking-a-process-is-alive.md +0 -0
  242. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/explanation/how-the-module-is-built.md +0 -0
  243. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/explanation/index.md +0 -0
  244. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/explanation/reading-and-writing.md +0 -0
  245. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/how-to/ai-contribution-policy.md +0 -0
  246. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/how-to/build-docs.md +0 -0
  247. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/how-to/contribute.md +0 -0
  248. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/how-to/install-sharedbox.md +0 -0
  249. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/how-to/run-commit-checks.md +0 -0
  250. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/how-to/run-tests.md +0 -0
  251. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/how-to/set-defaults-and-check-values.md +0 -0
  252. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/how-to/set-up-development.md +0 -0
  253. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/how-to/store-records.md +0 -0
  254. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/reference/api/library-authors.md +0 -0
  255. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/reference/api/references.md +0 -0
  256. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/reference/changelog.md +0 -0
  257. {sharedbox-0.5.0 → sharedbox-0.7.0}/docs/reference/index.md +0 -0
  258. {sharedbox-0.5.0 → sharedbox-0.7.0}/includes/abbreviations.md +0 -0
  259. {sharedbox-0.5.0 → sharedbox-0.7.0}/prek.toml +0 -0
  260. {sharedbox-0.5.0 → sharedbox-0.7.0}/scripts/check_xrefs.py +0 -0
  261. {sharedbox-0.5.0 → sharedbox-0.7.0}/scripts/vscode_setup.py +0 -0
  262. {sharedbox-0.5.0 → sharedbox-0.7.0}/src/sharedbox/_follow.py +0 -0
  263. {sharedbox-0.5.0 → sharedbox-0.7.0}/src/sharedbox/benchmarks/__main__.py +0 -0
  264. {sharedbox-0.5.0 → sharedbox-0.7.0}/src/sharedbox/benchmarks/cli.py +0 -0
  265. {sharedbox-0.5.0 → sharedbox-0.7.0}/src/sharedbox/benchmarks/contention.py +0 -0
  266. {sharedbox-0.5.0 → sharedbox-0.7.0}/src/sharedbox/benchmarks/size.py +0 -0
  267. {sharedbox-0.5.0 → sharedbox-0.7.0}/src/sharedbox/benchmarks/size_diff.py +0 -0
  268. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/cpp/consumer/CMakeLists.txt +0 -0
  269. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/cpp/table_builder.hpp +0 -0
  270. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/cpp/test_atomics.cpp +0 -0
  271. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/cpp/test_fork.cpp +0 -0
  272. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/cpp/test_windows_h.cpp +0 -0
  273. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/cpp/unique.hpp +0 -0
  274. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/refs_future.py +0 -0
  275. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/stress/test_stress_contention.py +0 -0
  276. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/stress/test_stress_crashes.py +0 -0
  277. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/stress/test_stress_follow.py +0 -0
  278. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/stress/test_stress_lock_timeout.py +0 -0
  279. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/stress/test_stress_memory.py +0 -0
  280. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/stress/test_stress_waiters.py +0 -0
  281. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/stress/test_stress_watchers.py +0 -0
  282. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_benchbox_contention.py +0 -0
  283. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_events_async.py +0 -0
  284. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_events_bytes.py +0 -0
  285. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_events_signals.py +0 -0
  286. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_events_sync.py +0 -0
  287. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_exit.py +0 -0
  288. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_follow.py +0 -0
  289. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_native_codec.py +0 -0
  290. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_native_liveness.py +0 -0
  291. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_native_wait.py +0 -0
  292. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_properties_codec.py +0 -0
  293. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_properties_forged.py +0 -0
  294. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_properties_layout.py +0 -0
  295. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_properties_stateful.py +0 -0
  296. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_properties_types.py +0 -0
  297. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_read_into.py +0 -0
  298. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_refs_lazy.py +0 -0
  299. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_types_arrays_bfloat16.py +0 -0
  300. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_types_arrays_torch.py +0 -0
  301. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_types_choices.py +0 -0
  302. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_types_records_msgspec.py +0 -0
  303. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_types_scalars.py +0 -0
  304. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_value_reuse.py +0 -0
  305. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/test_writing.py +0 -0
  306. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/type_checks/box_types.py +0 -0
  307. {sharedbox-0.5.0 → sharedbox-0.7.0}/tests/type_checks/events_types.py +0 -0
@@ -4,6 +4,7 @@ updates:
4
4
  directory: /
5
5
  schedule:
6
6
  interval: weekly
7
+ labels: [dependencies, skip-changelog]
7
8
  commit-message:
8
9
  prefix: ci
9
10
  groups:
@@ -14,6 +15,7 @@ updates:
14
15
  directory: /
15
16
  schedule:
16
17
  interval: weekly
18
+ labels: [dependencies, skip-changelog]
17
19
  commit-message:
18
20
  prefix: build
19
21
  include: scope
@@ -0,0 +1,3 @@
1
+ <!-- One bullet per change a reviewer can see, in the imperative. -->
2
+
3
+ - [ ] Added a file to `changelog.d/` for each change a user notices, or this pull request changes nothing a user notices and needs the `skip-changelog` label
@@ -0,0 +1,47 @@
1
+ name: Changelog
2
+
3
+ on:
4
+ pull_request:
5
+ types: [opened, reopened, synchronize, labeled, unlabeled]
6
+
7
+ permissions:
8
+ contents: read
9
+ pull-requests: read
10
+
11
+ jobs:
12
+ entry:
13
+ name: Require a changelog entry
14
+ runs-on: ubuntu-latest
15
+ steps:
16
+ - name: Read the labels
17
+ id: labels
18
+ env:
19
+ GH_TOKEN: ${{ github.token }}
20
+ PR: ${{ github.event.pull_request.number }}
21
+ REPO: ${{ github.repository }}
22
+ run: |
23
+ # read now rather than from the event: a pull request opened with a
24
+ # label gets it a moment after its "opened" event fires
25
+ skip=$(gh pr view "$PR" --repo "$REPO" --json labels --jq 'any(.labels[]; .name == "skip-changelog")')
26
+ echo "skip=$skip" >> "$GITHUB_OUTPUT"
27
+ if [ "$skip" = "true" ]; then
28
+ echo "Labelled skip-changelog: no entry needed."
29
+ fi
30
+
31
+ - uses: actions/checkout@v7
32
+ if: steps.labels.outputs.skip != 'true'
33
+ with:
34
+ fetch-depth: 0
35
+
36
+ - name: Install uv
37
+ if: steps.labels.outputs.skip != 'true'
38
+ uses: astral-sh/setup-uv@v7
39
+
40
+ - name: Check for an entry in changelog.d
41
+ if: steps.labels.outputs.skip != 'true'
42
+ run: |
43
+ uvx towncrier==26.9.0 check --compare-with "origin/${{ github.base_ref }}" || {
44
+ echo "Add a file to changelog.d/ for each change, or ask for the skip-changelog label:"
45
+ echo "https://jacopoabramo.github.io/sharedbox/how-to/commits-and-prs/#changelog-entries"
46
+ exit 1
47
+ }
@@ -19,7 +19,7 @@ jobs:
19
19
  # local hooks in prek.toml call `uv run --locked --only-group lint ...`
20
20
  - uses: astral-sh/setup-uv@v7
21
21
 
22
- - uses: j178/prek-action@4e14d07f9231acabce116ccfca13b13dd9755ece # v3.0.0
22
+ - uses: j178/prek-action@44924fe9ef4a6f88253c4b6b1bf11c689d3ce53d # v3.1.0
23
23
  with:
24
24
  prek-version: "0.5.3"
25
25
 
@@ -88,7 +88,7 @@ jobs:
88
88
  - name: Create a box larger than a 16 MiB /dev/shm
89
89
  if: runner.os == 'Linux' && matrix.build == 'Release'
90
90
  run: |
91
- docker run --rm --shm-size=16m -v "$PWD":/src -w /src ubuntu:24.04 build-cpp/test_small_shm
91
+ sudo unshare --mount sh -c 'mount -t tmpfs -o size=16m tmpfs /dev/shm && build-cpp/test_small_shm'
92
92
 
93
93
  build_wheels:
94
94
  name: Build wheel for ${{ matrix.python }}-${{ matrix.platform_id }}
@@ -114,11 +114,11 @@ jobs:
114
114
  ref: ${{ github.event_name == 'release' && github.event.release.tag_name || '' }}
115
115
 
116
116
  - name: Build wheels
117
- uses: pypa/cibuildwheel@v4.2.1
117
+ uses: pypa/cibuildwheel@v4.3.4
118
118
  env:
119
119
  CIBW_BUILD: ${{ matrix.python }}-${{ matrix.platform_id }}
120
120
  CIBW_CONTAINER_ENGINE: "docker; create_args: --shm-size=1g"
121
- CIBW_TEST_REQUIRES: pytest hypothesis numpy
121
+ CIBW_TEST_REQUIRES: pytest hypothesis numpy attrs
122
122
  CIBW_TEST_COMMAND: pytest {project}/tests
123
123
  with:
124
124
  package-dir: .
@@ -212,11 +212,11 @@ jobs:
212
212
  shell: bash
213
213
  run: |
214
214
  uv venv --python 3.12 .stress
215
- uv pip install --python .stress wheelhouse/*.whl pytest hypothesis
215
+ uv pip install --python .stress wheelhouse/*.whl pytest hypothesis numpy attrs
216
216
  python=.stress/bin/python
217
217
  [ -x "$python" ] || python=.stress/Scripts/python.exe
218
218
  "$python" -m pytest -m stress -q -p no:cacheprovider
219
- "$python" -m pytest tests/test_properties_codec.py tests/test_properties_layout.py tests/test_properties_forged.py tests/test_properties_stateful.py -q -p no:cacheprovider --hypothesis-profile=thorough
219
+ "$python" -m pytest tests/test_properties_*.py -q -p no:cacheprovider --hypothesis-profile=thorough
220
220
 
221
221
  - uses: actions/upload-artifact@v7
222
222
  if: always()
@@ -246,7 +246,15 @@ jobs:
246
246
  - uses: actions/checkout@v7
247
247
  with:
248
248
  fetch-depth: 0
249
- ref: ${{ github.event_name == 'release' && github.event.release.tag_name || '' }}
249
+ ref: ${{ github.event.release.tag_name }}
250
+
251
+ - name: Check the changelog has a section for a final release
252
+ env:
253
+ TAG: ${{ github.event.release.tag_name }}
254
+ run: |
255
+ if [[ "$TAG" =~ ^v[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
256
+ python3 scripts/release_notes.py extract "${TAG#v}" > /dev/null
257
+ fi
250
258
 
251
259
  - name: Build SDist
252
260
  run: pipx run build --sdist
@@ -280,3 +288,25 @@ jobs:
280
288
  merge-multiple: true
281
289
 
282
290
  - uses: pypa/gh-action-pypi-publish@release/v1
291
+
292
+ # final releases only: a release candidate's entries stay in changelog.d
293
+ # for the final release's section
294
+ github_release:
295
+ name: Write the GitHub release notes
296
+ needs: [upload_pypi]
297
+ if: github.event_name == 'release' && !github.event.release.prerelease
298
+ runs-on: ubuntu-latest
299
+ permissions:
300
+ contents: write
301
+ steps:
302
+ - uses: actions/checkout@v7
303
+ with:
304
+ ref: ${{ github.event.release.tag_name }}
305
+
306
+ - name: Write the release's notes from its changelog section
307
+ env:
308
+ GH_TOKEN: ${{ github.token }}
309
+ TAG: ${{ github.event.release.tag_name }}
310
+ run: |
311
+ python3 scripts/release_notes.py extract "${TAG#v}" > notes.md
312
+ gh release edit "$TAG" --title "$TAG" --notes-file notes.md
@@ -0,0 +1,108 @@
1
+ name: Ops
2
+
3
+ on:
4
+ pull_request:
5
+ branches: [ main ]
6
+ paths:
7
+ - include/sharedbox/**
8
+ - src/sharedbox/_native/**
9
+ - src/sharedbox/benchmarks/ops.py
10
+ - .github/workflows/ops.yaml
11
+ - CMakeLists.txt
12
+ workflow_dispatch:
13
+
14
+ permissions:
15
+ contents: read
16
+
17
+ jobs:
18
+ ops:
19
+ name: Reads and writes against the base branch on Windows
20
+ runs-on: windows-latest
21
+ timeout-minutes: 60
22
+ steps:
23
+ - uses: actions/checkout@v7
24
+ with:
25
+ path: head
26
+ fetch-depth: 0
27
+
28
+ - uses: actions/checkout@v7
29
+ with:
30
+ ref: ${{ github.base_ref || 'main' }}
31
+ path: base
32
+ fetch-depth: 0
33
+
34
+ - uses: astral-sh/setup-uv@v7
35
+
36
+ - name: Install both
37
+ shell: bash
38
+ run: |
39
+ for side in base head; do
40
+ (cd "$side" && uv sync --frozen --python 3.11)
41
+ done
42
+
43
+ - name: Run benchbox ops, alternating base and head
44
+ shell: bash
45
+ env:
46
+ # The 64k set and dict rows nearly double the job, so a pull request skips them.
47
+ SIZES: ${{ github.event_name == 'pull_request' && '[!6]*' || '*' }}
48
+ run: |
49
+ mkdir results
50
+ step=0
51
+ total=18 # 3 rounds x 2 sides x (int, record), plus list, set and dict once per side
52
+ for round in 1 2 3; do
53
+ for side in base head; do
54
+ for rows in int record list set dict; do
55
+ case "$rows" in list|set|dict) [ "$round" != 1 ] && continue ;; esac # not gated, one round is enough
56
+ step=$((step + 1))
57
+ echo "::group::[$step/$total] round $round, $side, $rows rows"
58
+ case "$rows" in
59
+ list) pattern="*list*/*" ;;
60
+ set) pattern="*set$SIZES/*" ;;
61
+ dict) pattern="*dict$SIZES/*" ;;
62
+ *) pattern="*$rows/SharedBox" ;;
63
+ esac
64
+ (cd "$side" && uv run --no-sync benchbox ops --fast \
65
+ --filter "$pattern" --json "../results/$side-$round-$rows.json")
66
+ echo "::endgroup::"
67
+ done
68
+ done
69
+ done
70
+
71
+ - name: Compare the medians
72
+ shell: bash
73
+ run: |
74
+ cd head
75
+ uv run --no-sync python - ../results <<'EOF' | tee -a "$GITHUB_STEP_SUMMARY"
76
+ import statistics
77
+ import sys
78
+ from pathlib import Path
79
+
80
+ import pyperf
81
+ from sharedbox.benchmarks._app import machine
82
+
83
+ means: dict[tuple[str, str], list[float]] = {}
84
+ for path in sorted(Path(sys.argv[1]).glob("*.json")):
85
+ side = path.name.split("-")[0]
86
+ for bench in pyperf.BenchmarkSuite.load(str(path)).get_benchmarks():
87
+ means.setdefault((bench.get_name(), side), []).append(bench.mean())
88
+ print("### benchbox ops on Windows cp311, median of three rounds, list, set and dict rows one round")
89
+ print()
90
+ print("A pull request skips the 64k set and dict rows; start the workflow by hand for them.")
91
+ print()
92
+ print(machine())
93
+ print()
94
+ print("| benchmark | base | head | head / base |")
95
+ print("| --- | --- | --- | --- |")
96
+ for name in sorted({name for name, _ in means}):
97
+ base = statistics.median(means.get((name, "base"), [0.0]))
98
+ head = statistics.median(means.get((name, "head"), [0.0]))
99
+ # A row added or removed by the pull request has times on one side only.
100
+ cells = [f"{v * 1e9:.1f} ns" if v else "-" for v in (base, head)]
101
+ ratio = f"{head / base:.3f}" if base and head else "-"
102
+ print(f"| {name} | {cells[0]} | {cells[1]} | {ratio} |")
103
+ EOF
104
+
105
+ - uses: actions/upload-artifact@v7
106
+ with:
107
+ name: ops
108
+ path: results
@@ -0,0 +1,78 @@
1
+ name: Prepare release
2
+
3
+ on:
4
+ workflow_dispatch:
5
+ inputs:
6
+ version:
7
+ description: "Version to release, such as 0.6.0, without the v"
8
+ required: true
9
+ type: string
10
+ dry_run:
11
+ description: "Only show the changelog section, in the run's summary"
12
+ required: false
13
+ type: boolean
14
+ default: false
15
+
16
+ permissions:
17
+ contents: write
18
+ pull-requests: write
19
+
20
+ jobs:
21
+ prepare:
22
+ name: Write the changelog section and open the release pull request
23
+ runs-on: ubuntu-latest
24
+ steps:
25
+ - name: Check the version
26
+ env:
27
+ VERSION: ${{ inputs.version }}
28
+ run: |
29
+ if [[ ! "$VERSION" =~ ^[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
30
+ echo "The version must look like 0.6.0, without the v; got '$VERSION'."
31
+ echo "Tag a release candidate instead of preparing it."
32
+ exit 1
33
+ fi
34
+
35
+ - uses: actions/checkout@v7
36
+ with:
37
+ ref: main
38
+
39
+ - name: Check there is something to release
40
+ env:
41
+ VERSION: ${{ inputs.version }}
42
+ run: |
43
+ # towncrier refuses a version only when the whole heading matches,
44
+ # date included, so on a later day it would write a second section
45
+ if python3 scripts/release_notes.py extract "$VERSION" > /dev/null 2>&1; then
46
+ echo "The changelog already has a section for $VERSION."
47
+ exit 1
48
+ fi
49
+ if [ -z "$(find changelog.d -type f ! -name .gitkeep)" ]; then
50
+ echo "changelog.d holds no entries, so there is nothing to release."
51
+ exit 1
52
+ fi
53
+
54
+ - name: Install uv
55
+ uses: astral-sh/setup-uv@v7
56
+
57
+ - name: Write the section
58
+ env:
59
+ VERSION: ${{ inputs.version }}
60
+ run: |
61
+ git config user.name "github-actions[bot]"
62
+ git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
63
+ uvx towncrier==26.9.0 build --yes --version "$VERSION" --date "$(date -u +%d-%m-%Y)"
64
+ python3 scripts/release_notes.py extract "$VERSION" > notes.md
65
+ cat notes.md >> "$GITHUB_STEP_SUMMARY"
66
+
67
+ - name: Open the release pull request
68
+ if: ${{ !inputs.dry_run }}
69
+ env:
70
+ VERSION: ${{ inputs.version }}
71
+ GH_TOKEN: ${{ github.token }}
72
+ run: |
73
+ branch="release/v$VERSION"
74
+ git switch -c "$branch"
75
+ git commit -m "docs: write the $VERSION changelog"
76
+ git push origin "$branch"
77
+ gh pr create --base main --head "$branch" --label skip-changelog \
78
+ --title "docs: write the $VERSION changelog" --body-file notes.md
@@ -0,0 +1,85 @@
1
+ name: Streams
2
+
3
+ on:
4
+ pull_request:
5
+ branches: [ main ]
6
+ paths:
7
+ - include/sharedbox/stream.hpp
8
+ - include/sharedbox/core.hpp
9
+ - src/sharedbox/_stream.py
10
+ - src/sharedbox/_native/stream.cpp
11
+ - src/sharedbox/_native/types.cpp
12
+ - src/sharedbox/_native/codec.cpp
13
+ - src/sharedbox/benchmarks/stream.py
14
+ - scripts/stream_compare.py
15
+ - .github/workflows/streams.yaml
16
+ workflow_dispatch:
17
+ inputs:
18
+ base:
19
+ description: Commit, branch or tag to compare against
20
+ required: false
21
+ default: main
22
+
23
+ permissions:
24
+ contents: read
25
+
26
+ jobs:
27
+ streams:
28
+ name: Streams against the base on ${{ matrix.os }}
29
+ runs-on: ${{ matrix.os }}
30
+ timeout-minutes: 60
31
+ strategy:
32
+ fail-fast: false
33
+ matrix:
34
+ os: [ ubuntu-latest, windows-latest ]
35
+ steps:
36
+ - uses: actions/checkout@v7
37
+ with:
38
+ path: head
39
+ fetch-depth: 0
40
+ - uses: actions/checkout@v7
41
+ with:
42
+ ref: ${{ inputs.base || github.base_ref || 'main' }}
43
+ path: base
44
+ fetch-depth: 0
45
+ - uses: astral-sh/setup-uv@v7
46
+ - name: Install both
47
+ shell: bash
48
+ run: |
49
+ for side in base head; do
50
+ (cd "$side" && uv sync --frozen --python 3.12)
51
+ done
52
+ - name: Check the base has SharedStream
53
+ id: base
54
+ shell: bash
55
+ run: |
56
+ if (cd base && uv run --no-sync python -c "import sharedbox; sharedbox.SharedStream"); then
57
+ echo "sides=base head" >> "$GITHUB_OUTPUT"
58
+ else
59
+ echo "sides=head" >> "$GITHUB_OUTPUT"
60
+ echo "base has no SharedStream; head only" | tee -a "$GITHUB_STEP_SUMMARY"
61
+ fi
62
+ - name: Run the stream benchmarks, alternating
63
+ shell: bash
64
+ run: |
65
+ mkdir results
66
+ for round in 1 2 3; do
67
+ if [ "${{ steps.base.outputs.sides }}" != "head" ]; then
68
+ (cd base && uv run --no-sync python ../head/src/sharedbox/benchmarks/stream.py \
69
+ --short --table both --json "../results/base-$round.json") \
70
+ || echo "::warning::base round $round failed"
71
+ fi
72
+ (cd head && uv run --no-sync python ../head/src/sharedbox/benchmarks/stream.py \
73
+ --short --table both --json "../results/head-$round.json")
74
+ done
75
+ - name: Compare
76
+ if: ${{ !cancelled() }}
77
+ shell: bash
78
+ run: |
79
+ cd head
80
+ uv run --no-sync python ../head/scripts/stream_compare.py ../results | tee -a "$GITHUB_STEP_SUMMARY"
81
+ - uses: actions/upload-artifact@v7
82
+ if: ${{ !cancelled() }}
83
+ with:
84
+ name: streams-${{ matrix.os }}
85
+ path: results
@@ -20,9 +20,10 @@ wheelhouse/
20
20
 
21
21
  graphify-out/
22
22
 
23
- build-cpp/
23
+ build-cpp*/
24
24
 
25
25
  .hypothesis/
26
+ .claude/settings.json
26
27
  .claude/settings.local.json
27
28
 
28
29
  site/