Skip to content

Commit 26072f3

Browse files
duckdblabs-botgithub-actions[bot]
authored andcommitted
Update vendored DuckDB sources to 30e907b52f
1 parent 1aa9faa commit 26072f3

38 files changed

+783
-196
lines changed

CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Large diffs are not rendered by default.

src/duckdb/extension/core_functions/include/core_functions/scalar/string_functions.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ struct FormatFun {
100100
struct FormatBytesFun {
101101
static constexpr const char *Name = "format_bytes";
102102
static constexpr const char *Parameters = "bytes";
103-
static constexpr const char *Description = "Converts bytes to a human-readable presentation (e.g. 16000 -> 15.6 KiB)";
103+
static constexpr const char *Description = "Converts bytes to a human-readable presentation (e.g., 16000 -> 15.6 KiB)";
104104
static constexpr const char *Example = "format_bytes(1000 * 16)";
105105
static constexpr const char *Categories = "";
106106

@@ -116,7 +116,7 @@ struct FormatreadablesizeFun {
116116
struct FormatreadabledecimalsizeFun {
117117
static constexpr const char *Name = "formatReadableDecimalSize";
118118
static constexpr const char *Parameters = "bytes";
119-
static constexpr const char *Description = "Converts bytes to a human-readable presentation (e.g. 16000 -> 16.0 KB)";
119+
static constexpr const char *Description = "Converts bytes to a human-readable presentation (e.g., 16000 -> 16.0 KB)";
120120
static constexpr const char *Example = "format_bytes(1000 * 16)";
121121
static constexpr const char *Categories = "";
122122

src/duckdb/extension/json/json_functions/read_json.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -132,6 +132,10 @@ class JSONSchemaTask : public BaseExecutorTask {
132132
}
133133
}
134134

135+
string TaskType() const override {
136+
return "JSONSchemaTask";
137+
}
138+
135139
private:
136140
AutoDetectState &auto_detect_state;
137141
JSONStructureNode &node;

src/duckdb/src/catalog/catalog_entry/duck_schema_entry.cpp

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -68,11 +68,14 @@ static void FindForeignKeyInformation(TableCatalogEntry &table, AlterForeignKeyT
6868
}
6969

7070
DuckSchemaEntry::DuckSchemaEntry(Catalog &catalog, CreateSchemaInfo &info)
71-
: SchemaCatalogEntry(catalog, info), tables(catalog, make_uniq<DefaultViewGenerator>(catalog, *this)),
72-
indexes(catalog), table_functions(catalog, make_uniq<DefaultTableFunctionGenerator>(catalog, *this)),
71+
: SchemaCatalogEntry(catalog, info),
72+
tables(catalog, catalog.IsSystemCatalog() ? make_uniq<DefaultViewGenerator>(catalog, *this) : nullptr),
73+
indexes(catalog),
74+
table_functions(catalog,
75+
catalog.IsSystemCatalog() ? make_uniq<DefaultTableFunctionGenerator>(catalog, *this) : nullptr),
7376
copy_functions(catalog), pragma_functions(catalog),
74-
functions(catalog, make_uniq<DefaultFunctionGenerator>(catalog, *this)), sequences(catalog), collations(catalog),
75-
types(catalog, make_uniq<DefaultTypeGenerator>(catalog, *this)) {
77+
functions(catalog, catalog.IsSystemCatalog() ? make_uniq<DefaultFunctionGenerator>(catalog, *this) : nullptr),
78+
sequences(catalog), collations(catalog), types(catalog, make_uniq<DefaultTypeGenerator>(catalog, *this)) {
7679
}
7780

7881
unique_ptr<CatalogEntry> DuckSchemaEntry::Copy(ClientContext &context) const {

src/duckdb/src/common/enum_util.cpp

Lines changed: 81 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,7 @@
6868
#include "duckdb/common/file_buffer.hpp"
6969
#include "duckdb/common/file_open_flags.hpp"
7070
#include "duckdb/common/filename_pattern.hpp"
71+
#include "duckdb/common/http_util.hpp"
7172
#include "duckdb/common/multi_file/multi_file_data.hpp"
7273
#include "duckdb/common/multi_file/multi_file_list.hpp"
7374
#include "duckdb/common/multi_file/multi_file_options.hpp"
@@ -1976,6 +1977,86 @@ HLLStorageType EnumUtil::FromString<HLLStorageType>(const char *value) {
19761977
return static_cast<HLLStorageType>(StringUtil::StringToEnum(GetHLLStorageTypeValues(), 2, "HLLStorageType", value));
19771978
}
19781979

1980+
const StringUtil::EnumStringLiteral *GetHTTPStatusCodeValues() {
1981+
static constexpr StringUtil::EnumStringLiteral values[] {
1982+
{ static_cast<uint32_t>(HTTPStatusCode::INVALID), "INVALID" },
1983+
{ static_cast<uint32_t>(HTTPStatusCode::Continue_100), "Continue_100" },
1984+
{ static_cast<uint32_t>(HTTPStatusCode::SwitchingProtocol_101), "SwitchingProtocol_101" },
1985+
{ static_cast<uint32_t>(HTTPStatusCode::Processing_102), "Processing_102" },
1986+
{ static_cast<uint32_t>(HTTPStatusCode::EarlyHints_103), "EarlyHints_103" },
1987+
{ static_cast<uint32_t>(HTTPStatusCode::OK_200), "OK_200" },
1988+
{ static_cast<uint32_t>(HTTPStatusCode::Created_201), "Created_201" },
1989+
{ static_cast<uint32_t>(HTTPStatusCode::Accepted_202), "Accepted_202" },
1990+
{ static_cast<uint32_t>(HTTPStatusCode::NonAuthoritativeInformation_203), "NonAuthoritativeInformation_203" },
1991+
{ static_cast<uint32_t>(HTTPStatusCode::NoContent_204), "NoContent_204" },
1992+
{ static_cast<uint32_t>(HTTPStatusCode::ResetContent_205), "ResetContent_205" },
1993+
{ static_cast<uint32_t>(HTTPStatusCode::PartialContent_206), "PartialContent_206" },
1994+
{ static_cast<uint32_t>(HTTPStatusCode::MultiStatus_207), "MultiStatus_207" },
1995+
{ static_cast<uint32_t>(HTTPStatusCode::AlreadyReported_208), "AlreadyReported_208" },
1996+
{ static_cast<uint32_t>(HTTPStatusCode::IMUsed_226), "IMUsed_226" },
1997+
{ static_cast<uint32_t>(HTTPStatusCode::MultipleChoices_300), "MultipleChoices_300" },
1998+
{ static_cast<uint32_t>(HTTPStatusCode::MovedPermanently_301), "MovedPermanently_301" },
1999+
{ static_cast<uint32_t>(HTTPStatusCode::Found_302), "Found_302" },
2000+
{ static_cast<uint32_t>(HTTPStatusCode::SeeOther_303), "SeeOther_303" },
2001+
{ static_cast<uint32_t>(HTTPStatusCode::NotModified_304), "NotModified_304" },
2002+
{ static_cast<uint32_t>(HTTPStatusCode::UseProxy_305), "UseProxy_305" },
2003+
{ static_cast<uint32_t>(HTTPStatusCode::unused_306), "unused_306" },
2004+
{ static_cast<uint32_t>(HTTPStatusCode::TemporaryRedirect_307), "TemporaryRedirect_307" },
2005+
{ static_cast<uint32_t>(HTTPStatusCode::PermanentRedirect_308), "PermanentRedirect_308" },
2006+
{ static_cast<uint32_t>(HTTPStatusCode::BadRequest_400), "BadRequest_400" },
2007+
{ static_cast<uint32_t>(HTTPStatusCode::Unauthorized_401), "Unauthorized_401" },
2008+
{ static_cast<uint32_t>(HTTPStatusCode::PaymentRequired_402), "PaymentRequired_402" },
2009+
{ static_cast<uint32_t>(HTTPStatusCode::Forbidden_403), "Forbidden_403" },
2010+
{ static_cast<uint32_t>(HTTPStatusCode::NotFound_404), "NotFound_404" },
2011+
{ static_cast<uint32_t>(HTTPStatusCode::MethodNotAllowed_405), "MethodNotAllowed_405" },
2012+
{ static_cast<uint32_t>(HTTPStatusCode::NotAcceptable_406), "NotAcceptable_406" },
2013+
{ static_cast<uint32_t>(HTTPStatusCode::ProxyAuthenticationRequired_407), "ProxyAuthenticationRequired_407" },
2014+
{ static_cast<uint32_t>(HTTPStatusCode::RequestTimeout_408), "RequestTimeout_408" },
2015+
{ static_cast<uint32_t>(HTTPStatusCode::Conflict_409), "Conflict_409" },
2016+
{ static_cast<uint32_t>(HTTPStatusCode::Gone_410), "Gone_410" },
2017+
{ static_cast<uint32_t>(HTTPStatusCode::LengthRequired_411), "LengthRequired_411" },
2018+
{ static_cast<uint32_t>(HTTPStatusCode::PreconditionFailed_412), "PreconditionFailed_412" },
2019+
{ static_cast<uint32_t>(HTTPStatusCode::PayloadTooLarge_413), "PayloadTooLarge_413" },
2020+
{ static_cast<uint32_t>(HTTPStatusCode::UriTooLong_414), "UriTooLong_414" },
2021+
{ static_cast<uint32_t>(HTTPStatusCode::UnsupportedMediaType_415), "UnsupportedMediaType_415" },
2022+
{ static_cast<uint32_t>(HTTPStatusCode::RangeNotSatisfiable_416), "RangeNotSatisfiable_416" },
2023+
{ static_cast<uint32_t>(HTTPStatusCode::ExpectationFailed_417), "ExpectationFailed_417" },
2024+
{ static_cast<uint32_t>(HTTPStatusCode::ImATeapot_418), "ImATeapot_418" },
2025+
{ static_cast<uint32_t>(HTTPStatusCode::MisdirectedRequest_421), "MisdirectedRequest_421" },
2026+
{ static_cast<uint32_t>(HTTPStatusCode::UnprocessableContent_422), "UnprocessableContent_422" },
2027+
{ static_cast<uint32_t>(HTTPStatusCode::Locked_423), "Locked_423" },
2028+
{ static_cast<uint32_t>(HTTPStatusCode::FailedDependency_424), "FailedDependency_424" },
2029+
{ static_cast<uint32_t>(HTTPStatusCode::TooEarly_425), "TooEarly_425" },
2030+
{ static_cast<uint32_t>(HTTPStatusCode::UpgradeRequired_426), "UpgradeRequired_426" },
2031+
{ static_cast<uint32_t>(HTTPStatusCode::PreconditionRequired_428), "PreconditionRequired_428" },
2032+
{ static_cast<uint32_t>(HTTPStatusCode::TooManyRequests_429), "TooManyRequests_429" },
2033+
{ static_cast<uint32_t>(HTTPStatusCode::RequestHeaderFieldsTooLarge_431), "RequestHeaderFieldsTooLarge_431" },
2034+
{ static_cast<uint32_t>(HTTPStatusCode::UnavailableForLegalReasons_451), "UnavailableForLegalReasons_451" },
2035+
{ static_cast<uint32_t>(HTTPStatusCode::InternalServerError_500), "InternalServerError_500" },
2036+
{ static_cast<uint32_t>(HTTPStatusCode::NotImplemented_501), "NotImplemented_501" },
2037+
{ static_cast<uint32_t>(HTTPStatusCode::BadGateway_502), "BadGateway_502" },
2038+
{ static_cast<uint32_t>(HTTPStatusCode::ServiceUnavailable_503), "ServiceUnavailable_503" },
2039+
{ static_cast<uint32_t>(HTTPStatusCode::GatewayTimeout_504), "GatewayTimeout_504" },
2040+
{ static_cast<uint32_t>(HTTPStatusCode::HttpVersionNotSupported_505), "HttpVersionNotSupported_505" },
2041+
{ static_cast<uint32_t>(HTTPStatusCode::VariantAlsoNegotiates_506), "VariantAlsoNegotiates_506" },
2042+
{ static_cast<uint32_t>(HTTPStatusCode::InsufficientStorage_507), "InsufficientStorage_507" },
2043+
{ static_cast<uint32_t>(HTTPStatusCode::LoopDetected_508), "LoopDetected_508" },
2044+
{ static_cast<uint32_t>(HTTPStatusCode::NotExtended_510), "NotExtended_510" },
2045+
{ static_cast<uint32_t>(HTTPStatusCode::NetworkAuthenticationRequired_511), "NetworkAuthenticationRequired_511" }
2046+
};
2047+
return values;
2048+
}
2049+
2050+
template<>
2051+
const char* EnumUtil::ToChars<HTTPStatusCode>(HTTPStatusCode value) {
2052+
return StringUtil::EnumToString(GetHTTPStatusCodeValues(), 64, "HTTPStatusCode", static_cast<uint32_t>(value));
2053+
}
2054+
2055+
template<>
2056+
HTTPStatusCode EnumUtil::FromString<HTTPStatusCode>(const char *value) {
2057+
return static_cast<HTTPStatusCode>(StringUtil::StringToEnum(GetHTTPStatusCodeValues(), 64, "HTTPStatusCode", value));
2058+
}
2059+
19792060
const StringUtil::EnumStringLiteral *GetIndexAppendModeValues() {
19802061
static constexpr StringUtil::EnumStringLiteral values[] {
19812062
{ static_cast<uint32_t>(IndexAppendMode::DEFAULT), "DEFAULT" },

src/duckdb/src/common/http_util.cpp

Lines changed: 0 additions & 29 deletions
This file was deleted.

src/duckdb/src/common/sort/partition_state.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -581,6 +581,10 @@ class PartitionMergeTask : public ExecutorTask {
581581

582582
TaskExecutionResult ExecuteTask(TaskExecutionMode mode) override;
583583

584+
string TaskType() const override {
585+
return "PartitionMergeTask";
586+
}
587+
584588
private:
585589
struct ExecutorCallback : public PartitionGlobalMergeStates::Callback {
586590
explicit ExecutorCallback(Executor &executor) : executor(executor) {

src/duckdb/src/execution/operator/aggregate/physical_hash_aggregate.cpp

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -488,6 +488,10 @@ class HashAggregateFinalizeTask : public ExecutorTask {
488488
public:
489489
TaskExecutionResult ExecuteTask(TaskExecutionMode mode) override;
490490

491+
string TaskType() const override {
492+
return "HashAggregateFinalizeTask";
493+
}
494+
491495
private:
492496
ClientContext &context;
493497
Pipeline &pipeline;
@@ -547,6 +551,10 @@ class HashAggregateDistinctFinalizeTask : public ExecutorTask {
547551
public:
548552
TaskExecutionResult ExecuteTask(TaskExecutionMode mode) override;
549553

554+
string TaskType() const override {
555+
return "HashAggregateDistinctFinalizeTask";
556+
}
557+
550558
private:
551559
TaskExecutionResult AggregateDistinctGrouping(const idx_t grouping_idx);
552560

src/duckdb/src/execution/operator/aggregate/physical_ungrouped_aggregate.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -445,6 +445,10 @@ class UngroupedDistinctAggregateFinalizeTask : public ExecutorTask {
445445

446446
TaskExecutionResult ExecuteTask(TaskExecutionMode mode) override;
447447

448+
string TaskType() const override {
449+
return "UngroupedDistinctAggregateFinalizeTask";
450+
}
451+
448452
private:
449453
TaskExecutionResult AggregateDistinct();
450454

src/duckdb/src/execution/operator/csv_scanner/util/csv_error.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -330,10 +330,10 @@ CSVError CSVError::CastError(const CSVReaderOptions &options, const string &colu
330330
if (!options.WasTypeManuallySet(column_idx)) {
331331
how_to_fix_it << "This type was auto-detected from the CSV file." << '\n';
332332
how_to_fix_it << "Possible solutions:" << '\n';
333-
how_to_fix_it << "* Override the type for this column manually by setting the type explicitly, e.g. types={'"
333+
how_to_fix_it << "* Override the type for this column manually by setting the type explicitly, e.g., types={'"
334334
<< column_name << "': 'VARCHAR'}" << '\n';
335335
how_to_fix_it
336-
<< "* Set the sample size to a larger value to enable the auto-detection to scan more values, e.g. "
336+
<< "* Set the sample size to a larger value to enable the auto-detection to scan more values, e.g., "
337337
"sample_size=-1"
338338
<< '\n';
339339
how_to_fix_it << "* Use a COPY statement to automatically derive types from an existing table." << '\n';

src/duckdb/src/execution/operator/join/physical_hash_join.cpp

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -469,6 +469,10 @@ class HashJoinTableInitTask : public ExecutorTask {
469469
return TaskExecutionResult::TASK_FINISHED;
470470
}
471471

472+
string TaskType() const override {
473+
return "HashJoinTableInitTask";
474+
}
475+
472476
private:
473477
HashJoinGlobalSinkState &sink;
474478
idx_t entry_idx_from;
@@ -524,6 +528,9 @@ class HashJoinFinalizeTask : public ExecutorTask {
524528
event->FinishTask();
525529
return TaskExecutionResult::TASK_FINISHED;
526530
}
531+
string TaskType() const override {
532+
return "HashJoinFinalizeTask";
533+
}
527534

528535
private:
529536
HashJoinGlobalSinkState &sink;
@@ -607,6 +614,10 @@ class HashJoinRepartitionTask : public ExecutorTask {
607614
return TaskExecutionResult::TASK_FINISHED;
608615
}
609616

617+
string TaskType() const override {
618+
return "HashJoinRepartitionTask";
619+
}
620+
610621
private:
611622
JoinHashTable &global_ht;
612623
JoinHashTable &local_ht;

0 commit comments

Comments
 (0)