oremanj / greenback

Reenter an asyncio or Trio event loop from synchronous code
https://greenback.readthedocs.io/
Other
77 stars 2 forks source link

Add greenback.bestow_portal() #1

Closed oremanj closed 4 years ago

oremanj commented 4 years ago

For use in debuggers and such where you need to make a task greenback-able without running code within it.

Also update to support trio.lowlevel as the new name for trio.hazmat. (greenback still works on older Trio versions that use hazmat.)

codecov[bot] commented 4 years ago

Codecov Report

Merging #1 into master will increase coverage by 0.02%. The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master       #1      +/-   ##
==========================================
+ Coverage   99.39%   99.42%   +0.02%     
==========================================
  Files           7        7              
  Lines         499      522      +23     
  Branches       37       37              
==========================================
+ Hits          496      519      +23     
  Misses          2        2              
  Partials        1        1              
Flag Coverage Δ
#cpython 98.65% <100.00%> (+0.06%) :arrow_up:
#pypy36nightly 93.57% <100.00%> (-0.11%) :arrow_down:
#pypy36release 93.57% <100.00%> (-0.11%) :arrow_down:
Impacted Files Coverage Δ
greenback/__init__.py 100.00% <100.00%> (ø)
greenback/_impl.py 97.69% <100.00%> (-0.02%) :arrow_down:
greenback/_tests/test_impl.py 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 757199e...88c318f. Read the comment docs.