-
Notifications
You must be signed in to change notification settings - Fork 114
feat: support DataFrames via narwhals #1570
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 17 commits
Commits
Show all changes
97 commits
Select commit
Hold shift + click to select a range
bbe6261
feat: start rough draft of narwhals support
machow 12d39cf
Merge branch 'main' into feat-narwhals
schloerke 57fe20f
add narwhals to deps
schloerke 81058ea
lint
schloerke c86ec1e
Merge branch 'main' into machow-feat-narwhals
schloerke 869aa7a
Fix typing issues
schloerke 271ec5f
Rename fixtures
schloerke a5714e4
Partial for narwhals serialize frame. Still needs work. Need datetime…
schloerke f11769f
Merge branch 'main' into machow-feat-narwhals
schloerke db83bc7
add missing narwhals dep in config
schloerke 1155868
Merge branch 'main' into machow-feat-narwhals
schloerke be6985a
Merge branch 'main' into machow-feat-narwhals
schloerke 9318a5b
Disable timedelta dtype within pandas (as moving towards all narwhals…
schloerke 42d0353
Scaffold out more dtypes
schloerke 3e3c8c0
Use `orjson` instead of `json` package to serialize json. (Native dat…
schloerke ef2ee1c
Update tests, trying to support more dtypes (more to go). Disable non…
schloerke 824f6b4
Merge branch 'main' into feat-narwhals
schloerke 563bc52
Bump min version of narwhals to v1.8.0 for `nw.Series.scatter(rows, v…
schloerke 861329a
Expose narwhals types of `DataFrame`, `DataFrameT`, `IntoDataFrame`, …
schloerke 5172734
Add narwhals for types and integrate into _tbl_data.py
schloerke ce6cd35
Styles function will accept `IntoDataFrameT` type
schloerke 3fea35c
Be explicit on type of object being inspected
schloerke dc8179f
Disable all pandas specific functions for data frame
schloerke 002ba7e
DataGrid and DataTable can now accept `IntroDataFrameT`
schloerke 2eacaa5
Upgrade `render.data_frame` to handle `IntoDataFrameT`. Add `._nw_dat…
schloerke 32fe466
Update typing
schloerke 00088be
Update tests to handle the new types
schloerke cf6b283
Fix port test to be more robust
schloerke 9cf92d3
Add quick short circuit
schloerke cfb5ac7
Add TODO with hint from Marco
schloerke aa0d8dd
Fix html column bug
schloerke 8b88353
Fix narwhals subset bugs
schloerke cf5a845
Do not convert data early
schloerke 08e70ad
Update _data_frame.py
schloerke 3b4be82
Fix another html column issue
schloerke 1f8c9c6
lint
schloerke 6273885
Update tests for narwhals. Note: py-htmltools is holding up PR's test…
schloerke 815baa4
Merge branch 'main' into machow-feat-narwhals
schloerke d0282aa
Remove `SeriesLike` type
schloerke c9009e8
Tighten up code. Remove mention of singledispatch
schloerke e7d1fe8
Merge branch 'main' into machow-feat-narwhals
schloerke a0681b7
Use latest narwhals (1.8.3) and dev htmltools
schloerke d0772e4
Remove many TODOs
schloerke 77d6085
Update _html.py
schloerke d66e1de
Update docs
schloerke a950d7d
Test more narwhals types. Add comment for file.
schloerke baed7f9
Add more cell types to data frame js. Add test app for all types and …
schloerke 90276a3
Update app.py
schloerke 246819f
If the cell value is `null`, display `""` for table cell value
schloerke 0e57199
Test that `DataFrame.data()` returns the same type as render method
schloerke f4caa1f
Temporarily disable htmltools install
schloerke cb960c4
Install htmltools from `taglist_not_list` branch on GH
schloerke df72692
Add new narwhals types
schloerke 6e22352
Update app.py
schloerke 71ead9f
Update htmltools dep to include new TagList inheriting from UserList
schloerke f8d7c13
Add note about narwhals inspecting only the first sentence
schloerke 46a1203
Be sure to return the cell text
schloerke da98bd8
Rename internal method `cell_contains_htmltoolslike` to `ui_must_be_p…
schloerke 4fc66b3
Leverage htmltools's new HTML/UserString and TagList/UserList objects…
schloerke 98d40e1
Update app to use html within the first row to tell narwhals it's an …
schloerke 17c3b2a
Add `reactive_method()` and tests
schloerke f7c2e65
Utilize new `@reactive_calc_method` decorator in data frame class
schloerke 5a47cc8
Merge branch 'main' into machow-feat-narwhals
schloerke ee2f485
Update _reactive_method.py
schloerke f817510
Update date warning when non-narwhals compatible data is received
schloerke 8f68a4b
Update narwhals
schloerke 758fd86
Change equality subclass checks to isinstance checks
schloerke f5e2c6a
Update test_render_data_frame_tbl_data.py
schloerke 47b855c
Update test_render_data_frame_tbl_data.py
schloerke 1a9aa96
Update _data_frame.py
schloerke a9d3c67
Add another future impl for reactive_value_method
schloerke a25a3d1
Restore odd skip as it is still required
schloerke fddd87f
Drop testing of python 3.8 (minimal changes)
schloerke a992b2f
Revert "chore: revert check where airmass skips on python 3.9 (#1708)"
schloerke 12544b6
Update Makefile
schloerke 6f28b06
Revert htmltools install as it isn't needed anymore
schloerke 3f3b9be
Drop `is_into_data_frame`
schloerke bc99573
Code review
schloerke e0caacd
Remove unused `._type_hints`
schloerke 3791a3b
Update _data_frame.py
schloerke e2444d1
Collect all JS deps of a data frame sep from the content. For each ce…
schloerke 1eef355
Update test_render_data_frame_tbl_data.py
schloerke f5e9099
Try requiring py-htmltools directly. Do not install py-htmltools manu…
schloerke c397e82
Use htmltools github ref
schloerke 3ce71f9
Remove small and unused narwals wrapper methods
schloerke 1a6e917
Update Makefile
schloerke 6142df3
Store the reactive calc on self directly. This adds a two-way pointer…
schloerke 529f371
Move py-shinylive github install to pyproject
schloerke 1a26d7d
Revert "Move py-shinylive github install to pyproject"
schloerke b29e037
Perform the install in a single command
schloerke 1fcef38
Merge branch 'main' into feat-narwhals
schloerke 1f46fb3
Un-export `render.[DataFrame, DataFrameT, IntoDataFrame, IntoDataFram…
schloerke 6630f61
Add narwhals support for `@render.table`; Remove no longer necessary …
schloerke d1b53ff
Update CHANGELOG.md
schloerke 9f2a29d
Fix test
schloerke a1a9e54
Add changelog for `@render.table`
schloerke 6ee52a9
Set max version of narwhals to `<1.10.0`
schloerke File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.