jupyter-duckdb 1.2.101__py3-none-any.whl → 1.2.103__py3-none-any.whl

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.
@@ -0,0 +1,3 @@
1
+ .duckdb-query-result:not(.default) {
2
+ display: none
3
+ }
@@ -0,0 +1,55 @@
1
+ function animate_ra(divId, rootNodeId) {
2
+ /*
3
+ const {createApp, onMounted, ref} = Vue
4
+
5
+ createApp({
6
+ setup() {
7
+ onMounted(() => {
8
+ const titles = document.querySelectorAll(`#${divId} title`)
9
+ const gs = [...titles]
10
+ .map(t => [t.textContent, t.parentElement])
11
+ .filter(g => g[1].id && g[1].id.startsWith('node'))
12
+
13
+ console.log(gs)
14
+ })
15
+ }
16
+ }).mount(`#${divId}`)
17
+ */
18
+
19
+ const titles = [...document.querySelectorAll(`#${divId} title`)]
20
+ .filter(p => p.parentElement.id && p.parentElement.id.startsWith('node'))
21
+
22
+ // update cursor
23
+ titles.forEach(t => t.parentElement.style.cursor = 'pointer')
24
+ titles.forEach(t => t.parentElement.style.userSelect = 'none')
25
+
26
+ // update all polygons to handle click events
27
+ titles.forEach(t => {
28
+ t.parentElement.querySelectorAll('polygon')
29
+ .forEach(p => p.style.pointerEvents = 'all')
30
+ })
31
+
32
+ // add click listener for each node
33
+ titles.forEach(t => {
34
+ t.parentElement.addEventListener('click', () => {
35
+ titles.forEach(a => {
36
+ document.querySelectorAll(`.${a.textContent}`)
37
+ .forEach(e => e.style.display = a === t ? 'block' : 'none')
38
+ a.parentElement.querySelectorAll('polygon')
39
+ .forEach(e => e.setAttribute('fill', a === t ? 'rgb(200, 240, 255)' : 'none'))
40
+ })
41
+ })
42
+ })
43
+
44
+ // call listener for root node
45
+ window.setTimeout(() => {
46
+ titles.forEach(t => {
47
+ if (t.textContent === rootNodeId)
48
+ t.dispatchEvent(new MouseEvent('click', {
49
+ bubbles: true,
50
+ cancelable: true,
51
+ view: window
52
+ }))
53
+ })
54
+ }, 100)
55
+ }
@@ -1,6 +1,6 @@
1
- Metadata-Version: 2.2
1
+ Metadata-Version: 2.4
2
2
  Name: jupyter-duckdb
3
- Version: 1.2.101
3
+ Version: 1.2.103
4
4
  Summary: a basic wrapper kernel for DuckDB
5
5
  Home-page: https://github.com/erictroebs/jupyter-duckdb
6
6
  Author: Eric Tröbs
@@ -118,23 +118,24 @@ another DuckDB file or a file with SQL statements. In the first case the
118
118
  included tables will be copied to the new database, while in the second case the
119
119
  SQL statements are just executed. We find this feature very useful to work in a
120
120
  temporary copy of the data and therefore be able to restart at any time. The
121
- last optional parameter `WITH_TESTS` is described in
122
- detail [below](#ship-tests-with-your-notebooks).
121
+ optional parameter `NAME` may be used to name a connection and reference it
122
+ later by using the magic command `USE`.
123
123
 
124
124
  ```
125
125
  %CREATE data.duckdb OF my_statements.sql
126
126
  ```
127
127
 
128
128
  `LOAD` on the other hand loads an existing database and returns an error if it
129
- does not exist. (That is why `OF` cannot be used with `LOAD`! `WITH_TESTS` on
130
- the other hand is available also with this magic command.)
129
+ does not exist. (That is why `OF` cannot be used with `LOAD`! `NAME` on the
130
+ other hand is available also with this magic command.)
131
131
 
132
132
  ```
133
133
  %LOAD data.duckdb
134
134
  ```
135
135
 
136
- Only one database can be open at any time. If a new database is created or
137
- loaded, the current one is closed first and saved to disk if necessary.
136
+ Multiple databases can be open at any time. If a new database with the same
137
+ name is created or loaded, the current one is closed first and saved to disk
138
+ if necessary.
138
139
 
139
140
  Please note that `:memory:` is also a valid file path for DuckDB. The data is
140
141
  then stored exclusively in the main memory. In combination with `CREATE`
@@ -213,10 +214,10 @@ FROM bar
213
214
 
214
215
  ### Ship Tests With Your Notebooks
215
216
 
216
- Simple tests can be loaded together with the database with the help of
217
- the `WITH_TESTS` parameter. These tests are stored as a JSON file. Each test is
218
- assigned a unique name, a result set and whether the test should check the order
219
- of the result. A very simple test file looks like the following JSON object:
217
+ Simple tests can be loaded from json files with the help of magic command
218
+ `LOAD_TESTS`. These tests are stored as a JSON file. Each test is assigned a
219
+ unique name, a result set and whether the test should check the order of the
220
+ result. A very simple test file looks like the following JSON object:
220
221
 
221
222
  ```json
222
223
  {
@@ -1,9 +1,9 @@
1
1
  duckdb_kernel/__init__.py,sha256=6auU6zeJrsA4fxPSr2PYamS8fG-SMXTn5YQFXF2cseo,33
2
2
  duckdb_kernel/__main__.py,sha256=Z3GwHEBWoQjNm2Y84ijnbA0Lk66L7nsFREuqhZ_ptk0,165
3
3
  duckdb_kernel/kernel.json,sha256=_7E8Ci2FSdCvnzCjsOaue8QE8AvpS5JLQuxORO5IGtA,127
4
- duckdb_kernel/kernel.py,sha256=qURs-uIdQgnqZKSP0Z2Q8Eo_rrdMMdTcHdpUsURxXN8,26470
4
+ duckdb_kernel/kernel.py,sha256=qb2dEj2XhNE_9-xlpQBky7Cd4km_dqRLTXfNaNQNdpM,28189
5
5
  duckdb_kernel/db/Column.py,sha256=GM5P6sFdlYK92hiKln5-6038gIDOTxh1AYbR4kiga_w,559
6
- duckdb_kernel/db/Connection.py,sha256=5pH-CwGh-r9Q2QwJKGSxvoINBU-sqmvZyG4Q1digfeE,599
6
+ duckdb_kernel/db/Connection.py,sha256=tBXQBYt9c52RLbpl9sakNuAm0Z84--fhZ4efo8ACz-U,670
7
7
  duckdb_kernel/db/Constraint.py,sha256=1YgUHk7s8mHCVedbcuJKyXDykj7_ybbwT3Dk9p2VMis,287
8
8
  duckdb_kernel/db/DatabaseError.py,sha256=43zl8yym1f-fxH_UtGIbWnDnBE_TRwr9aCziY9t40QY,41
9
9
  duckdb_kernel/db/ForeignKey.py,sha256=iurUAXwTwSIpLXsL0B7BA8jqDTfW4_wkeHxoqQbZwiU,470
@@ -11,19 +11,19 @@ duckdb_kernel/db/Table.py,sha256=HfvGX54kD_XvmLApYSmxtTQNvz2YYaaUNpm4e8dSOVY,934
11
11
  duckdb_kernel/db/__init__.py,sha256=PKQYQDCW7VQYxmzhQK6A0Qloka9FdMfeFQMfY-CjBSA,198
12
12
  duckdb_kernel/db/error/EmptyResultError.py,sha256=N9Oxi2HDZBKaRQsfRsWpJJGOYX4BjdQqWOU-XvzUzNY,92
13
13
  duckdb_kernel/db/error/__init__.py,sha256=oHfhfbcfyTJ3pAPN835omdQcebvJTauuULFx5gm9rq4,47
14
- duckdb_kernel/db/implementation/duckdb/Connection.py,sha256=uBL-UVrSo8EJNXnnyAc2AwAYJ1QQQmH0noV6pnngZHs,6977
14
+ duckdb_kernel/db/implementation/duckdb/Connection.py,sha256=nFzj2wjHORFuRn27zfKhHtwu1Hulph7X4ImCaEbQtbQ,7051
15
15
  duckdb_kernel/db/implementation/duckdb/__init__.py,sha256=HKogB1es4wOiQUoh7_eT32xnUFLmzoCyR_0LuY9r8YQ,35
16
- duckdb_kernel/db/implementation/postgres/Connection.py,sha256=39wv-mvKHdu4u_ADFiSbAvGMVEs3FtuzRYIH4uzJ-pw,9307
16
+ duckdb_kernel/db/implementation/postgres/Connection.py,sha256=WCCdkM4V-Y2Pg-ofeTLHpyT7jgbQaw7qnaW5M1bYbX4,9490
17
17
  duckdb_kernel/db/implementation/postgres/__init__.py,sha256=HKogB1es4wOiQUoh7_eT32xnUFLmzoCyR_0LuY9r8YQ,35
18
18
  duckdb_kernel/db/implementation/postgres/util.py,sha256=4nr1mqXhlwkMVXbJSfJ7dRlUm6UskpvgKApe7GRwmBI,281
19
- duckdb_kernel/db/implementation/sqlite/Connection.py,sha256=SSLpdigWjO_3lUXdsx3eH5OXOTBlZiXOgIyPCf6L8D0,7044
19
+ duckdb_kernel/db/implementation/sqlite/Connection.py,sha256=W_7Eb2u2dHl54h5FXGQVc9oIFa6czYMhkNc2UWbTrkE,7118
20
20
  duckdb_kernel/db/implementation/sqlite/__init__.py,sha256=HKogB1es4wOiQUoh7_eT32xnUFLmzoCyR_0LuY9r8YQ,35
21
21
  duckdb_kernel/magics/MagicCommand.py,sha256=l0EmnqgGZ0HyqQhdTljAaftflVo_RYp-U5UiDftYxAA,3180
22
- duckdb_kernel/magics/MagicCommandCallback.py,sha256=9XVidNtzs8Lwq_T59VrH89t5LUgJcc5C7grusElXVW4,1041
22
+ duckdb_kernel/magics/MagicCommandCallback.py,sha256=Otl7Sa53eJtkMU5gBup3VTVCQfr7p00kt-xpnlETVe4,877
23
23
  duckdb_kernel/magics/MagicCommandException.py,sha256=MwuWkpA6NoCqz437urdI0RVXhbSbVdziuRoi7slYFPc,49
24
- duckdb_kernel/magics/MagicCommandHandler.py,sha256=noRm22EsfTZI_FL_N15f6NYbZSPvejvS24rlA5hkDkQ,4730
25
- duckdb_kernel/magics/StringWrapper.py,sha256=W6qIfeHU51do1edd6yXgw6K7orzjwSHU4oWAI5DuKEE,96
26
- duckdb_kernel/magics/__init__.py,sha256=DA8gnQeRCUt1Scy3_NQ9w5CPmMEY9i8YwB-g392pN1U,204
24
+ duckdb_kernel/magics/MagicCommandHandler.py,sha256=hKNHRfa0BSPei4QXdVlLlbpvZIhJJ91aaT_HTMiK28E,4700
25
+ duckdb_kernel/magics/MagicState.py,sha256=Vt_KwUwQP3446c1snSxS68Skl5AZQzrJd2Q1ETpKuKI,344
26
+ duckdb_kernel/magics/__init__.py,sha256=ggxzDzDEsKMZzYsWw9JqYVJhciJPvPVYGV7oNo9Yp-E,239
27
27
  duckdb_kernel/parser/DCParser.py,sha256=16c1mxa494KP9OreUKQHsSQKoDGZ7NNp2u_gi_D-dkw,2293
28
28
  duckdb_kernel/parser/LogicParser.py,sha256=_vZwE5OPRUEN8aEC_fSZAYKR_dpexqNthXog9OFHYRY,1233
29
29
  duckdb_kernel/parser/ParserError.py,sha256=qJQVloFtID1HgVDQ1Io247bODT1ic3oO9Z1ZrWR-2Mk,321
@@ -85,11 +85,15 @@ duckdb_kernel/util/TestError.py,sha256=iwlGHr9j6pFDa2cGxqGyvJ-exrFUtPJjVm_OhHi4n
85
85
  duckdb_kernel/util/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
86
86
  duckdb_kernel/util/formatting.py,sha256=cbt0CtERnqtzd97mLrOjeJpqM2Lo6pW96BjAYqrOTD8,793
87
87
  duckdb_kernel/visualization/Drawer.py,sha256=D0LkiGMvuJ2v6cQSg_axLTGaM4VXAJEQJAynvedQ3So,296
88
- duckdb_kernel/visualization/Plotly.py,sha256=5MDOHJsWiIYnQt4ZtKqQ69KcHetbO3N9PzJ8ZZW5CIo,3408
89
- duckdb_kernel/visualization/RATreeDrawer.py,sha256=j-Vy1zpYMzwZ3CsphyfPW-J7ou9a9tM6aXXgAlQTgDI,2128
88
+ duckdb_kernel/visualization/Plotly.py,sha256=eWW7mFJ18rbKf-CsvzaLx0wWsyPep7lByVeuUaf4-Ho,3203
89
+ duckdb_kernel/visualization/RATreeDrawer.py,sha256=5ayWknm6PhEqOZ3Pfba8gZD_7pXzCjyTuUOtdKA8Y-o,2947
90
90
  duckdb_kernel/visualization/SchemaDrawer.py,sha256=9K-TUUmyeGdMYMTFQJ7evIU3p8p2KyMKeizUc7-y8co,3015
91
91
  duckdb_kernel/visualization/__init__.py,sha256=37a-YUXb7Hr4NJCMatpjtmwP2FOPME-5wUWpszrYEMk,100
92
- jupyter_duckdb-1.2.101.dist-info/METADATA,sha256=xNQwQu4VWyfFuHjDPDENmpxnHuO2eVzN0_c9ZklAe1Q,9115
93
- jupyter_duckdb-1.2.101.dist-info/WHEEL,sha256=52BFRY2Up02UkjOa29eZOS2VxUrpPORXg1pkohGGUS8,91
94
- jupyter_duckdb-1.2.101.dist-info/top_level.txt,sha256=KvRRPMnmkQNuhyBsXoPmwyt26LRDp0O-0HN6u0Dm5jA,14
95
- jupyter_duckdb-1.2.101.dist-info/RECORD,,
92
+ duckdb_kernel/visualization/lib/__init__.py,sha256=LYi0YPtn5fXOejbLIqbt_3KzP-XrwpN8l0JzoAI_ngg,1044
93
+ duckdb_kernel/visualization/lib/plotly-3.0.1.min.js,sha256=oy6Be7Eh6eiQFs5M7oXuPxxm9qbJXEtTpfSI93dW16Q,4653932
94
+ duckdb_kernel/visualization/lib/ra.css,sha256=foz1v69EQ117BDduB9QyHH978PbRs2TG1kBS4VGqZbI,57
95
+ duckdb_kernel/visualization/lib/ra.js,sha256=VzMRn55ztcd5Kfu2B6gdRPARpi8n-fvs8oNFnfp55Ec,1845
96
+ jupyter_duckdb-1.2.103.dist-info/METADATA,sha256=KF4yFiFhppasCLN85BH8KVdKBOudeEbFIkplYy08rMg,9132
97
+ jupyter_duckdb-1.2.103.dist-info/WHEEL,sha256=1tXe9gY0PYatrMPMDd6jXqjfpz_B-Wqm32CPfRC58XU,91
98
+ jupyter_duckdb-1.2.103.dist-info/top_level.txt,sha256=KvRRPMnmkQNuhyBsXoPmwyt26LRDp0O-0HN6u0Dm5jA,14
99
+ jupyter_duckdb-1.2.103.dist-info/RECORD,,
@@ -1,5 +1,5 @@
1
1
  Wheel-Version: 1.0
2
- Generator: setuptools (76.0.0)
2
+ Generator: setuptools (77.0.3)
3
3
  Root-Is-Purelib: true
4
4
  Tag: py3-none-any
5
5
 
@@ -1,3 +0,0 @@
1
- class StringWrapper:
2
- def __init__(self, value: str = None):
3
- self.value: str = value