PR changed-lines coverage: 81.67% (147/180, 1 noise lines excluded) Uncovered changed code (with context): ================================================================================ src/Functions/FunctionTopKFilter.cpp ================================================================================ --- uncovered block 50-50 --- 48 | 49 | bool isVariadic() const override { return false; } >> 50 | bool isInjective(const ColumnsWithTypeAndName &) const override { return false; } 51 | bool isSuitableForConstantFolding() const override { return false; } 52 | bool isSuitableForShortCircuitArgumentsExecution(const DataTypesWithConstInfo & /*arguments*/) const override { return false; } --- uncovered block 52-52 --- 50 | bool isInjective(const ColumnsWithTypeAndName &) const override { return false; } 51 | bool isSuitableForConstantFolding() const override { return false; } >> 52 | bool isSuitableForShortCircuitArgumentsExecution(const DataTypesWithConstInfo & /*arguments*/) const override { return false; } 53 | bool isDeterministic() const override { return false; } 54 | bool isDeterministicInScopeOfQuery() const override { return false; } --- uncovered block 61-65 --- 59 | { 60 | if (arguments.size() != 1) >> 61 | throw Exception( >> 62 | ErrorCodes::TOO_FEW_ARGUMENTS_FOR_FUNCTION, >> 63 | "Number of arguments for function {} can't be {}, should be 1", >> 64 | getName(), >> 65 | arguments.size()); 66 | 67 | return std::make_shared(); --- uncovered block 70-70 --- 68 | } 69 | >> 70 | DataTypePtr getReturnTypeForDefaultImplementationForDynamic() const override { return std::make_shared(); } 71 | 72 | bool useDefaultImplementationForConstants() const override { return true; } --- uncovered block 125-132 --- 123 | 124 | if (collator) >> 125 | { >> 126 | compare_results.resize(input_rows_count); >> 127 | for (size_t i = 0; i < input_rows_count; ++i) >> 128 | { >> 129 | int cmp = col.compareAtWithCollation(i, 0, *threshold_col, nulls_direction, *collator); >> 130 | compare_results[i] = static_cast(direction * cmp); >> 131 | } >> 132 | } 133 | else 134 | { ================================================================================ src/Processors/QueryPlan/ReadFromMergeTree.cpp ================================================================================ --- uncovered block 2058-2058 --- 2056 | if (top_k_filter_info->data_type->isNullable() 2057 | || !top_k_filter_info->data_type->isValueRepresentedByNumber()) >> 2058 | return false; 2059 | 2060 | if (top_k_filter_info->threshold_tracker --- uncovered block 2062-2062 --- 2060 | if (top_k_filter_info->threshold_tracker 2061 | && top_k_filter_info->threshold_tracker->getCollator()) >> 2062 | return false; 2063 | 2064 | return true; ================================================================================ src/Processors/TopKThresholdTracker.cpp ================================================================================ --- uncovered block 15-15 --- 13 | return 0; 14 | if (lhs_null) >> 15 | return sort_desc.nulls_direction; 16 | if (rhs_null) 17 | return -sort_desc.nulls_direction; --- uncovered block 17-17 --- 15 | return sort_desc.nulls_direction; 16 | if (rhs_null) >> 17 | return -sort_desc.nulls_direction; 18 | 19 | if (sort_desc.collator && lhs.getType() == Field::Types::String) --- uncovered block 20-24 --- 18 | 19 | if (sort_desc.collator && lhs.getType() == Field::Types::String) >> 20 | { >> 21 | const auto & l = lhs.safeGet(); >> 22 | const auto & r = rhs.safeGet(); >> 23 | return sort_desc.collator->compare(l.data(), l.size(), r.data(), r.size()); >> 24 | } 25 | 26 | if (lhs < rhs) ================================================================================ src/Processors/TopKThresholdTracker.h ================================================================================ --- uncovered block 36-36 --- 34 | { 35 | if (!is_set) >> 36 | return true; 37 | 38 | std::shared_lock lock(mutex); --- uncovered block 38-43 --- 36 | return true; 37 | >> 38 | std::shared_lock lock(mutex); >> 39 | int cmp = compareFields(value, threshold); >> 40 | if (sort_desc.direction == 1 && cmp > 0) >> 41 | return false; >> 42 | if (sort_desc.direction == -1 && cmp < 0) >> 43 | return false; 44 | 45 | return true; --- uncovered block 45-45 --- 43 | return false; 44 | >> 45 | return true; 46 | } 47 | WARNING: Failed to get start time for [Print Uncovered Code] - start time and duration won't be set