perspective-python 3.7.4__tar.gz → 3.8.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 (97) hide show
  1. {perspective_python-3.7.4 → perspective_python-3.8.0}/Cargo.toml +3 -3
  2. {perspective_python-3.7.4 → perspective_python-3.8.0}/LICENSE_THIRDPARTY_cargo.yml +2 -2
  3. {perspective_python-3.7.4 → perspective_python-3.8.0}/PKG-INFO +1 -1
  4. {perspective_python-3.7.4 → perspective_python-3.8.0}/package.json +1 -1
  5. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/__init__.py +1 -1
  6. perspective_python-3.8.0/perspective/tests/table/test_column_paths.py +89 -0
  7. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/table/test_view.py +13 -11
  8. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/table/test_view_expression.py +1 -1
  9. {perspective_python-3.7.4/perspective_python-3.7.4.data → perspective_python-3.8.0/perspective_python-3.8.0.data}/data/share/jupyter/labextensions/@finos/perspective-jupyterlab/package.json +2 -2
  10. perspective_python-3.8.0/perspective_python-3.8.0.data/data/share/jupyter/labextensions/@finos/perspective-jupyterlab/static/253.e30b6884e47a9553ecfc.js +16 -0
  11. perspective_python-3.7.4/perspective_python-3.7.4.data/data/share/jupyter/labextensions/@finos/perspective-jupyterlab/static/remoteEntry.dde85a45c0ee7558f793.js → perspective_python-3.8.0/perspective_python-3.8.0.data/data/share/jupyter/labextensions/@finos/perspective-jupyterlab/static/remoteEntry.0c4df9cdbab87a425a95.js +1 -1
  12. {perspective_python-3.7.4 → perspective_python-3.8.0}/pyproject.toml +1 -1
  13. {perspective_python-3.7.4 → perspective_python-3.8.0}/src/client/client_async.rs +14 -9
  14. {perspective_python-3.7.4 → perspective_python-3.8.0}/src/client/client_sync.rs +7 -2
  15. {perspective_python-3.7.4 → perspective_python-3.8.0}/src/client/pandas.rs +1 -1
  16. {perspective_python-3.7.4 → perspective_python-3.8.0}/src/client/polars.rs +1 -4
  17. {perspective_python-3.7.4 → perspective_python-3.8.0}/src/server/server_sync.rs +29 -6
  18. {perspective_python-3.7.4 → perspective_python-3.8.0}/src/server/session_async.rs +0 -1
  19. {perspective_python-3.7.4 → perspective_python-3.8.0}/src/server/session_sync.rs +0 -2
  20. perspective_python-3.7.4/perspective_python-3.7.4.data/data/share/jupyter/labextensions/@finos/perspective-jupyterlab/static/253.43f556e31ec8de4307a2.js +0 -16
  21. {perspective_python-3.7.4 → perspective_python-3.8.0}/LICENSE.md +0 -0
  22. {perspective_python-3.7.4 → perspective_python-3.8.0}/README.md +0 -0
  23. {perspective_python-3.7.4 → perspective_python-3.8.0}/build.rs +0 -0
  24. {perspective_python-3.7.4 → perspective_python-3.8.0}/docs/index.html +0 -0
  25. {perspective_python-3.7.4 → perspective_python-3.8.0}/docs/lib.md +0 -0
  26. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/extension/finos-perspective-nbextension.json +0 -0
  27. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/handlers/__init__.py +0 -0
  28. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/handlers/aiohttp.py +0 -0
  29. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/handlers/starlette.py +0 -0
  30. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/handlers/tornado.py +0 -0
  31. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/templates/exported_widget.html.template +0 -0
  32. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/__init__.py +0 -0
  33. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/async/test_async_client.py +0 -0
  34. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/async/test_websocket_client.py +0 -0
  35. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/conftest.py +0 -0
  36. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/core/__init__.py +0 -0
  37. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/core/test_async.py +0 -0
  38. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/multi_threaded/__init__.py +0 -0
  39. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/multi_threaded/test_multi_threaded.py +0 -0
  40. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/server/__init__.py +0 -0
  41. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/server/test_server.py +0 -0
  42. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/server/test_session.py +0 -0
  43. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/table/__init__.py +0 -0
  44. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/table/arrow/date32.arrow +0 -0
  45. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/table/arrow/date64.arrow +0 -0
  46. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/table/arrow/dict.arrow +0 -0
  47. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/table/arrow/dict_update.arrow +0 -0
  48. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/table/arrow/int_float_str.arrow +0 -0
  49. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/table/arrow/int_float_str_file.arrow +0 -0
  50. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/table/arrow/int_float_str_update.arrow +0 -0
  51. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/table/object_sequence.py +0 -0
  52. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/table/test_delete.py +0 -0
  53. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/table/test_exception.py +0 -0
  54. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/table/test_leaks.py +0 -0
  55. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/table/test_ports.py +0 -0
  56. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/table/test_remove.py +0 -0
  57. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/table/test_table.py +0 -0
  58. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/table/test_table_arrow.py +0 -0
  59. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/table/test_table_datetime.py +0 -0
  60. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/table/test_table_infer.py +0 -0
  61. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/table/test_table_limit.py +0 -0
  62. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/table/test_table_numpy.py +0 -0
  63. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/table/test_table_pandas.py +0 -0
  64. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/table/test_table_polars.py +0 -0
  65. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/table/test_to_arrow.py +0 -0
  66. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/table/test_to_arrow_lz4.py +0 -0
  67. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/table/test_to_format.py +0 -0
  68. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/table/test_to_polars.py +0 -0
  69. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/table/test_update.py +0 -0
  70. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/table/test_update_arrow.py +0 -0
  71. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/table/test_update_pandas.py +0 -0
  72. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/test_dependencies.py +0 -0
  73. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/viewer/__init__.py +0 -0
  74. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/viewer/test_viewer.py +0 -0
  75. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/widget/__init__.py +0 -0
  76. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/widget/test_widget.py +0 -0
  77. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/tests/widget/test_widget_pandas.py +0 -0
  78. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/widget/__init__.py +0 -0
  79. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/widget/viewer/__init__.py +0 -0
  80. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/widget/viewer/validate.py +0 -0
  81. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/widget/viewer/viewer.py +0 -0
  82. {perspective_python-3.7.4 → perspective_python-3.8.0}/perspective/widget/viewer/viewer_traitlets.py +0 -0
  83. {perspective_python-3.7.4/perspective_python-3.7.4.data → perspective_python-3.8.0/perspective_python-3.8.0.data}/data/share/jupyter/labextensions/@finos/perspective-jupyterlab/install.json +0 -0
  84. /perspective_python-3.7.4/perspective_python-3.7.4.data/data/share/jupyter/labextensions/@finos/perspective-jupyterlab/static/253.43f556e31ec8de4307a2.js.LICENSE.txt → /perspective_python-3.8.0/perspective_python-3.8.0.data/data/share/jupyter/labextensions/@finos/perspective-jupyterlab/static/253.e30b6884e47a9553ecfc.js.LICENSE.txt +0 -0
  85. {perspective_python-3.7.4/perspective_python-3.7.4.data → perspective_python-3.8.0/perspective_python-3.8.0.data}/data/share/jupyter/labextensions/@finos/perspective-jupyterlab/static/815.de1b4b53d57212354a6c.js +0 -0
  86. {perspective_python-3.7.4/perspective_python-3.7.4.data → perspective_python-3.8.0/perspective_python-3.8.0.data}/data/share/jupyter/labextensions/@finos/perspective-jupyterlab/static/style.js +0 -0
  87. {perspective_python-3.7.4/perspective_python-3.7.4.data → perspective_python-3.8.0/perspective_python-3.8.0.data}/data/share/jupyter/labextensions/@finos/perspective-jupyterlab/static/third-party-licenses.json +0 -0
  88. {perspective_python-3.7.4 → perspective_python-3.8.0}/src/client/mod.rs +0 -0
  89. {perspective_python-3.7.4 → perspective_python-3.8.0}/src/client/proxy_session.rs +0 -0
  90. {perspective_python-3.7.4 → perspective_python-3.8.0}/src/client/pyarrow.rs +0 -0
  91. {perspective_python-3.7.4 → perspective_python-3.8.0}/src/client/table_data.rs +0 -0
  92. {perspective_python-3.7.4 → perspective_python-3.8.0}/src/client/update_data.rs +0 -0
  93. {perspective_python-3.7.4 → perspective_python-3.8.0}/src/lib.rs +0 -0
  94. {perspective_python-3.7.4 → perspective_python-3.8.0}/src/py_async.rs +0 -0
  95. {perspective_python-3.7.4 → perspective_python-3.8.0}/src/py_err.rs +0 -0
  96. {perspective_python-3.7.4 → perspective_python-3.8.0}/src/server/mod.rs +0 -0
  97. {perspective_python-3.7.4 → perspective_python-3.8.0}/src/server/server_async.rs +0 -0
@@ -12,7 +12,7 @@
12
12
 
13
13
  [package]
14
14
  name = "perspective-python"
15
- version = "3.7.4"
15
+ version = "3.8.0"
16
16
  edition = "2024"
17
17
  description = "A data visualization and analytics component, especially well-suited for large and/or streaming datasets."
18
18
  repository = "https://github.com/finos/perspective"
@@ -57,8 +57,8 @@ pyo3-build-config = "0.22.6"
57
57
  python-config-rs = "0.1.2"
58
58
 
59
59
  [dependencies]
60
- perspective-client = { version = "3.7.4" }
61
- perspective-server = { version = "3.7.4" }
60
+ perspective-client = { version = "3.8.0" }
61
+ perspective-server = { version = "3.8.0" }
62
62
  macro_rules_attribute = "0.2.0"
63
63
  async-lock = "2.5.0"
64
64
  pollster = "0.3.0"
@@ -2911,14 +2911,14 @@ third_party_libraries:
2911
2911
 
2912
2912
  END OF TERMS AND CONDITIONS
2913
2913
  - package_name: perspective-client
2914
- package_version: 3.7.4
2914
+ package_version: 3.8.0
2915
2915
  repository: https://github.com/finos/perspective
2916
2916
  license: Apache-2.0
2917
2917
  licenses:
2918
2918
  - license: Apache-2.0
2919
2919
  text: "# Apache License\n\n_Version 2.0, January 2004_ \n_&lt;<http://www.apache.org/licenses/>&gt;_\n\n### Terms and Conditions for use, reproduction, and distribution\n\n#### 1. Definitions\n\n“License” shall mean the terms and conditions for use, reproduction, and\ndistribution as defined by Sections 1 through 9 of this document.\n\n“Licensor” shall mean the copyright owner or entity authorized by the copyright\nowner that is granting the License.\n\n“Legal Entity” shall mean the union of the acting entity and all other entities\nthat control, are controlled by, or are under common control with that entity.\nFor the purposes of this definition, “control” means **(i)** the power, direct or\nindirect, to cause the direction or management of such entity, whether by\ncontract or otherwise, or **(ii)** ownership of fifty percent (50%) or more of the\noutstanding shares, or **(iii)** beneficial ownership of such entity.\n\n“You” (or “Your”) shall mean an individual or Legal Entity exercising\npermissions granted by this License.\n\n“Source” form shall mean the preferred form for making modifications, including\nbut not limited to software source code, documentation source, and configuration\nfiles.\n\n“Object” form shall mean any form resulting from mechanical transformation or\ntranslation of a Source form, including but not limited to compiled object code,\ngenerated documentation, and conversions to other media types.\n\n“Work” shall mean the work of authorship, whether in Source or Object form, made\navailable under the License, as indicated by a copyright notice that is included\nin or attached to the work (an example is provided in the Appendix below).\n\n“Derivative Works” shall mean any work, whether in Source or Object form, that\nis based on (or derived from) the Work and for which the editorial revisions,\nannotations, elaborations, or other modifications represent, as a whole, an\noriginal work of authorship. For the purposes of this License, Derivative Works\nshall not include works that remain separable from, or merely link (or bind by\nname) to the interfaces of, the Work and Derivative Works thereof.\n\n“Contribution” shall mean any work of authorship, including the original version\nof the Work and any modifications or additions to that Work or Derivative Works\nthereof, that is intentionally submitted to Licensor for inclusion in the Work\nby the copyright owner or by an individual or Legal Entity authorized to submit\non behalf of the copyright owner. For the purposes of this definition,\n“submitted” means any form of electronic, verbal, or written communication sent\nto the Licensor or its representatives, including but not limited to\ncommunication on electronic mailing lists, source code control systems, and\nissue tracking systems that are managed by, or on behalf of, the Licensor for\nthe purpose of discussing and improving the Work, but excluding communication\nthat is conspicuously marked or otherwise designated in writing by the copyright\nowner as “Not a Contribution.”\n\n“Contributor” shall mean Licensor and any individual or Legal Entity on behalf\nof whom a Contribution has been received by Licensor and subsequently\nincorporated within the Work.\n\n#### 2. Grant of Copyright License\n\nSubject to the terms and conditions of this License, each Contributor hereby\ngrants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free,\nirrevocable copyright license to reproduce, prepare Derivative Works of,\npublicly display, publicly perform, sublicense, and distribute the Work and such\nDerivative Works in Source or Object form.\n\n#### 3. Grant of Patent License\n\nSubject to the terms and conditions of this License, each Contributor hereby\ngrants to You a perpetual, worldwide, non-exclusive, no-charge, royalty-free,\nirrevocable (except as stated in this section) patent license to make, have\nmade, use, offer to sell, sell, import, and otherwise transfer the Work, where\nsuch license applies only to those patent claims licensable by such Contributor\nthat are necessarily infringed by their Contribution(s) alone or by combination\nof their Contribution(s) with the Work to which such Contribution(s) was\nsubmitted. If You institute patent litigation against any entity (including a\ncross-claim or counterclaim in a lawsuit) alleging that the Work or a\nContribution incorporated within the Work constitutes direct or contributory\npatent infringement, then any patent licenses granted to You under this License\nfor that Work shall terminate as of the date such litigation is filed.\n\n#### 4. Redistribution\n\nYou may reproduce and distribute copies of the Work or Derivative Works thereof\nin any medium, with or without modifications, and in Source or Object form,\nprovided that You meet the following conditions:\n\n- **(a)** You must give any other recipients of the Work or Derivative Works a copy of\n this License; and\n- **(b)** You must cause any modified files to carry prominent notices stating that You\n changed the files; and\n- **(c)** You must retain, in the Source form of any Derivative Works that You distribute,\n all copyright, patent, trademark, and attribution notices from the Source form\n of the Work, excluding those notices that do not pertain to any part of the\n Derivative Works; and\n- **(d)** If the Work includes a “NOTICE” text file as part of its distribution, then any\n Derivative Works that You distribute must include a readable copy of the\n attribution notices contained within such NOTICE file, excluding those notices\n that do not pertain to any part of the Derivative Works, in at least one of the\n following places: within a NOTICE text file distributed as part of the\n Derivative Works; within the Source form or documentation, if provided along\n with the Derivative Works; or, within a display generated by the Derivative\n Works, if and wherever such third-party notices normally appear. The contents of\n the NOTICE file are for informational purposes only and do not modify the\n License. You may add Your own attribution notices within Derivative Works that\n You distribute, alongside or as an addendum to the NOTICE text from the Work,\n provided that such additional attribution notices cannot be construed as\n modifying the License.\n\nYou may add Your own copyright statement to Your modifications and may provide\nadditional or different license terms and conditions for use, reproduction, or\ndistribution of Your modifications, or for any such Derivative Works as a whole,\nprovided Your use, reproduction, and distribution of the Work otherwise complies\nwith the conditions stated in this License.\n\n#### 5. Submission of Contributions\n\nUnless You explicitly state otherwise, any Contribution intentionally submitted\nfor inclusion in the Work by You to the Licensor shall be under the terms and\nconditions of this License, without any additional terms or conditions.\nNotwithstanding the above, nothing herein shall supersede or modify the terms of\nany separate license agreement you may have executed with Licensor regarding\nsuch Contributions.\n\n#### 6. Trademarks\n\nThis License does not grant permission to use the trade names, trademarks,\nservice marks, or product names of the Licensor, except as required for\nreasonable and customary use in describing the origin of the Work and\nreproducing the content of the NOTICE file.\n\n#### 7. Disclaimer of Warranty\n\nUnless required by applicable law or agreed to in writing, Licensor provides the\nWork (and each Contributor provides its Contributions) on an “AS IS” BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied,\nincluding, without limitation, any warranties or conditions of TITLE,\nNON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are\nsolely responsible for determining the appropriateness of using or\nredistributing the Work and assume any risks associated with Your exercise of\npermissions under this License.\n\n#### 8. Limitation of Liability\n\nIn no event and under no legal theory, whether in tort (including negligence),\ncontract, or otherwise, unless required by applicable law (such as deliberate\nand grossly negligent acts) or agreed to in writing, shall any Contributor be\nliable to You for damages, including any direct, indirect, special, incidental,\nor consequential damages of any character arising as a result of this License or\nout of the use or inability to use the Work (including but not limited to\ndamages for loss of goodwill, work stoppage, computer failure or malfunction, or\nany and all other commercial damages or losses), even if such Contributor has\nbeen advised of the possibility of such damages.\n\n#### 9. Accepting Warranty or Additional Liability\n\nWhile redistributing the Work or Derivative Works thereof, You may choose to\noffer, and charge a fee for, acceptance of support, warranty, indemnity, or\nother liability obligations and/or rights consistent with this License. However,\nin accepting such obligations, You may act only on Your own behalf and on Your\nsole responsibility, not on behalf of any other Contributor, and only if You\nagree to indemnify, defend, and hold each Contributor harmless for any liability\nincurred by, or claims asserted against, such Contributor by reason of your\naccepting any such warranty or additional liability.\n\n_END OF TERMS AND CONDITIONS_\n\n### APPENDIX: How to apply the Apache License to your work\n\nTo apply the Apache License to your work, attach the following boilerplate\nnotice, with the fields enclosed by brackets `[]` replaced with your own\nidentifying information. (Don't include the brackets!) The text should be\nenclosed in the appropriate comment syntax for the file format. We also\nrecommend that a file or class name and description of purpose be included on\nthe same “printed page” as the copyright notice for easier identification within\nthird-party archives.\n\n Copyright 2019 The Perspective Authors\n\n Licensed under the Apache License, Version 2.0 (the \"License\");\n you may not use this file except in compliance with the License.\n You may obtain a copy of the License at\n\n http://www.apache.org/licenses/LICENSE-2.0\n\n Unless required by applicable law or agreed to in writing, software\n distributed under the License is distributed on an \"AS IS\" BASIS,\n WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n See the License for the specific language governing permissions and\n limitations under the License.\n"
2920
2920
  - package_name: perspective-server
2921
- package_version: 3.7.4
2921
+ package_version: 3.8.0
2922
2922
  repository: https://github.com/finos/perspective
2923
2923
  license: Apache-2.0
2924
2924
  licenses:
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: perspective-python
3
- Version: 3.7.4
3
+ Version: 3.8.0
4
4
  Classifier: Development Status :: 5 - Production/Stable
5
5
  Classifier: Programming Language :: Rust
6
6
  Classifier: Programming Language :: Python :: Implementation :: CPython
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@finos/perspective-python",
3
- "version": "3.7.4",
3
+ "version": "3.8.0",
4
4
  "description": "",
5
5
  "private": true,
6
6
  "repository": {
@@ -10,7 +10,7 @@
10
10
  # ┃ of the [Apache License 2.0](https://www.apache.org/licenses/LICENSE-2.0). ┃
11
11
  # ┗━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┛
12
12
 
13
- __version__ = "3.7.4"
13
+ __version__ = "3.8.0"
14
14
  __all__ = [
15
15
  "_jupyter_labextension_paths",
16
16
  "Server",
@@ -0,0 +1,89 @@
1
+ # ┏━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
2
+ # ┃ ██████ ██████ ██████ █ █ █ █ █ █▄ ▀███ █ ┃
3
+ # ┃ ▄▄▄▄▄█ █▄▄▄▄▄ ▄▄▄▄▄█ ▀▀▀▀▀█▀▀▀▀▀ █ ▀▀▀▀▀█ ████████▌▐███ ███▄ ▀█ █ ▀▀▀▀▀ ┃
4
+ # ┃ █▀▀▀▀▀ █▀▀▀▀▀ █▀██▀▀ ▄▄▄▄▄ █ ▄▄▄▄▄█ ▄▄▄▄▄█ ████████▌▐███ █████▄ █ ▄▄▄▄▄ ┃
5
+ # ┃ █ ██████ █ ▀█▄ █ ██████ █ ███▌▐███ ███████▄ █ ┃
6
+ # ┣━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┫
7
+ # ┃ Copyright (c) 2017, the Perspective Authors. ┃
8
+ # ┃ ╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌ ┃
9
+ # ┃ This file is part of the Perspective library, distributed under the terms ┃
10
+ # ┃ of the [Apache License 2.0](https://www.apache.org/licenses/LICENSE-2.0). ┃
11
+ # ┗━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┛
12
+
13
+ import perspective as psp
14
+
15
+ client = psp.Server().new_local_client()
16
+
17
+
18
+ class TestViewColumnPaths(object):
19
+ def test_column_paths(self, superstore):
20
+ tbl = client.table(superstore)
21
+ view = tbl.view()
22
+ paths = view.column_paths()
23
+ assert paths == [
24
+ "index",
25
+ "Row ID",
26
+ "Order ID",
27
+ "Order Date",
28
+ "Ship Date",
29
+ "Ship Mode",
30
+ "Customer ID",
31
+ "Segment",
32
+ "Country",
33
+ "City",
34
+ "State",
35
+ "Postal Code",
36
+ "Region",
37
+ "Product ID",
38
+ "Category",
39
+ "Sub-Category",
40
+ "Sales",
41
+ "Quantity",
42
+ "Discount",
43
+ "Profit",
44
+ ]
45
+
46
+ view.delete()
47
+ tbl.delete()
48
+
49
+ def test_column_paths_split_by(self, superstore):
50
+ tbl = client.table(superstore)
51
+ view = tbl.view(group_by=["State"], columns=["Sales"], split_by=["Ship Mode"])
52
+ paths = view.column_paths()
53
+ assert paths == [
54
+ "First Class|Sales",
55
+ "Second Class|Sales",
56
+ "Standard Class|Sales",
57
+ ]
58
+
59
+ view.delete()
60
+ tbl.delete()
61
+
62
+ def test_column_paths_split_by_range(self, superstore):
63
+ tbl = client.table(superstore)
64
+ view = tbl.view(group_by=["State"], columns=["Sales"], split_by=["Ship Mode"])
65
+ paths = view.column_paths(start_col=1)
66
+ assert paths == [
67
+ "Second Class|Sales",
68
+ "Standard Class|Sales",
69
+ ]
70
+
71
+ view.delete()
72
+ view = tbl.view(group_by=["State"], columns=["Sales"], split_by=["Ship Mode"])
73
+ paths = view.column_paths(start_col=1, end_col=2)
74
+ assert paths == [
75
+ "Second Class|Sales",
76
+ "Standard Class|Sales",
77
+ ]
78
+
79
+ view.delete()
80
+ tbl = client.table(superstore)
81
+ view = tbl.view(group_by=["State"], columns=["Sales"], split_by=["Ship Mode"])
82
+ paths = view.column_paths(end_col=1)
83
+ assert paths == [
84
+ "First Class|Sales",
85
+ "Second Class|Sales",
86
+ ]
87
+
88
+ view.delete()
89
+ tbl.delete()
@@ -119,14 +119,14 @@ class TestView(object):
119
119
  tbl = Table(data)
120
120
  view = tbl.view(group_by=["a"])
121
121
  paths = view.column_paths()
122
- assert paths == ["__ROW_PATH__", "a", "b"]
122
+ assert paths == ["a", "b"]
123
123
 
124
124
  def test_view_column_path_one_numeric_names(self):
125
125
  data = {"a": [1, 2, 3], "b": [1.5, 2.5, 3.5], "1234": [5, 6, 7]}
126
126
  tbl = Table(data)
127
127
  view = tbl.view(group_by=["a"], columns=["b", "1234", "a"])
128
128
  paths = view.column_paths()
129
- assert paths == ["__ROW_PATH__", "b", "1234", "a"]
129
+ assert paths == ["b", "1234", "a"]
130
130
 
131
131
  def test_view_column_path_two(self):
132
132
  data = {"a": [1, 2, 3], "b": [1.5, 2.5, 3.5]}
@@ -134,7 +134,6 @@ class TestView(object):
134
134
  view = tbl.view(group_by=["a"], split_by=["b"])
135
135
  paths = view.column_paths()
136
136
  assert paths == [
137
- "__ROW_PATH__",
138
137
  "1.5|a",
139
138
  "1.5|b",
140
139
  "2.5|a",
@@ -245,7 +244,7 @@ class TestView(object):
245
244
  )
246
245
  )
247
246
  view = table.view(columns=["-0.1", "-0.05", "0.0", "0.1"], group_by=["str"])
248
- assert view.column_paths() == ["__ROW_PATH__", "-0.1", "-0.05", "0.0", "0.1"]
247
+ assert view.column_paths() == ["-0.1", "-0.05", "0.0", "0.1"]
249
248
 
250
249
  def test_view_aggregate_order_with_columns(self):
251
250
  """If `columns` is provided, order is always guaranteed."""
@@ -257,7 +256,7 @@ class TestView(object):
257
256
  aggregates={"d": "avg", "c": "avg", "b": "last", "a": "last"},
258
257
  )
259
258
 
260
- order = ["__ROW_PATH__", "a", "b", "c", "d"]
259
+ order = ["a", "b", "c", "d"]
261
260
  assert view.column_paths() == order
262
261
 
263
262
  def test_view_df_aggregate_order_with_columns(self):
@@ -272,7 +271,7 @@ class TestView(object):
272
271
  aggregates={"d": "avg", "c": "avg", "b": "last", "a": "last"},
273
272
  )
274
273
 
275
- order = ["__ROW_PATH__", "index", "d", "a", "c", "b"]
274
+ order = ["index", "d", "a", "c", "b"]
276
275
  assert view.column_paths() == order
277
276
 
278
277
  def test_view_aggregates_with_no_columns(self):
@@ -281,7 +280,7 @@ class TestView(object):
281
280
  view = tbl.view(
282
281
  group_by=["a"], aggregates={"c": "avg", "a": "last"}, columns=[]
283
282
  )
284
- assert view.column_paths() == ["__ROW_PATH__"]
283
+ assert view.column_paths() == []
285
284
  assert view.to_records() == [
286
285
  {"__ROW_PATH__": []},
287
286
  {"__ROW_PATH__": [1]},
@@ -297,8 +296,7 @@ class TestView(object):
297
296
  cols = tbl.columns()
298
297
  view = tbl.view(group_by=["a"], aggregates={"c": "avg", "a": "last"})
299
298
 
300
- order = ["__ROW_PATH__"] + cols
301
- assert view.column_paths() == order
299
+ assert view.column_paths() == cols
302
300
 
303
301
  # check that default aggregates have been applied
304
302
  result = view.to_columns()
@@ -448,7 +446,9 @@ class TestView(object):
448
446
  ]
449
447
  tbl = Table(data)
450
448
  view = tbl.view(
451
- aggregates={"y": ["weighted mean", "x"]}, group_by=["a"], columns=["y"]
449
+ aggregates={"y": ("weighted mean", ["x"])},
450
+ group_by=["a"],
451
+ columns=["y"],
452
452
  )
453
453
  assert view.to_records() == [
454
454
  {"__ROW_PATH__": [], "y": (1.0 * 200 + 2 * 100) / (1.0 + 2)},
@@ -463,7 +463,9 @@ class TestView(object):
463
463
  ]
464
464
  tbl = Table(data)
465
465
  view = tbl.view(
466
- aggregates={"y": ["weighted mean", "x"]}, group_by=["a"], columns=["y"]
466
+ aggregates={"y": ("weighted mean", ["x"])},
467
+ group_by=["a"],
468
+ columns=["y"],
467
469
  )
468
470
  assert view.to_records() == [
469
471
  {"__ROW_PATH__": [], "y": (1 * 200 + (-2) * 100) / (1 - 2)},
@@ -585,7 +585,7 @@ class TestViewExpression(object):
585
585
  table = Table({"a": [1, 2, 3, 4], "b": [5, 6, 7, 8]})
586
586
  view = table.view(
587
587
  group_by=["computed"],
588
- aggregates={"computed": ["weighted mean", "b"]},
588
+ aggregates={"computed": ("weighted mean", ["b"])},
589
589
  expressions={"computed": ' "a" + "b"'},
590
590
  )
591
591
  view2 = table.view(
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@finos/perspective-jupyterlab",
3
- "version": "3.7.4",
3
+ "version": "3.8.0",
4
4
  "description": "A Jupyterlab extension for the Perspective library, designed to be used with perspective-python.",
5
5
  "files": [
6
6
  "dist/**/*",
@@ -73,7 +73,7 @@
73
73
  }
74
74
  },
75
75
  "_build": {
76
- "load": "static/remoteEntry.dde85a45c0ee7558f793.js",
76
+ "load": "static/remoteEntry.0c4df9cdbab87a425a95.js",
77
77
  "extension": "./extension",
78
78
  "style": "./style"
79
79
  }