Compare commits

..

33 Commits

Author SHA1 Message Date
Tyler Goodlet 4a6bac2fb1 Drop explicit `tabcompleter` dep, `pdpp` already sub-depends on it? 2025-03-24 21:44:59 -04:00
Tyler Goodlet 968140677b Bump up to `pytest>=8.3.5` to match "GH actions"
Ensure it's only for the `--dev` optional deps.
2025-03-24 21:44:59 -04:00
Tyler Goodlet 4abc0afbee Bump to `msgspec>=0.19.0` for py 3.13 support! 2025-03-24 21:44:59 -04:00
Tyler Goodlet 4d865b8846 Bind another `_bexc` for debuggin 2025-03-24 21:44:59 -04:00
Tyler Goodlet 38497fab6a Comment-tag pause points in `asycnio_bp.py`
Thought i already did this but, obvi needed these to make the expect
matches pass in our test.
2025-03-24 21:44:59 -04:00
Tyler Goodlet fd6d2506bd Unpack errors from `pdb.bdb`
Like any `bdb.BdbQuit` that might be relayed from a remote context after
a REPl exit with the `quit` cmd. This fixes various issues while
debugging where it may not be clear to the parent task that the child
was terminated with a purposefully unrecoverable error.
2025-03-24 21:44:59 -04:00
Tyler Goodlet 78028ca5f5 Show frames when decode is handed bad input 2025-03-24 21:44:59 -04:00
Tyler Goodlet 307e3cf593 Another loosie in the trioisms suite 2025-03-24 21:44:59 -04:00
Tyler Goodlet 68784a859a Match `maybe_open_crash_handler()` to non-maybe version
Such that it will deliver a `BoxedMaybeException` to the caller
regardless whether `pdb` is set, and proxy through all `**kwargs`.
2025-03-24 21:44:59 -04:00
Tyler Goodlet 42389f8693 Use `collapse_eg()` in broadcaster suite
Around the test embedded `trio.open_nursery()` calls as expected. Also
tidy up the various nursery var names.
2025-03-24 21:44:59 -04:00
Tyler Goodlet 539ae7d26d Draft some eg collapsing helpers
Inside a new `.trionics._beg` and exposed from the subpkg ns in
anticipation of the `strict_exception_groups=False` being removed by
`trio` in py 3.15.

Notes,
- mk an embedded single-exc "extractor" using a `BaseExceptionGroup.exceptions` length
  check, when 1 return the lone child.
- use the above in a new `@acm`, async bc it's most likely to be composed in an
  `async with` tuple-style sequence block, called `collapse_eg()` which
  acts a one line "absorber" for when the above mentioned flag is no
  logner supported by `trio.open_nursery()`.

All untested atm fwiw.. but soon to be used in our test suite(s) likely!
2025-03-24 21:44:59 -04:00
Tyler Goodlet 802774641f Fix docs tests with yet another loosie-goosie
So the KBI propagates up to the actor nursery scope and also avoid
running any `examples/multihost/` subdir scripts.
2025-03-24 21:44:59 -04:00
Tyler Goodlet 1a0e6314f2 Another couple loose-ifies for discovery and advanced fault suites 2025-03-24 21:44:59 -04:00
Tyler Goodlet e510d84293 Add (masked) meta-debug-fixture for determining if `debug_mode` is set in harness.. 2025-03-24 21:44:59 -04:00
Tyler Goodlet ea29a1c479 Various test tweaks related to 3.13 egs
Including changes like,
- loose eg flagging in various test emedded `trio.open_nursery()`s.
- changes to eg handling (like using `except*`).
- added `debug_mode` integration to tests that needed some REPLin
  in order to figure out appropriate updates.
2025-03-24 21:44:59 -04:00
Tyler Goodlet 0af83bd4d8 Go to loose egs in `Actor` root & service nurseries (for now..) 2025-03-24 21:44:59 -04:00
Tyler Goodlet 0696e7d9d0 Fix `roundtripped` ref error in `validate_payload_msg()` 2025-03-24 21:44:59 -04:00
Tyler Goodlet d6ed798922 Hide `open_nursery()` frame by def 2025-03-24 21:44:59 -04:00
Tyler Goodlet f63fb8d4cd Moar sclang log fmting tweaks 2025-03-24 21:44:59 -04:00
Tyler Goodlet 66bc38fcac Add equiv of `AsyncioCancelled` for aio side
Such that a `TrioCancelled` is raised in the aio task via
`.set_exception()` to explicitly indicate and allow that task to handle
a taskc request from the parent `trio.Task`.
2025-03-24 21:44:59 -04:00
Tyler Goodlet 030a9b5625 Expose `._state.debug_mode()` predicate at top level 2025-03-24 21:44:59 -04:00
Tyler Goodlet b6e4e581fc Another loose-egs flag in `test_child_manages_service_nursery` 2025-03-24 21:44:59 -04:00
Tyler Goodlet 67c68343a8 Handle egs on failed `request_root_stdio_lock()`
Namely when the subactor fails to lock the root, in which case we
try to be very verbose about how/what failed in logging as well
as ensure we cancel the employed IPC ctx.

Implement the outer `BaseException` handler to handle both styles,
- match on an eg (or the prior std cancel excs) only raising a lone
  sub-exc from for former.
- always `as _req_err:` and assign to a new func-global `req_err`
  to enable the above matching.

Other,
- raise `DebugStateError` on `status.subactor_uid != actor_uid`.
- fix a `_repl_fail_report` ref error due to making silly assumptions
  about the `_repl_fail_msg` global; now copy from global as default.
- various log-fmt and logic expression styling tweaks.
- ignore `trio.Cancelled` by default in `open_crash_handler()`.
2025-03-24 21:44:59 -04:00
Tyler Goodlet 3e37508585 A couple more loose-egs flag flips
Namely inside,
- `ActorNursery.open_portal()` which uses
  `.trionics.maybe_open_nursery()` and is now adjusted to
  pass-through `**kwargs` for at least this flag.
- inside the `.trionics.gather_contexts()`.
2025-03-24 21:44:59 -04:00
Tyler Goodlet 934f4531cf Disable tb colors in `._testing.mk_cmd()`
Unset the appropriate cpython osenv var such that our `pexpect` script
runs in the test suite can maintain original matching logic.
2025-03-24 21:44:59 -04:00
Tyler Goodlet 908ffc9e3e Log format tweaks for sclang reprs
A space here, a newline there..
2025-03-24 21:44:59 -04:00
Tyler Goodlet 0e76a2d88e Expose `hide_tb: bool` from `.open_nursery()`
Such that it gets passed through to `.open_root_actor()` in the
`implicit_runtime==True` case - useful for debugging cases where
`.devx._debug` APIs might be used to avoid REPL clobbering in subactors.
2025-03-24 21:44:59 -04:00
Tyler Goodlet de91ca7159 Flip to `strict_exception_groups=False` in core tns
Since it'll likely need a bit of detailing to get the test suite running
identically with strict egs (exception groups), i've opted to just flip
the switch on a few core nursery scopes for now until as such a time
i can focus enough to port the matching internals.. Xp
2025-03-24 21:44:59 -04:00
Tyler Goodlet 0bb9dfd8f8 Clean up some imports in `._clustering` 2025-03-24 21:44:59 -04:00
Tyler Goodlet 34ce5fda26 Drop `asyncio`-canc error from `._exceptions` 2025-03-24 21:44:59 -04:00
Tyler Goodlet 82544e5f4a Bump various (dev) deps and prefer sys python
Since it turns out there's a few gotchas moving to python 3.13,
- we need to pin to new(er) `trio` which now flips to strict exception
  groups (something to be handled in a follow up patch).
- since we're now using `uv` we should (at least for now) prefer the
  system `python` (over astral's distis) since they compile for
  `libedit` in terms of what the (new) `readline.backend: str` will read
  as; this will break our tab-completion and vi-mode settings in
  the `pdbp` REPL without a user configuring a `~/.editrc`
  appropriately.
- go back to using latest `pdbp` (not a local dev version) since it
  should work fine presuming the previous bullet is addressed.

Lock bumps,
- for now use latest `trio==0.29.0` (which i gotta feeling might have
  broken some existing attempts at strict-eg handling i've tried..)
- update to latest `xonsh`, `pdbp` and its dep `tabcompleter`

Other cleaning,
- put back in various deps "comments" from `poetry` content.
- drop the `xonsh-vox` and `xontrib-vox` dev deps; no `vox` support with
  `uv` rn anyway..
2025-03-24 21:44:59 -04:00
Tyler Goodlet b1018a13fe Continue supporting py3.11+
Apparently the only thing needing a guard was use of
`asyncio.Queue.shutdown()` and the paired `QueueShutDown` exception?

Cool.
2025-03-24 21:44:46 -04:00
Tyler Goodlet 90287b9875 Fix an `aio_err` ref bug 2025-03-24 21:44:09 -04:00
1 changed files with 0 additions and 2 deletions

View File

@ -324,7 +324,6 @@ dependencies = [
{ name = "colorlog" },
{ name = "msgspec" },
{ name = "pdbp" },
{ name = "tabcompleter" },
{ name = "tricycle" },
{ name = "trio" },
{ name = "wrapt" },
@ -346,7 +345,6 @@ requires-dist = [
{ name = "colorlog", specifier = ">=6.8.2,<7" },
{ name = "msgspec", specifier = ">=0.19.0" },
{ name = "pdbp", specifier = ">=1.6,<2" },
{ name = "tabcompleter", specifier = ">=1.4.0" },
{ name = "tricycle", specifier = ">=0.4.1,<0.5" },
{ name = "trio", specifier = ">0.27" },
{ name = "wrapt", specifier = ">=1.16.0,<2" },