duckdb 0.10.3-dev8.0 → 1.0.1-dev15.0
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.
- package/.github/workflows/Electron.yml +293 -0
- package/.github/workflows/HighPriorityIssues.yml +1 -1
- package/.github/workflows/NodeJS.yml +3 -3
- package/package.json +1 -1
- package/scripts/electron-versions.json +64 -0
- package/scripts/node_build.sh +12 -0
- package/scripts/node_build_win.sh +12 -0
- package/src/duckdb/extension/parquet/parquet_extension.cpp +7 -1
- package/src/duckdb/src/catalog/dependency_manager.cpp +4 -0
- package/src/duckdb/src/common/enum_util.cpp +29 -0
- package/src/duckdb/src/common/error_data.cpp +5 -2
- package/src/duckdb/src/common/local_file_system.cpp +5 -0
- package/src/duckdb/src/common/multi_file_reader.cpp +3 -0
- package/src/duckdb/src/common/printer.cpp +1 -1
- package/src/duckdb/src/common/string_util.cpp +1 -1
- package/src/duckdb/src/core_functions/aggregate/holistic/approximate_quantile.cpp +14 -5
- package/src/duckdb/src/core_functions/aggregate/holistic/quantile.cpp +11 -3
- package/src/duckdb/src/execution/operator/helper/physical_load.cpp +2 -2
- package/src/duckdb/src/execution/operator/persistent/physical_copy_database.cpp +3 -1
- package/src/duckdb/src/execution/operator/persistent/physical_copy_to_file.cpp +13 -10
- package/src/duckdb/src/execution/physical_plan/plan_copy_to_file.cpp +2 -2
- package/src/duckdb/src/function/table/system/duckdb_extensions.cpp +2 -3
- package/src/duckdb/src/function/table/version/pragma_version.cpp +5 -5
- package/src/duckdb/src/include/duckdb/common/enum_util.hpp +8 -0
- package/src/duckdb/src/include/duckdb/common/enums/copy_overwrite_mode.hpp +18 -0
- package/src/duckdb/src/include/duckdb/common/multi_file_reader.hpp +1 -0
- package/src/duckdb/src/include/duckdb/common/shared_ptr.hpp +3 -3
- package/src/duckdb/src/include/duckdb/execution/operator/persistent/physical_copy_to_file.hpp +2 -1
- package/src/duckdb/src/include/duckdb/main/attached_database.hpp +6 -0
- package/src/duckdb/src/include/duckdb/main/config.hpp +4 -0
- package/src/duckdb/src/include/duckdb/main/extension_helper.hpp +6 -6
- package/src/duckdb/src/include/duckdb/main/settings.hpp +20 -0
- package/src/duckdb/src/include/duckdb/planner/operator/logical_comparison_join.hpp +7 -7
- package/src/duckdb/src/include/duckdb/planner/operator/logical_copy_to_file.hpp +2 -1
- package/src/duckdb/src/include/duckdb/storage/storage_extension.hpp +7 -0
- package/src/duckdb/src/include/duckdb.h +126 -4
- package/src/duckdb/src/main/attached_database.cpp +7 -6
- package/src/duckdb/src/main/capi/stream-c.cpp +17 -8
- package/src/duckdb/src/main/capi/table_function-c.cpp +11 -7
- package/src/duckdb/src/main/config.cpp +2 -0
- package/src/duckdb/src/main/extension/extension_helper.cpp +3 -25
- package/src/duckdb/src/main/extension/extension_install.cpp +10 -6
- package/src/duckdb/src/main/settings/settings.cpp +32 -0
- package/src/duckdb/src/optimizer/pushdown/pushdown_cross_product.cpp +3 -3
- package/src/duckdb/src/optimizer/rule/move_constants.cpp +4 -0
- package/src/duckdb/src/planner/binder/query_node/plan_subquery.cpp +2 -2
- package/src/duckdb/src/planner/binder/statement/bind_copy.cpp +17 -4
- package/src/duckdb/src/planner/binder/statement/bind_create.cpp +26 -15
- package/src/duckdb/src/planner/binder/tableref/plan_joinref.cpp +29 -11
- package/src/duckdb/src/planner/operator/logical_copy_to_file.cpp +3 -3
- package/src/duckdb/src/storage/storage_manager.cpp +17 -8
- package/test/replacement_scan.test.ts +2 -0
- /package/src/duckdb/src/include/duckdb/common/{enable_shared_from_this.ipp → enable_shared_from_this_ipp.hpp} +0 -0
- /package/src/duckdb/src/include/duckdb/common/{shared_ptr.ipp → shared_ptr_ipp.hpp} +0 -0
- /package/src/duckdb/src/include/duckdb/common/{weak_ptr.ipp → weak_ptr_ipp.hpp} +0 -0
@@ -0,0 +1,293 @@
|
|
1
|
+
name: Electron
|
2
|
+
on:
|
3
|
+
push:
|
4
|
+
pull_request:
|
5
|
+
workflow_dispatch:
|
6
|
+
repository_dispatch:
|
7
|
+
|
8
|
+
concurrency:
|
9
|
+
group: ${{ github.workflow }}-${{ github.ref }}-${{ github.head_ref || '' }}-${{ github.base_ref || '' }}-${{ github.ref != 'refs/heads/main' || github.sha }}
|
10
|
+
cancel-in-progress: false
|
11
|
+
|
12
|
+
env:
|
13
|
+
GH_TOKEN: ${{ secrets.GH_TOKEN }}
|
14
|
+
AWS_ACCESS_KEY_ID: ${{secrets.S3_DUCKDB_NODE_ID}}
|
15
|
+
AWS_SECRET_ACCESS_KEY: ${{secrets.S3_DUCKDB_NODE_KEY}}
|
16
|
+
AWS_DEFAULT_REGION: us-east-1
|
17
|
+
|
18
|
+
jobs:
|
19
|
+
set-up-npm:
|
20
|
+
name: Set up NPM
|
21
|
+
runs-on: ubuntu-20.04
|
22
|
+
env:
|
23
|
+
DUCKDB_NODE_BUILD_CACHE: 0
|
24
|
+
steps:
|
25
|
+
- uses: actions/checkout@v3
|
26
|
+
with:
|
27
|
+
fetch-depth: 0
|
28
|
+
|
29
|
+
- uses: actions/setup-python@v4
|
30
|
+
with:
|
31
|
+
python-version: '3.11'
|
32
|
+
|
33
|
+
- name: Setup NPM
|
34
|
+
shell: bash
|
35
|
+
run: ./scripts/node_version.sh upload
|
36
|
+
env:
|
37
|
+
DUCKDB_NODE_BUILD_CACHE: 0 # create a standalone package
|
38
|
+
NODE_AUTH_TOKEN: ${{secrets.NODE_AUTH_TOKEN}}
|
39
|
+
|
40
|
+
# From `npm show electron time --json` and https://www.electronjs.org/docs/latest/tutorial/electron-timelines
|
41
|
+
set-up-electron-versions:
|
42
|
+
name: Set up Electron version
|
43
|
+
runs-on: ubuntu-20.04
|
44
|
+
outputs:
|
45
|
+
matrix: ${{ steps.setup.outputs.matrix }}
|
46
|
+
steps:
|
47
|
+
- uses: actions/checkout@v3
|
48
|
+
with:
|
49
|
+
fetch-depth: 0
|
50
|
+
|
51
|
+
- id: setup
|
52
|
+
run: |
|
53
|
+
echo "matrix=$(jq -c '[.[] | select(.electron == ("18.3.15", "22.3.27"))]' < scripts/electron-versions.json)" >> $GITHUB_OUTPUT
|
54
|
+
|
55
|
+
- name: Check
|
56
|
+
run: |
|
57
|
+
jq . <<< '${{ steps.setup.outputs.matrix }}'
|
58
|
+
|
59
|
+
linux-electron:
|
60
|
+
name: Electron Linux
|
61
|
+
runs-on: ubuntu-20.04
|
62
|
+
needs: [set-up-npm, set-up-electron-versions]
|
63
|
+
env:
|
64
|
+
TARGET_ARCH: ${{ matrix.target_arch }}
|
65
|
+
DUCKDB_NODE_BUILD_CACHE: 0
|
66
|
+
strategy:
|
67
|
+
matrix:
|
68
|
+
version: ${{ fromJSON(needs.set-up-electron-versions.outputs.matrix) }}
|
69
|
+
target_arch: [ x64, arm64 ]
|
70
|
+
|
71
|
+
steps:
|
72
|
+
- uses: actions/checkout@v3
|
73
|
+
with:
|
74
|
+
fetch-depth: 0
|
75
|
+
|
76
|
+
# Default Python (3.12) doesn't have support for distutils
|
77
|
+
- uses: actions/setup-python@v4
|
78
|
+
with:
|
79
|
+
python-version: '3.10'
|
80
|
+
|
81
|
+
- name: Update apt
|
82
|
+
shell: bash
|
83
|
+
run: |
|
84
|
+
sudo apt-get update -y
|
85
|
+
|
86
|
+
- name: Install requirements
|
87
|
+
shell: bash
|
88
|
+
run: |
|
89
|
+
sudo apt-get install -y git ninja-build make gcc-multilib g++-multilib wget libssl-dev
|
90
|
+
|
91
|
+
- name: Setup Ccache
|
92
|
+
uses: hendrikmuhs/ccache-action@main
|
93
|
+
with:
|
94
|
+
key: ${{ github.job }}
|
95
|
+
save: ${{ ( github.ref == 'refs/heads/main' || github.repository != 'duckdb/duckdb-node' ) && startsWith(matrix.version.node, '19') }}
|
96
|
+
|
97
|
+
- name: Setup
|
98
|
+
shell: bash
|
99
|
+
run: ./scripts/node_version.sh
|
100
|
+
env:
|
101
|
+
DUCKDB_NODE_BUILD_CACHE: 0 # create a standalone package
|
102
|
+
NODE_AUTH_TOKEN: ${{secrets.NODE_AUTH_TOKEN}}
|
103
|
+
|
104
|
+
- name: Validate Docs
|
105
|
+
run: npx jsdoc-to-markdown --files lib/*.js >> $GITHUB_STEP_SUMMARY
|
106
|
+
env:
|
107
|
+
npm_config_yes: true
|
108
|
+
|
109
|
+
- name: Electron ${{ matrix.version.electron }}
|
110
|
+
shell: bash
|
111
|
+
run: ./scripts/node_build.sh ${{ matrix.version.node }}
|
112
|
+
env:
|
113
|
+
ELECTRON_VERSION: ${{ matrix.version.electron }}
|
114
|
+
|
115
|
+
osx-electron-arm64:
|
116
|
+
name: Electron OSX
|
117
|
+
runs-on: macos-14
|
118
|
+
needs: set-up-npm
|
119
|
+
strategy:
|
120
|
+
matrix:
|
121
|
+
version: ${{ fromJSON(needs.set-up-electron-versions.outputs.matrix) }}
|
122
|
+
target_arch: [ arm64 ]
|
123
|
+
|
124
|
+
env:
|
125
|
+
TARGET_ARCH: ${{ matrix.target_arch }}
|
126
|
+
DUCKDB_NODE_BUILD_CACHE: 0
|
127
|
+
steps:
|
128
|
+
- uses: actions/checkout@v3
|
129
|
+
with:
|
130
|
+
fetch-depth: 0
|
131
|
+
|
132
|
+
# Default Python (3.12) doesn't have support for distutils
|
133
|
+
- uses: actions/setup-python@v4
|
134
|
+
with:
|
135
|
+
python-version: '3.11'
|
136
|
+
|
137
|
+
- name: Setup Ccache
|
138
|
+
uses: hendrikmuhs/ccache-action@main
|
139
|
+
with:
|
140
|
+
key: ${{ github.job }}-${{ matrix.target_arch }}
|
141
|
+
save: ${{ ( github.ref == 'refs/heads/main' || github.repository != 'duckdb/duckdb-node' ) && startsWith(matrix.version.node, '19') }}
|
142
|
+
|
143
|
+
- name: Downgrade curl # fixes a bug with the brew curl that lead to failed downloads
|
144
|
+
shell: bash
|
145
|
+
run: |
|
146
|
+
brew uninstall --ignore-dependencies curl
|
147
|
+
which curl
|
148
|
+
|
149
|
+
- name: Setup
|
150
|
+
shell: bash
|
151
|
+
run: ./scripts/node_version.sh
|
152
|
+
env:
|
153
|
+
NODE_AUTH_TOKEN: ${{secrets.NODE_AUTH_TOKEN}}
|
154
|
+
|
155
|
+
- name: Electron ${{ matrix.version.electron }}
|
156
|
+
shell: bash
|
157
|
+
run: ./scripts/node_build.sh 18
|
158
|
+
env:
|
159
|
+
ELECTRON_VERSION: ${{ matrix.version.electron }}
|
160
|
+
|
161
|
+
osx-electron-x64:
|
162
|
+
name: Electron OSX
|
163
|
+
runs-on: macos-13
|
164
|
+
needs: set-up-npm
|
165
|
+
strategy:
|
166
|
+
matrix:
|
167
|
+
version: ${{ fromJSON(needs.set-up-electron-versions.outputs.matrix) }}
|
168
|
+
target_arch: [ x64 ]
|
169
|
+
|
170
|
+
env:
|
171
|
+
TARGET_ARCH: ${{ matrix.target_arch }}
|
172
|
+
DUCKDB_NODE_BUILD_CACHE: 0
|
173
|
+
steps:
|
174
|
+
- uses: actions/checkout@v3
|
175
|
+
with:
|
176
|
+
fetch-depth: 0
|
177
|
+
|
178
|
+
# Default Python (3.12) doesn't have support for distutils
|
179
|
+
- uses: actions/setup-python@v4
|
180
|
+
with:
|
181
|
+
python-version: '3.11'
|
182
|
+
|
183
|
+
- name: Setup Ccache
|
184
|
+
uses: hendrikmuhs/ccache-action@main
|
185
|
+
with:
|
186
|
+
key: ${{ github.job }}-${{ matrix.target_arch }}
|
187
|
+
save: ${{ ( github.ref == 'refs/heads/main' || github.repository != 'duckdb/duckdb-node' ) && startsWith(matrix.version.node, '19') }}
|
188
|
+
|
189
|
+
- name: Downgrade curl # fixes a bug with the brew curl that lead to failed downloads
|
190
|
+
shell: bash
|
191
|
+
run: |
|
192
|
+
brew uninstall --ignore-dependencies curl
|
193
|
+
which curl
|
194
|
+
|
195
|
+
- name: Setup
|
196
|
+
shell: bash
|
197
|
+
run: ./scripts/node_version.sh
|
198
|
+
env:
|
199
|
+
NODE_AUTH_TOKEN: ${{secrets.NODE_AUTH_TOKEN}}
|
200
|
+
|
201
|
+
- name: Electron ${{ matrix.version.electron }}
|
202
|
+
shell: bash
|
203
|
+
run: ./scripts/node_build.sh 18
|
204
|
+
env:
|
205
|
+
ELECTRON_VERSION: ${{ matrix.version.electron }}
|
206
|
+
|
207
|
+
win-electron:
|
208
|
+
name: node.js Windows
|
209
|
+
runs-on: windows-latest
|
210
|
+
needs: set-up-npm
|
211
|
+
continue-on-error: ${{ !startsWith(matrix.version.node, '18') && !startsWith(matrix.version.node, '20') && !startsWith(matrix.version.node, '21') }}
|
212
|
+
env:
|
213
|
+
npm_config_msvs_version: 2019
|
214
|
+
|
215
|
+
strategy:
|
216
|
+
matrix:
|
217
|
+
target_arch: [ arm64 ]
|
218
|
+
version: ${{ fromJSON(needs.set-up-electron-versions.outputs.matrix) }}
|
219
|
+
|
220
|
+
steps:
|
221
|
+
# Default Python (3.12) doesn't have support for distutils
|
222
|
+
- uses: actions/setup-python@v4
|
223
|
+
with:
|
224
|
+
python-version: '3.11'
|
225
|
+
|
226
|
+
- uses: actions/checkout@v3
|
227
|
+
with:
|
228
|
+
fetch-depth: 0
|
229
|
+
|
230
|
+
- name: Setup Node
|
231
|
+
uses: actions/setup-node@v3
|
232
|
+
with:
|
233
|
+
node-version: 18
|
234
|
+
|
235
|
+
- name: Versions
|
236
|
+
shell: bash
|
237
|
+
run: |
|
238
|
+
systeminfo
|
239
|
+
node -v
|
240
|
+
npm -v
|
241
|
+
|
242
|
+
- name: Windows Build Tools
|
243
|
+
shell: bash
|
244
|
+
run: |
|
245
|
+
choco install visualstudio2019-workload-vctools -y
|
246
|
+
|
247
|
+
- name: Node Version
|
248
|
+
shell: bash
|
249
|
+
run: ./scripts/node_version.sh
|
250
|
+
env:
|
251
|
+
NODE_AUTH_TOKEN: ${{secrets.NODE_AUTH_TOKEN}}
|
252
|
+
|
253
|
+
- name: Setup Ccache
|
254
|
+
uses: hendrikmuhs/ccache-action@main
|
255
|
+
with:
|
256
|
+
key: ${{ github.job }}-${{ matrix.version.node }}
|
257
|
+
save: ${{ github.ref == 'refs/heads/main' || github.repository != 'duckdb/duckdb-node' }}
|
258
|
+
variant: sccache
|
259
|
+
|
260
|
+
- name: Electron
|
261
|
+
shell: bash
|
262
|
+
run: ./scripts/node_build_win.sh
|
263
|
+
env:
|
264
|
+
ELECTRON_VERSION: ${{ matrix.version.electron }}
|
265
|
+
|
266
|
+
test_matrix:
|
267
|
+
needs:
|
268
|
+
- linux-electron
|
269
|
+
- osx-electron-arm64
|
270
|
+
- osx-electron-x64
|
271
|
+
- win-electron
|
272
|
+
strategy:
|
273
|
+
matrix:
|
274
|
+
os: [windows-latest, ubuntu-latest, ubuntu-22.04, ubuntu-20.04, windows-2019, macos-12, macos-13, macos-14]
|
275
|
+
version: [20]
|
276
|
+
runs-on: ${{ matrix.os }}
|
277
|
+
steps:
|
278
|
+
- uses: actions/setup-node@v4
|
279
|
+
with:
|
280
|
+
node-version: ${{ matrix.version }}
|
281
|
+
|
282
|
+
- uses: actions/checkout@v3
|
283
|
+
with:
|
284
|
+
sparse-checkout: examples
|
285
|
+
|
286
|
+
- name: Install duckdb
|
287
|
+
run: |
|
288
|
+
npm install duckdb@next
|
289
|
+
|
290
|
+
- name: Run minor test
|
291
|
+
shell: bash
|
292
|
+
run: |
|
293
|
+
node examples/example.js
|
@@ -32,5 +32,5 @@ jobs:
|
|
32
32
|
- name: Create or label issue
|
33
33
|
run: |
|
34
34
|
if [ "$MIRROR_ISSUE_NUMBER" == "" ]; then
|
35
|
-
gh issue create --repo duckdblabs/duckdb-internal --label "Node.js" --
|
35
|
+
gh issue create --repo duckdblabs/duckdb-internal --label "Node.js" --title "$TITLE_PREFIX - $PUBLIC_ISSUE_TITLE" --body "See https://github.com/duckdb/duckdb-node/issues/${{ github.event.issue.number }}"
|
36
36
|
fi
|
@@ -116,7 +116,7 @@ jobs:
|
|
116
116
|
run: ./scripts/node_build.sh ${{ matrix.node }}
|
117
117
|
|
118
118
|
osx-nodejs-arm64:
|
119
|
-
name: node.js OSX
|
119
|
+
name: node.js OSX arm64
|
120
120
|
runs-on: macos-14
|
121
121
|
needs: set-up-npm
|
122
122
|
continue-on-error: ${{ matrix.node != '18' && matrix.node != '20' && matrix.node != '21' }}
|
@@ -179,7 +179,7 @@ jobs:
|
|
179
179
|
run: ./scripts/node_build.sh ${{ matrix.node }}
|
180
180
|
|
181
181
|
osx-nodejs-x64:
|
182
|
-
name: node.js OSX
|
182
|
+
name: node.js OSX x64
|
183
183
|
runs-on: macos-13
|
184
184
|
needs: set-up-npm
|
185
185
|
continue-on-error: ${{ matrix.node != '18' && matrix.node != '20' && matrix.node != '21' }}
|
@@ -251,7 +251,7 @@ jobs:
|
|
251
251
|
|
252
252
|
strategy:
|
253
253
|
matrix:
|
254
|
-
node: [ '16', '17', '18', '19', '20', '21']
|
254
|
+
node: [ '16', '17', '18', '19', '20', '21', '22' ]
|
255
255
|
isRelease:
|
256
256
|
- ${{ startsWith(github.ref, 'refs/tags/v') || github.ref == 'refs/heads/main' }}
|
257
257
|
exclude:
|
package/package.json
CHANGED
@@ -0,0 +1,64 @@
|
|
1
|
+
[
|
2
|
+
{ "electron": "18.3.15", "node": "16.13" },
|
3
|
+
{ "electron": "19.0.17", "node": "16.14" },
|
4
|
+
{ "electron": "19.1.9", "node": "16.14" },
|
5
|
+
{ "electron": "20.0.3", "node": "16.15" },
|
6
|
+
{ "electron": "20.1.4", "node": "16.15" },
|
7
|
+
{ "electron": "20.2.0", "node": "16.15" },
|
8
|
+
{ "electron": "20.3.12", "node": "16.15" },
|
9
|
+
{ "electron": "21.0.1", "node": "16.16" },
|
10
|
+
{ "electron": "21.1.1", "node": "16.16" },
|
11
|
+
{ "electron": "21.2.3", "node": "16.16" },
|
12
|
+
{ "electron": "21.3.5", "node": "16.16" },
|
13
|
+
{ "electron": "21.4.4", "node": "16.16" },
|
14
|
+
{ "electron": "22.0.3", "node": "16.17" },
|
15
|
+
{ "electron": "22.1.0", "node": "16.17" },
|
16
|
+
{ "electron": "22.2.1", "node": "16.17" },
|
17
|
+
{ "electron": "22.3.27", "node": "16.17" },
|
18
|
+
{ "electron": "23.0.0", "node": "18.12" },
|
19
|
+
{ "electron": "23.1.4", "node": "18.12" },
|
20
|
+
{ "electron": "23.2.4", "node": "18.12" },
|
21
|
+
{ "electron": "23.3.13", "node": "18.12" },
|
22
|
+
{ "electron": "24.0.0", "node": "18.14" },
|
23
|
+
{ "electron": "24.1.3", "node": "18.14" },
|
24
|
+
{ "electron": "24.2.0", "node": "18.14" },
|
25
|
+
{ "electron": "24.3.1", "node": "18.14" },
|
26
|
+
{ "electron": "24.4.1", "node": "18.14" },
|
27
|
+
{ "electron": "24.5.1", "node": "18.14" },
|
28
|
+
{ "electron": "24.6.5", "node": "18.14" },
|
29
|
+
{ "electron": "24.7.1", "node": "18.14" },
|
30
|
+
{ "electron": "24.8.8", "node": "18.14" },
|
31
|
+
{ "electron": "25.0.1", "node": "18.15" },
|
32
|
+
{ "electron": "25.1.1", "node": "18.15" },
|
33
|
+
{ "electron": "25.2.0", "node": "18.15" },
|
34
|
+
{ "electron": "25.3.2", "node": "18.15" },
|
35
|
+
{ "electron": "25.4.0", "node": "18.15" },
|
36
|
+
{ "electron": "25.5.0", "node": "18.15" },
|
37
|
+
{ "electron": "25.6.0", "node": "18.15" },
|
38
|
+
{ "electron": "25.7.0", "node": "18.15" },
|
39
|
+
{ "electron": "25.8.4", "node": "18.15" },
|
40
|
+
{ "electron": "25.9.8", "node": "18.15" },
|
41
|
+
{ "electron": "26.0.0", "node": "18.16" },
|
42
|
+
{ "electron": "26.1.0", "node": "18.16" },
|
43
|
+
{ "electron": "26.2.4", "node": "18.16" },
|
44
|
+
{ "electron": "26.3.0", "node": "18.16" },
|
45
|
+
{ "electron": "26.4.3", "node": "18.16" },
|
46
|
+
{ "electron": "26.5.0", "node": "18.16" },
|
47
|
+
{ "electron": "26.6.10", "node": "18.16" },
|
48
|
+
{ "electron": "27.0.4", "node": "18.17" },
|
49
|
+
{ "electron": "27.1.3", "node": "18.17" },
|
50
|
+
{ "electron": "27.2.4", "node": "18.17" },
|
51
|
+
{ "electron": "27.3.11", "node": "18.17" },
|
52
|
+
{ "electron": "28.0.0", "node": "18.18" },
|
53
|
+
{ "electron": "28.1.4", "node": "18.18" },
|
54
|
+
{ "electron": "28.2.10", "node": "18.18" },
|
55
|
+
{ "electron": "28.3.3", "node": "18.18" },
|
56
|
+
{ "electron": "29.0.1", "node": "20.9" },
|
57
|
+
{ "electron": "29.1.6", "node": "20.9" },
|
58
|
+
{ "electron": "29.2.0", "node": "20.9" },
|
59
|
+
{ "electron": "29.3.3", "node": "20.9" },
|
60
|
+
{ "electron": "29.4.3", "node": "20.9" },
|
61
|
+
{ "electron": "30.0.9", "node": "20.11" },
|
62
|
+
{ "electron": "30.1.2", "node": "20.11" },
|
63
|
+
{ "electron": "31.0.2", "node": "20.14" }
|
64
|
+
]
|
package/scripts/node_build.sh
CHANGED
@@ -16,6 +16,18 @@ if [ "$(expr substr $(uname -s) 1 5)" == "Linux" ] && [[ "$TARGET_ARCH" == "arm6
|
|
16
16
|
export CXX=aarch64-linux-gnu-g++
|
17
17
|
fi
|
18
18
|
|
19
|
+
if [ -n "$ELECTRON_VERSION" ] ; then
|
20
|
+
# Electron's version.
|
21
|
+
export npm_config_target="$ELECTRON_VERSION"
|
22
|
+
# The architecture of your machine
|
23
|
+
export npm_config_arch="$TARGET_ARCH"
|
24
|
+
export npm_config_target_arch="$TARGET_ARCH"
|
25
|
+
# Download headers for Electron.
|
26
|
+
export npm_config_disturl=https://electronjs.org/headers
|
27
|
+
# Tell node-pre-gyp that we are building for Electron.
|
28
|
+
export npm_config_runtime=electron
|
29
|
+
fi
|
30
|
+
|
19
31
|
npm install --build-from-source --target_arch="$TARGET_ARCH"
|
20
32
|
|
21
33
|
./node_modules/.bin/node-pre-gyp reveal --target_arch="$TARGET_ARCH"
|
@@ -8,6 +8,18 @@ which node
|
|
8
8
|
|
9
9
|
make clean
|
10
10
|
|
11
|
+
if [ -n "$ELECTRON_VERSION" ] ; then
|
12
|
+
# Electron's version.
|
13
|
+
export npm_config_target="$ELECTRON_VERSION"
|
14
|
+
# The architecture of your machine
|
15
|
+
export npm_config_arch="$TARGET_ARCH"
|
16
|
+
export npm_config_target_arch="$TARGET_ARCH"
|
17
|
+
# Download headers for Electron.
|
18
|
+
export npm_config_disturl=https://electronjs.org/headers
|
19
|
+
# Tell node-pre-gyp that we are building for Electron.
|
20
|
+
export npm_config_runtime=electron
|
21
|
+
fi
|
22
|
+
|
11
23
|
npm install --build-from-source
|
12
24
|
# no tests on releases
|
13
25
|
if [[ ! "$GITHUB_REF" =~ ^(refs/tags/v.+)$ ]] ; then
|
@@ -651,7 +651,13 @@ public:
|
|
651
651
|
bool require_extra_columns =
|
652
652
|
result->multi_file_reader_state && result->multi_file_reader_state->RequiresExtraColumns();
|
653
653
|
if (input.CanRemoveFilterColumns() || require_extra_columns) {
|
654
|
-
|
654
|
+
if (!input.projection_ids.empty()) {
|
655
|
+
result->projection_ids = input.projection_ids;
|
656
|
+
} else {
|
657
|
+
result->projection_ids.resize(input.column_ids.size());
|
658
|
+
iota(begin(result->projection_ids), end(result->projection_ids), 0);
|
659
|
+
}
|
660
|
+
|
655
661
|
const auto table_types = bind_data.types;
|
656
662
|
for (const auto &col_idx : input.column_ids) {
|
657
663
|
if (IsRowIdColumnId(col_idx)) {
|
@@ -18,6 +18,7 @@
|
|
18
18
|
#include "duckdb/common/enums/catalog_lookup_behavior.hpp"
|
19
19
|
#include "duckdb/common/enums/catalog_type.hpp"
|
20
20
|
#include "duckdb/common/enums/compression_type.hpp"
|
21
|
+
#include "duckdb/common/enums/copy_overwrite_mode.hpp"
|
21
22
|
#include "duckdb/common/enums/cte_materialize.hpp"
|
22
23
|
#include "duckdb/common/enums/date_part_specifier.hpp"
|
23
24
|
#include "duckdb/common/enums/debug_initialize.hpp"
|
@@ -1306,6 +1307,34 @@ ConstraintType EnumUtil::FromString<ConstraintType>(const char *value) {
|
|
1306
1307
|
throw NotImplementedException(StringUtil::Format("Enum value: '%s' not implemented", value));
|
1307
1308
|
}
|
1308
1309
|
|
1310
|
+
template<>
|
1311
|
+
const char* EnumUtil::ToChars<CopyOverwriteMode>(CopyOverwriteMode value) {
|
1312
|
+
switch(value) {
|
1313
|
+
case CopyOverwriteMode::COPY_ERROR_ON_CONFLICT:
|
1314
|
+
return "COPY_ERROR_ON_CONFLICT";
|
1315
|
+
case CopyOverwriteMode::COPY_OVERWRITE:
|
1316
|
+
return "COPY_OVERWRITE";
|
1317
|
+
case CopyOverwriteMode::COPY_OVERWRITE_OR_IGNORE:
|
1318
|
+
return "COPY_OVERWRITE_OR_IGNORE";
|
1319
|
+
default:
|
1320
|
+
throw NotImplementedException(StringUtil::Format("Enum value: '%d' not implemented", value));
|
1321
|
+
}
|
1322
|
+
}
|
1323
|
+
|
1324
|
+
template<>
|
1325
|
+
CopyOverwriteMode EnumUtil::FromString<CopyOverwriteMode>(const char *value) {
|
1326
|
+
if (StringUtil::Equals(value, "COPY_ERROR_ON_CONFLICT")) {
|
1327
|
+
return CopyOverwriteMode::COPY_ERROR_ON_CONFLICT;
|
1328
|
+
}
|
1329
|
+
if (StringUtil::Equals(value, "COPY_OVERWRITE")) {
|
1330
|
+
return CopyOverwriteMode::COPY_OVERWRITE;
|
1331
|
+
}
|
1332
|
+
if (StringUtil::Equals(value, "COPY_OVERWRITE_OR_IGNORE")) {
|
1333
|
+
return CopyOverwriteMode::COPY_OVERWRITE_OR_IGNORE;
|
1334
|
+
}
|
1335
|
+
throw NotImplementedException(StringUtil::Format("Enum value: '%s' not implemented", value));
|
1336
|
+
}
|
1337
|
+
|
1309
1338
|
template<>
|
1310
1339
|
const char* EnumUtil::ToChars<DataFileType>(DataFileType value) {
|
1311
1340
|
switch(value) {
|
@@ -1,6 +1,6 @@
|
|
1
1
|
#include "duckdb/common/error_data.hpp"
|
2
|
-
#include "duckdb/common/exception.hpp"
|
3
2
|
|
3
|
+
#include "duckdb/common/exception.hpp"
|
4
4
|
#include "duckdb/common/string_util.hpp"
|
5
5
|
#include "duckdb/common/to_string.hpp"
|
6
6
|
#include "duckdb/common/types.hpp"
|
@@ -50,7 +50,10 @@ ErrorData::ErrorData(const string &message) : initialized(true), type(ExceptionT
|
|
50
50
|
|
51
51
|
const string &ErrorData::Message() {
|
52
52
|
if (final_message.empty()) {
|
53
|
-
|
53
|
+
if (type != ExceptionType::UNKNOWN_TYPE) {
|
54
|
+
final_message = Exception::ExceptionTypeToString(type) + " ";
|
55
|
+
}
|
56
|
+
final_message += "Error: " + raw_message;
|
54
57
|
if (type == ExceptionType::INTERNAL) {
|
55
58
|
final_message += "\nThis error signals an assertion failure within DuckDB. This usually occurs due to "
|
56
59
|
"unexpected conditions or errors in the program's logic.\nFor more information, see "
|
@@ -485,9 +485,14 @@ int64_t LocalFileSystem::Write(FileHandle &handle, void *buffer, int64_t nr_byte
|
|
485
485
|
|
486
486
|
bool LocalFileSystem::Trim(FileHandle &handle, idx_t offset_bytes, idx_t length_bytes) {
|
487
487
|
#if defined(__linux__)
|
488
|
+
// FALLOC_FL_PUNCH_HOLE requires glibc 2.18 or up
|
489
|
+
#if __GLIBC__ < 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ < 18)
|
490
|
+
return false;
|
491
|
+
#else
|
488
492
|
int fd = handle.Cast<UnixFileHandle>().fd;
|
489
493
|
int res = fallocate(fd, FALLOC_FL_PUNCH_HOLE | FALLOC_FL_KEEP_SIZE, offset_bytes, length_bytes);
|
490
494
|
return res == 0;
|
495
|
+
#endif
|
491
496
|
#else
|
492
497
|
return false;
|
493
498
|
#endif
|
@@ -62,7 +62,7 @@ idx_t Printer::TerminalWidth() {
|
|
62
62
|
#ifndef DUCKDB_DISABLE_PRINT
|
63
63
|
#ifdef DUCKDB_WINDOWS
|
64
64
|
CONSOLE_SCREEN_BUFFER_INFO csbi;
|
65
|
-
int
|
65
|
+
int rows;
|
66
66
|
|
67
67
|
GetConsoleScreenBufferInfo(GetStdHandle(STD_OUTPUT_HANDLE), &csbi);
|
68
68
|
rows = csbi.srWindow.Right - csbi.srWindow.Left + 1;
|
@@ -246,7 +246,7 @@ bool StringUtil::CIEquals(const string &l1, const string &l2) {
|
|
246
246
|
bool StringUtil::CILessThan(const string &s1, const string &s2) {
|
247
247
|
const auto charmap = UpperFun::ASCII_TO_UPPER_MAP;
|
248
248
|
|
249
|
-
unsigned char u1, u2;
|
249
|
+
unsigned char u1 {}, u2 {};
|
250
250
|
|
251
251
|
idx_t length = MinValue<idx_t>(s1.length(), s2.length());
|
252
252
|
length += s1.length() != s2.length();
|
@@ -181,16 +181,25 @@ unique_ptr<FunctionData> BindApproxQuantile(ClientContext &context, AggregateFun
|
|
181
181
|
throw BinderException("APPROXIMATE QUANTILE can only take constant quantile parameters");
|
182
182
|
}
|
183
183
|
Value quantile_val = ExpressionExecutor::EvaluateScalar(context, *arguments[1]);
|
184
|
+
if (quantile_val.IsNull()) {
|
185
|
+
throw BinderException("APPROXIMATE QUANTILE parameter list cannot be NULL");
|
186
|
+
}
|
184
187
|
|
185
188
|
vector<float> quantiles;
|
186
|
-
|
187
|
-
|
188
|
-
} else if (quantile_val.IsNull()) {
|
189
|
-
throw BinderException("APPROXIMATE QUANTILE parameter list cannot be NULL");
|
190
|
-
} else {
|
189
|
+
switch (quantile_val.type().id()) {
|
190
|
+
case LogicalTypeId::LIST:
|
191
191
|
for (const auto &element_val : ListValue::GetChildren(quantile_val)) {
|
192
192
|
quantiles.push_back(CheckApproxQuantile(element_val));
|
193
193
|
}
|
194
|
+
break;
|
195
|
+
case LogicalTypeId::ARRAY:
|
196
|
+
for (const auto &element_val : ArrayValue::GetChildren(quantile_val)) {
|
197
|
+
quantiles.push_back(CheckApproxQuantile(element_val));
|
198
|
+
}
|
199
|
+
break;
|
200
|
+
default:
|
201
|
+
quantiles.push_back(CheckApproxQuantile(quantile_val));
|
202
|
+
break;
|
194
203
|
}
|
195
204
|
|
196
205
|
// remove the quantile argument so we can use the unary aggregate
|
@@ -1509,12 +1509,20 @@ unique_ptr<FunctionData> BindQuantile(ClientContext &context, AggregateFunction
|
|
1509
1509
|
throw BinderException("QUANTILE argument must not be NULL");
|
1510
1510
|
}
|
1511
1511
|
vector<Value> quantiles;
|
1512
|
-
|
1513
|
-
|
1514
|
-
} else {
|
1512
|
+
switch (quantile_val.type().id()) {
|
1513
|
+
case LogicalTypeId::LIST:
|
1515
1514
|
for (const auto &element_val : ListValue::GetChildren(quantile_val)) {
|
1516
1515
|
quantiles.push_back(CheckQuantile(element_val));
|
1517
1516
|
}
|
1517
|
+
break;
|
1518
|
+
case LogicalTypeId::ARRAY:
|
1519
|
+
for (const auto &element_val : ArrayValue::GetChildren(quantile_val)) {
|
1520
|
+
quantiles.push_back(CheckQuantile(element_val));
|
1521
|
+
}
|
1522
|
+
break;
|
1523
|
+
default:
|
1524
|
+
quantiles.push_back(CheckQuantile(quantile_val));
|
1525
|
+
break;
|
1518
1526
|
}
|
1519
1527
|
|
1520
1528
|
Function::EraseArgument(function, arguments, arguments.size() - 1);
|
@@ -17,14 +17,14 @@ static void InstallFromRepository(ClientContext &context, const LoadInfo &info)
|
|
17
17
|
}
|
18
18
|
|
19
19
|
ExtensionHelper::InstallExtension(context, info.filename, info.load_type == LoadType::FORCE_INSTALL, repository,
|
20
|
-
info.version);
|
20
|
+
true, info.version);
|
21
21
|
}
|
22
22
|
|
23
23
|
SourceResultType PhysicalLoad::GetData(ExecutionContext &context, DataChunk &chunk, OperatorSourceInput &input) const {
|
24
24
|
if (info->load_type == LoadType::INSTALL || info->load_type == LoadType::FORCE_INSTALL) {
|
25
25
|
if (info->repository.empty()) {
|
26
26
|
ExtensionHelper::InstallExtension(context.client, info->filename,
|
27
|
-
info->load_type == LoadType::FORCE_INSTALL, nullptr, info->version);
|
27
|
+
info->load_type == LoadType::FORCE_INSTALL, nullptr, true, info->version);
|
28
28
|
} else {
|
29
29
|
InstallFromRepository(context.client, *info);
|
30
30
|
}
|
@@ -49,8 +49,10 @@ SourceResultType PhysicalCopyDatabase::GetData(ExecutionContext &context, DataCh
|
|
49
49
|
catalog.CreateTable(context.client, *bound_info);
|
50
50
|
break;
|
51
51
|
}
|
52
|
+
case CatalogType::INDEX_ENTRY:
|
52
53
|
default:
|
53
|
-
throw
|
54
|
+
throw NotImplementedException("Entry type %s not supported in PhysicalCopyDatabase",
|
55
|
+
CatalogTypeToString(create_info->type));
|
54
56
|
}
|
55
57
|
}
|
56
58
|
return SourceResultType::FINISHED;
|