Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Randomize more settings #39663

Merged
merged 20 commits into from Dec 19, 2023

Conversation

CurtizJ
Copy link
Member

@CurtizJ CurtizJ commented Jul 27, 2022

Changelog category (leave one):

  • Not for changelog (changelog entry is not required)

@robot-clickhouse robot-clickhouse added the pr-not-for-changelog This PR should not be mentioned in the changelog label Jul 27, 2022
@CurtizJ
Copy link
Member Author

CurtizJ commented Jul 27, 2022

#39667.

return (
lambda: 0
if random.random() < 0.5
else 1
Copy link
Member

@nickitat nickitat Jul 28, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i'm afraid that it may slow down some tests significantly. have you checked?

@nickitat nickitat self-assigned this Jul 28, 2022
@alexey-milovidov alexey-milovidov self-assigned this Feb 3, 2023
@alexey-milovidov
Copy link
Member

alexey-milovidov commented Feb 16, 2023

@CurtizJ, this is so good pull request; let's continue!

@alexey-milovidov
Copy link
Member

We have faced a bug on GitHub.
GitHub can reset file mode, dropping the executable flag.

@alexey-milovidov
Copy link
Member

@CurtizJ This is so wonderful, let's continue!

@robot-clickhouse-ci-2
Copy link
Contributor

robot-clickhouse-ci-2 commented May 6, 2023

This is an automated comment for commit dbabaeb with description of existing statuses. It's updated for the latest CI running

❌ Click here to open a full report in a separate page

Successful checks
Check nameDescriptionStatus
AST fuzzerRuns randomly generated queries to catch program errors. The build type is optionally given in parenthesis. If it fails, ask a maintainer for help✅ success
ClickBenchRuns [ClickBench](https://github.com/ClickHouse/ClickBench/) with instant-attach table✅ success
ClickHouse build checkBuilds ClickHouse in various configurations for use in further steps. You have to fix the builds that fail. Build logs often has enough information to fix the error, but you might have to reproduce the failure locally. The cmake options can be found in the build log, grepping for cmake. Use these options and follow the general build process✅ success
Compatibility checkChecks that clickhouse binary runs on distributions with old libc versions. If it fails, ask a maintainer for help✅ success
Docker server and keeper imagesThere's no description for the check yet, please add it to tests/ci/ci_config.py:CHECK_DESCRIPTIONS✅ success
Docs checkThere's no description for the check yet, please add it to tests/ci/ci_config.py:CHECK_DESCRIPTIONS✅ success
Fast testNormally this is the first check that is ran for a PR. It builds ClickHouse and runs most of stateless functional tests, omitting some. If it fails, further checks are not started until it is fixed. Look at the report to see which tests fail, then reproduce the failure locally as described here✅ success
Install packagesChecks that the built packages are installable in a clear environment✅ success
Mergeable CheckChecks if all other necessary checks are successful✅ success
Performance ComparisonMeasure changes in query performance. The performance test report is described in detail here. In square brackets are the optional part/total tests✅ success
SQLTestThere's no description for the check yet, please add it to tests/ci/ci_config.py:CHECK_DESCRIPTIONS✅ success
SQLancerFuzzing tests that detect logical bugs with SQLancer tool✅ success
SqllogicRun clickhouse on the sqllogic test set against sqlite and checks that all statements are passed✅ success
Style CheckRuns a set of checks to keep the code style clean. If some of tests failed, see the related log from the report✅ success
Unit testsRuns the unit tests for different release types✅ success
Check nameDescriptionStatus
CI runningA meta-check that indicates the running CI. Normally, it's in success or pending state. The failed status indicates some problems with the PR⏳ pending
Flaky testsChecks if new added or modified tests are flaky by running them repeatedly, in parallel, with more randomization. Functional tests are run 100 times with address sanitizer, and additional randomization of thread scheduling. Integrational tests are run up to 10 times. If at least once a new test has failed, or was too long, this check will be red. We don't allow flaky tests, read the doc❌ failure
Integration testsThe integration tests report. In parenthesis the package type is given, and in square brackets are the optional part/total tests❌ failure
Stateful testsRuns stateful functional tests for ClickHouse binaries built in various configurations -- release, debug, with sanitizers, etc❌ failure
Stateless testsRuns stateless functional tests for ClickHouse binaries built in various configurations -- release, debug, with sanitizers, etc❌ failure
Stress testRuns stateless functional tests concurrently from several clients to detect concurrency-related errors❌ failure
Upgrade checkRuns stress tests on server version from last release and then tries to upgrade it to the version from the PR. It checks if the new server can successfully startup without any errors, crashes or sanitizer asserts❌ failure

@alexey-milovidov
Copy link
Member

We need this.

@alexey-milovidov
Copy link
Member

@CurtizJ, We still need this.

@alexey-milovidov
Copy link
Member

We need this.

@alexey-milovidov
Copy link
Member

@CurtizJ We need this PR to be merged.

@alexey-milovidov
Copy link
Member

@CurtizJ This PR makes sense.

@alexey-milovidov
Copy link
Member

How nice it is.

@alexey-milovidov
Copy link
Member

@CurtizJ We need this.

@alexey-milovidov
Copy link
Member

This pull request is good to continue.

@alexey-milovidov
Copy link
Member

This is a good pull request - let's continue.

@alexey-milovidov
Copy link
Member

We need this pull request to be merged.

@alexey-milovidov
Copy link
Member

@CurtizJ, please continue 😸

@CurtizJ
Copy link
Member Author

CurtizJ commented Dec 8, 2023

Current (not complete) list of failed tests:

02480_max_map_null_totals
01244_optimize_distributed_group_by_sharding_key
01064_incremental_streaming_from_2_src_with_feedback
01514_distributed_cancel_query_on_error
02352_rwlock
02178_column_function_insert_from
01134_max_rows_to_group_by
00184_shard_distributed_group_by_no_merge
01710_projections_partial_optimize_aggregation_in_order
01563_distributed_query_finish
01710_aggregate_projections
02496_remove_redundant_sorting
01513_optimize_aggregation_in_order_memory_long
02500_remove_redundant_distinct
02500_remove_redundant_distinct_analyzer
02496_remove_redundant_sorting_analyzer
01472_many_rows_in_totals
01591_window_functions
02427_column_nullable_ubsan
02479_race_condition_between_insert_and_droppin_mv	

@CurtizJ
Copy link
Member Author

CurtizJ commented Dec 8, 2023

02480_max_map_null_totals - #57686

@CurtizJ
Copy link
Member Author

CurtizJ commented Dec 8, 2023

02178_column_function_insert_from - #57688

@CurtizJ
Copy link
Member Author

CurtizJ commented Dec 8, 2023

01710_projections_partial_optimize_aggregation_in_order - #57692

@CurtizJ
Copy link
Member Author

CurtizJ commented Dec 13, 2023

01291_distributed_low_cardinality_memory_efficient - #57814.

@CurtizJ
Copy link
Member Author

CurtizJ commented Dec 13, 2023

So I found 4 real issues in this PR: #57686, #57688, #57692, #57814

Two of them (#57686 and #57692) are fixed in #57795 and #57790.

#57688 is closed with won't fix resolution because it is fixed with new analyzer.

#57814 looks a bit weird. Probably should be closed with won't fix unless the more real scenario will be provided.

@CurtizJ
Copy link
Member Author

CurtizJ commented Dec 16, 2023

Last failing test:

02274_full_sort_join_nodistinct

2023-12-14 09:58:47 [6b3bb7ac6f8c] 2023.12.14 09:58:47.700559 [ 2600 ] {c955c4e1-82d4-474e-bec2-77bdd0cbbeff} <Error> executeQuery: std::exception. Code: 1001, type: std::__1::__fs::filesystem::filesystem_error, e.what() = filesystem error: in create_directories: No such file or directory ["/var/lib/clickhouse/caches/cached_s3/969/969b1806ff4241db78e954e0cd3840c0"]
2023-12-14 09:58:47 Cannot print extra info for Poco::Exception (version 23.12.1.594) (from [::1]:50854) (comment: 02274_full_sort_join_nodistinct.gen.sql) (in query: SELECT t1.key, t2.key, t1.s, length(t2.s) FROM tn1 AS t1 ALL LEFT JOIN tn2 AS t2 ON t1.key == t2.key ORDER BY t1.key, t2.key, t1.s;), Stack trace (when copying this message, always include the lines below):
2023-12-14 09:58:47 
2023-12-14 09:58:47 0. ./contrib/llvm-project/libcxx/include/string:1499: std::system_error::system_error(std::error_code, String const&) @ 0x0000000016ad8615 in /usr/lib/debug/usr/bin/clickhouse.debug
2023-12-14 09:58:47 1. ./contrib/llvm-project/libcxx/include/__filesystem/filesystem_error.h:42: std::__fs::filesystem::filesystem_error::filesystem_error[abi:v15000](String const&, std::__fs::filesystem::path const&, std::error_code) @ 0x000000000c597901 in /usr/lib/debug/usr/bin/clickhouse.debug
2023-12-14 09:58:47 2. ./contrib/llvm-project/libcxx/include/__filesystem/filesystem_error.h:90: void std::__fs::filesystem::__throw_filesystem_error[abi:v15000]<String&, std::__fs::filesystem::path const&, std::error_code const&>(String&, std::__fs::filesystem::path const&, std::error_code const&) @ 0x0000000016a8f01a in /usr/lib/debug/usr/bin/clickhouse.debug
2023-12-14 09:58:47 3. ./contrib/llvm-project/libcxx/src/filesystem/filesystem_common.h:0: std::__fs::filesystem::detail::(anonymous namespace)::ErrorHandler<bool>::report(std::error_code const&) const (.llvm.14483552974555787744) @ 0x0000000016a92376 in /usr/lib/debug/usr/bin/clickhouse.debug
2023-12-14 09:58:47 4. ./build_docker/./contrib/llvm-project/libcxx/src/filesystem/operations.cpp:0: std::__fs::filesystem::__create_directories(std::__fs::filesystem::path const&, std::error_code*) @ 0x0000000016a92b79 in /usr/lib/debug/usr/bin/clickhouse.debug
2023-12-14 09:58:47 5. ./contrib/llvm-project/libcxx/include/string:1499: DB::TemporaryDataOnDisk::createCacheFile(unsigned long) @ 0x00000000112ef13a in /usr/lib/debug/usr/bin/clickhouse.debug
2023-12-14 09:58:47 6. ./build_docker/./src/Interpreters/TemporaryDataOnDisk.cpp:83: DB::TemporaryDataOnDisk::createStream(DB::Block const&, unsigned long) @ 0x00000000112ef572 in /usr/lib/debug/usr/bin/clickhouse.debug
2023-12-14 09:58:47 7. ./build_docker/./src/Processors/Transforms/MergeSortingTransform.cpp:171: DB::MergeSortingTransform::consume(DB::Chunk) @ 0x00000000125e3e09 in /usr/lib/debug/usr/bin/clickhouse.debug
2023-12-14 09:58:47 8. ./contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:701: DB::SortingTransform::work() @ 0x00000000125fa444 in /usr/lib/debug/usr/bin/clickhouse.debug
2023-12-14 09:58:47 9. ./build_docker/./src/Processors/Executors/ExecutionThreadContext.cpp:0: DB::ExecutionThreadContext::executeTask() @ 0x000000001235335a in /usr/lib/debug/usr/bin/clickhouse.debug
2023-12-14 09:58:47 10. ./build_docker/./src/Processors/Executors/PipelineExecutor.cpp:273: DB::PipelineExecutor::executeStepImpl(unsigned long, std::atomic<bool>*) @ 0x000000001234a070 in /usr/lib/debug/usr/bin/clickhouse.debug
2023-12-14 09:58:47 11. ./contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:833: void std::__function::__policy_invoker<void ()>::__call_impl<std::__function::__default_alloc_func<DB::PipelineExecutor::spawnThreads()::$_0, void ()>>(std::__function::__policy_storage const*) @ 0x000000001234b0ef in /usr/lib/debug/usr/bin/clickhouse.debug
2023-12-14 09:58:47 12. ./base/base/../base/wide_integer_impl.h:809: ThreadPoolImpl<ThreadFromGlobalPoolImpl<false>>::worker(std::__list_iterator<ThreadFromGlobalPoolImpl<false>, void*>) @ 0x000000000c631670 in /usr/lib/debug/usr/bin/clickhouse.debug
2023-12-14 09:58:47 13. ./build_docker/./src/Common/ThreadPool.cpp:0: void std::

@CurtizJ
Copy link
Member Author

CurtizJ commented Dec 18, 2023

02274_full_sort_join_nodistinct is fixed in #58013.

@CurtizJ
Copy link
Member Author

CurtizJ commented Dec 19, 2023

Tests look ok except 00155_long_merges in flaky check, but I think it won't pass even on master with parallel run.

@CurtizJ
Copy link
Member Author

CurtizJ commented Dec 19, 2023

Anyway there will be some new flaky tests.

@alexey-milovidov alexey-milovidov merged commit bd5675f into ClickHouse:master Dec 19, 2023
252 of 262 checks passed
nickitat added a commit that referenced this pull request Feb 1, 2024
It became flaky after we merged #39663. When external aggregation happens it seems like we get more than one part, and because we used `OPTIMIZE` without `FINAL` data wasn't properly merged.
`order by` on the line 12 is not needed by now, but let's add it just in case.
Algunenano pushed a commit to Algunenano/ClickHouse that referenced this pull request Feb 6, 2024
It became flaky after we merged ClickHouse#39663. When external aggregation happens it seems like we get more than one part, and because we used `OPTIMIZE` without `FINAL` data wasn't properly merged.
`order by` on the line 12 is not needed by now, but let's add it just in case.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pr-not-for-changelog This PR should not be mentioned in the changelog
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants