citusdata / citus

Distributed PostgreSQL as an extension
https://www.citusdata.com
GNU Affero General Public License v3.0
10.43k stars 662 forks source link

Regression Testing #5988

Open TsinghuaLucky912 opened 2 years ago

TsinghuaLucky912 commented 2 years ago

Version

pg14.1+citus v10.2.5

Environment

[postgres@VM-24-14-centos:~/other/postgres/contrib/citus → v10.2.5]$ 
[postgres@VM-24-14-centos:~/other/postgres/contrib/citus → v10.2.5]$ export LC_COLLATE="C" 
[postgres@VM-24-14-centos:~/other/postgres/contrib/citus → v10.2.5]$ 
[postgres@VM-24-14-centos:~/other/postgres/contrib/citus → v10.2.5]$ export LANG="en_US.UTF-8"
[postgres@VM-24-14-centos:~/other/postgres/contrib/citus → v10.2.5]$ 
[postgres@VM-24-14-centos:~/other/postgres/contrib/citus → v10.2.5]$ mitmdump --version
Mitmproxy: 5.3.0
Python:    3.6.8
OpenSSL:   OpenSSL 1.1.1k  FIPS 25 Mar 2021
Platform:  Linux-4.18.0-305.3.1.el8.x86_64-x86_64-with-centos-8.2.2004-Core
[postgres@VM-24-14-centos:~/other/postgres/contrib/citus → v10.2.5]$ 
[postgres@VM-24-14-centos:~/other/postgres/contrib/citus → v10.2.5]$ mitmproxy --version
Mitmproxy: 5.3.0
Python:    3.6.8
OpenSSL:   OpenSSL 1.1.1k  FIPS 25 Mar 2021
Platform:  Linux-4.18.0-305.3.1.el8.x86_64-x86_64-with-centos-8.2.2004-Core
[postgres@VM-24-14-centos:~/other/postgres/contrib/citus → v10.2.5]$ whereis mitmdump
mitmdump: /usr/local/bin/mitmdump
[postgres@VM-24-14-centos:~/other/postgres/contrib/citus → v10.2.5]$
[postgres@VM-24-14-centos:~/other/postgres/contrib/citus → v10.2.5]$ pg_config --version
PostgreSQL 14.1
[postgres@VM-24-14-centos:~/other/postgres/contrib/citus → v10.2.5]$

Error

check-failure,the error is as follows:

============== installing citus                       ==============
CREATE EXTENSION
============== running regression test queries        ==============
test failure_test_helpers         ... ok           35 ms
test failure_setup                   ...    // I am here (stuck here)

I don't know how to pass this schedule,or is this a problem?

SaitTalhaNisanci commented 2 years ago

check-failure target is run in a slightly different way(in a virtual env), have you followed these steps to run it? https://github.com/citusdata/citus/blob/master/src/test/regress/mitmscripts/README.md#getting-started

TsinghuaLucky912 commented 2 years ago

Hello, I tried your document but it didn't work, the following is the result of the test:

360截图20220606144744860 360截图20220606144712558

TsinghuaLucky912 commented 2 years ago

Still stuck here, same as before

360截图20220606145653861

thanodnl commented 2 years ago

to be honest, the failure testing are hard to run locally. Any reason you are on the 10.2.x branch?

A while ago there was a security issue with mitmproxy, a tool we use for the failure tests. Since we were running a very old version we actually ran into a breaking change to mitmproxy while mitigating the security issue in mitmproxy. To work around this, while mitm proxy would redesign the API's we were using they suggested to use out hacky patch in a forked version. These changes haven't been backported to this older branch.

From my recollection it was pretty hard to install the older dependencies in a correct manner. If you could change to the master branch you might have better chances of succeeding. In any case. do make sure that you install the pipenv from the checkout for which you want to run the tests.

The blocking behaviour does look like the issue we fixed in our custom fork of mitmproxy.


That said, I am wondering for the rationale to run the failure tests locally? Could you share your use-case with us?

TsinghuaLucky912 commented 2 years ago

Hi, thank you very much for answering this question in your busy schedule. I use citus mainly for our high availability solution selection

I tried to compile and install myself and perform regression tests to check the stability of citus. The result was stuck when make check. I don't know how to solve this. I tried the solutions on the network and the official documents of citus did not solve this. question