Skip to content

Commit c74fb33

Browse files
committed
apply patches, attempt fixup CI
1 parent 3be7dce commit c74fb33

File tree

4 files changed

+24
-16
lines changed

4 files changed

+24
-16
lines changed

.github/workflows/Linux.yml

+6-4
Original file line numberDiff line numberDiff line change
@@ -16,23 +16,25 @@ jobs:
1616
matrix:
1717
# Add commits/tags to build against other DuckDB versions
1818
duckdb_version: [ '<submodule_version>' ]
19-
arch: ['linux_amd64_gcc4']
19+
arch: ['linux_amd64']
2020
vcpkg_version: [ '2023.04.15' ]
2121
include:
22-
- arch: 'linux_amd64_gcc4'
23-
container: 'quay.io/pypa/manylinux2014_x86_64'
22+
- arch: 'linux_amd64'
23+
container: 'quay.io/pypa/manylinux_2_28_x86_64'
2424
vcpkg_triplet: 'x64-linux'
2525

2626
env:
2727
VCPKG_TARGET_TRIPLET: ${{ matrix.vcpkg_triplet }}
2828
GEN: Ninja
2929
VCPKG_TOOLCHAIN_PATH: ${{ github.workspace }}/vcpkg/scripts/buildsystems/vcpkg.cmake
30-
ACTIONS_ALLOW_USE_UNSECURE_NODE_VERSION: true
3130

3231
steps:
3332
- name: Install required ubuntu packages
3433
if: ${{ matrix.arch == 'linux_amd64' || matrix.arch == 'linux_arm64' }}
3534
run: |
35+
export PATH=$PATH:/usr/bin/
36+
apt update
37+
apt install apt
3638
apt-get update -y -qq
3739
apt-get install -y -qq software-properties-common
3840
add-apt-repository ppa:git-core/ppa

.github/workflows/MainDistributionPipeline.yml

+2
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ jobs:
1717
uses: duckdb/extension-ci-tools/.github/workflows/_extension_distribution.yml@main
1818
with:
1919
duckdb_version: main
20+
ci_tools_version: main
2021
extension_name: postgres_scanner
2122
exclude_archs: 'wasm_mvp;wasm_eh;wasm_threads;windows_amd64_rtools'
2223

@@ -27,6 +28,7 @@ jobs:
2728
secrets: inherit
2829
with:
2930
duckdb_version: main
31+
ci_tools_version: main
3032
extension_name: postgres_scanner
3133
exclude_archs: 'wasm_mvp;wasm_eh;wasm_threads;windows_amd64_rtools'
3234
deploy_latest: ${{ startsWith(github.ref, 'refs/tags/v') || github.ref == 'refs/heads/main' }}

duckdb

Submodule duckdb updated 3241 files

src/postgres_scanner.cpp

+15-11
Original file line numberDiff line numberDiff line change
@@ -484,17 +484,21 @@ static void PostgresScan(ClientContext &context, TableFunctionInput &data, DataC
484484
local_state.ScanChunk(context, bind_data, gstate, output);
485485
}
486486

487-
static idx_t PostgresScanBatchIndex(ClientContext &context, const FunctionData *bind_data_p,
488-
LocalTableFunctionState *local_state_p, GlobalTableFunctionState *global_state) {
489-
auto &bind_data = bind_data_p->Cast<PostgresBindData>();
490-
auto &local_state = local_state_p->Cast<PostgresLocalState>();
491-
return local_state.batch_idx;
487+
static OperatorPartitionData PostgresGetPartitionData(ClientContext &context, TableFunctionGetPartitionInput &input) {
488+
if (input.partition_info.RequiresPartitionColumns()) {
489+
throw InternalException("PostgresScan::GetPartitionData: partition columns not supported");
490+
}
491+
auto &bind_data = input.bind_data->Cast<PostgresBindData>();
492+
auto &local_state = input.local_state->Cast<PostgresLocalState>();
493+
return OperatorPartitionData(local_state.batch_idx);
492494
}
493495

494-
static string PostgresScanToString(const FunctionData *bind_data_p) {
495-
D_ASSERT(bind_data_p);
496-
auto &bind_data = bind_data_p->Cast<PostgresBindData>();
497-
return bind_data.table_name;
496+
static InsertionOrderPreservingMap<string> PostgresScanToString(TableFunctionToStringInput &input) {
497+
D_ASSERT(input.bind_data);
498+
InsertionOrderPreservingMap<string> result;
499+
auto &bind_data = input.bind_data->Cast<PostgresBindData>();
500+
result["Table"] = bind_data.table_name;
501+
return result;
498502
}
499503

500504
unique_ptr<NodeStatistics> PostgresScanCardinality(ClientContext &context, const FunctionData *bind_data_p) {
@@ -538,7 +542,7 @@ PostgresScanFunction::PostgresScanFunction()
538542
to_string = PostgresScanToString;
539543
serialize = PostgresScanSerialize;
540544
deserialize = PostgresScanDeserialize;
541-
get_batch_index = PostgresScanBatchIndex;
545+
get_partition_data = PostgresGetPartitionData;
542546
cardinality = PostgresScanCardinality;
543547
table_scan_progress = PostgresScanProgress;
544548
projection_pushdown = true;
@@ -551,7 +555,7 @@ PostgresScanFunctionFilterPushdown::PostgresScanFunctionFilterPushdown()
551555
to_string = PostgresScanToString;
552556
serialize = PostgresScanSerialize;
553557
deserialize = PostgresScanDeserialize;
554-
get_batch_index = PostgresScanBatchIndex;
558+
get_partition_data = PostgresGetPartitionData;
555559
cardinality = PostgresScanCardinality;
556560
table_scan_progress = PostgresScanProgress;
557561
projection_pushdown = true;

0 commit comments

Comments
 (0)