[python] Add new SOMAContext class and deprecate SOMATileDBContext#4363
[python] Add new SOMAContext class and deprecate SOMATileDBContext#4363
Conversation
c9c81de to
dce9aa0
Compare
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #4363 +/- ##
==========================================
+ Coverage 86.13% 88.88% +2.74%
==========================================
Files 140 63 -77
Lines 21141 7304 -13837
Branches 17 0 -17
==========================================
- Hits 18210 6492 -11718
+ Misses 2931 812 -2119
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
dce9aa0 to
e804607
Compare
aaronwolen
left a comment
There was a problem hiding this comment.
I performed a fairly shallow review and found a couple minor issues that I thought I'd report now. As requested, I'll review the new api more thoroughly next.
Co-authored-by: Aaron Wolen <[email protected]>
2a17083 to
5302c2a
Compare
aaronwolen
left a comment
There was a problem hiding this comment.
Looks great.
I suggested a fix for one minor formatting issues and had an implementation question, otherwise it's good to go.
| self._lock = threading.Lock() | ||
| """A lock to ensure single initialization of ``_tiledb_ctx``.""" | ||
|
|
||
| self.threadpool = threadpool or ThreadPoolExecutor() |
There was a problem hiding this comment.
Would this allow users to modify the threadpool of a context object?
There was a problem hiding this comment.
Because it's public? Technically, yes, but I doubt anyone would do that. I copied this from the SOMATileDBContext, and I assume the thinking is to make using the threadpool public.
Co-authored-by: Aaron Wolen <[email protected]>
Issue and/or context: Closes SOMA-789
Changes:
Create a new
SOMAContextthat is more closely aligned with the R and libtiledbsomaSOMAContextobjects.