Code Monkey home page Code Monkey logo

pytest-cloud's People

Contributors

bubenkoff avatar dasm avatar hah86 avatar hpk42 avatar movermeyer avatar olegpidsadnyi avatar orthographic-pedant avatar pelme avatar ronnypfannschmidt avatar zac-hd avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

pytest-cloud's Issues

pytest-cloud is not working with pytest-xdist>1.25.0

pytest-xdist introduced breaking change to pytest-cloud with the release of 1.26.0 version change request

(venv2) ➜  utils git:(master) ✗ pytest test_name.py --cloud-node=hostname --cloud-python=python2 -s
Detected root dir: /apps/utils
Detecting connectable test nodes...
Found 1 connectable test nodes: set(['hostname'])
RSyncing directory structure
rsync: -arHAXx: unknown option
rsync error: syntax or usage error (code 1) at /AppleInternal/BuildRoot/Library/Caches/com.apple.xbs/Sources/rsync/rsync-54/rsync/main.c(1337) [client=2.6.9]
RSync finished
Scheduling with 12 parallel test sessions
============================================================================================================================= test session starts ==============================================================================================================================
platform darwin -- Python 2.7.17, pytest-4.6.9, py-1.8.1, pluggy-0.13.1
rootdir: /Users/dsmigiel/apps/dcp-test-utils, inifile: pytest.ini
plugins: timeout-1.3.4, ansible-playbook-0.4.1, xdist-1.31.0, forked-1.1.3, metadata-1.8.0, json-report-1.2.1, cloud-3.0.1
timeout: 600.0s
timeout method: signal
timeout func_only: False
hostname_0 C / (...) / hostname_11 C[hostname_0] node down: Traceback (most recent call last):
  File "<string>", line 1084, in executetask
  File "<string>", line 1, in do_exec
  File "/apps/utils/venv2/lib/python2.7/site-packages/xdist/remote.py", line 232, in <module>
ValueError: need more than 3 values to unpack

After downgrading to xdist-1.25.0

(venv2) ➜  utils git:(master) ✗ pytest test_name.py --cloud-node=hostname --cloud-python=python2
Detected root dir: /apps/utils
Detecting connectable test nodes...
Found 1 connectable test nodes: set(['hostname'])
RSyncing directory structure
rsync: -arHAXx: unknown option
rsync error: syntax or usage error (code 1) at /AppleInternal/BuildRoot/Library/Caches/com.apple.xbs/Sources/rsync/rsync-54/rsync/main.c(1337) [client=2.6.9]
RSync finished
Scheduling with 12 parallel test sessions
============================================================================================================================= test session starts ==============================================================================================================================
platform darwin -- Python 2.7.17, pytest-4.6.9, py-1.8.1, pluggy-0.13.1
rootdir: /apps/utils, inifile: pytest.ini
plugins: timeout-1.3.4, xdist-1.25.0, ansible-playbook-0.4.1, forked-1.1.3, metadata-1.8.0, json-report-1.2.1, cloud-3.0.1
timeout: 600.0s
timeout method: signal
timeout func_only: False
hostname_0 C / (...) / hostname_11 C[hostname_0] node down: Traceback (most recent call last):
  File "<string>", line 1084, in executetask
  File "<string>", line 1, in do_exec
  File "/apps/utils/venv2/lib/python2.7/site-packages/xdist/remote.py", line 266, in <module>
  File "/apps/utils/venv2/lib/python2.7/site-packages/xdist/remote.py", line 242, in remote_initconfig
  File "/remote/pytest_username_utils/venv2/lib/python2.7/site-packages/_pytest/config/__init__.py", line 787, in fromdictargs
    config.parse(args, addopts=False)
  File "/remote/pytest_username_utils/venv2/lib/python2.7/site-packages/_pytest/config/__init__.py", line 953, in parse
    args, self.option, namespace=self.option
  File "/remote/pytest_username_utils/venv2/lib/python2.7/site-packages/_pytest/config/argparsing.py", line 101, in parse_setoption
    parsedoption = self.parse(args, namespace=namespace)
  File "/remote/pytest_username_utils/venv2/lib/python2.7/site-packages/_pytest/config/argparsing.py", line 81, in parse
    return self.optparser.parse_args(args, namespace=namespace)
  File "/remote/pytest_username_utils/venv2/lib/python2.7/site-packages/_pytest/config/argparsing.py", line 349, in parse_args
    args, argv = self.parse_known_args(args, namespace)
  File "/usr/lib64/python2.7/argparse.py", line 1720, in parse_known_args
    namespace, args = self._parse_known_args(args, namespace)
  File "/usr/lib64/python2.7/argparse.py", line 1944, in _parse_known_args
    self.error(_('argument %s is required') % name)
  File "/remote/pytest_username_utils/venv2/lib/python2.7/site-packages/_pytest/config/argparsing.py", line 345, in error
    raise UsageError(self.format_usage() + msg)
UsageError: usage: -c [options] [file_or_dir] [file_or_dir] [...]
-c: error: argument --workspace is required

In second example, last error doesn't matter. It is caused by test itself.

ValueError: ("the use of non-builtin globals isn't supported")

Getting below error. please help me out to proceed further.

(workvenv) bash-3.2$ pytest tests/ [email protected] --cloud-chdir=/home/hah --cloud-max-processes=2 --rsyncdir=.
Detected root dir: /Users/harish/Work/PPMPro/automation
Detecting connectable test nodes...
NODES LEN 1
SPECS [email protected]//id=1.2.3.4//chdir=/home/hah//python=python3.7
group 0
Node [email protected]
HOST IS [email protected]
Host 1.2.3.4
Found 1 connectable test nodes: {'[email protected]'}
RSyncing directory structure
rsync: -arHAXx: unknown option
rsync error: syntax or usage error (code 1) at /BuildRoot/Library/Caches/com.apple.xbs/Sources/rsync/rsync-52.200.1/rsync/main.c(1337) [client=2.6.9]
RSync finished

Traceback (most recent call last):
File "/Users/harish/Work/workvenv/bin/pytest", line 8, in
sys.exit(main())
File "/Users/harish/Work/workvenv/lib/python3.7/site-packages/_pytest/config/init.py", line 92, in main
config=config
File "/Users/harish/Work/workvenv/lib/python3.7/site-packages/pluggy/hooks.py", line 286, in call
return self._hookexec(self, self.get_hookimpls(), kwargs)
File "/Users/harish/Work/workvenv/lib/python3.7/site-packages/pluggy/manager.py", line 93, in _hookexec
return self._inner_hookexec(hook, methods, kwargs)
File "/Users/harish/Work/workvenv/lib/python3.7/site-packages/pluggy/manager.py", line 87, in
firstresult=hook.spec.opts.get("firstresult") if hook.spec else False,
File "/Users/harish/Work/workvenv/lib/python3.7/site-packages/pluggy/callers.py", line 208, in _multicall
return outcome.get_result()
File "/Users/harish/Work/workvenv/lib/python3.7/site-packages/pluggy/callers.py", line 80, in get_result
raise ex[1].with_traceback(ex[2])
File "/Users/harish/Work/workvenv/lib/python3.7/site-packages/pluggy/callers.py", line 187, in _multicall
res = hook_impl.function(*args)
File "/Users/harish/Work/workvenv/lib/python3.7/site-packages/pytest_cloud/plugin.py", line 136, in pytest_cmdline_main
check_options(config)
File "/Users/harish/Work/workvenv/lib/python3.7/site-packages/pytest_cloud/plugin.py", line 340, in check_options
config=config)
File "/Users/harish/Work/workvenv/lib/python3.7/site-packages/pytest_cloud/plugin.py", line 312, in get_nodes_specs
for node, hst in node_specs))
File "/Users/harish/Work/workvenv/lib/python3.7/site-packages/pytest_cloud/plugin.py", line 312, in
for node, hst in node_specs))
KeyError: '1.2.3.4'

Getting error "None of the given test nodes are connectable"

Getting below error when try to execute. I have tested manually rsync -avz tests/ username@ip:/home/username and it works fine.
(workvenv) bash-3.2$ pytest -m "smoke" --cloud-node=username@IP --cloud-chdir=/home/ --cloud-virtualenv-path= --cloud-max-processes=2 --rsyncdir=.
Detected root dir:
Detecting connectable test nodes...
/Users/harish/Work/workvenv/lib/python3.7/site-packages/psycopg2/init.py:144: UserWarning: The psycopg2 wheel package will be renamed from release 2.8; in order to keep installing from binary please use "pip install psycopg2-binary" instead. For details see: http://initd.org/psycopg/docs/install.html#binary-install-from-pypi.
""")
Traceback (most recent call last):
File "/Users/harish/Work/workvenv/bin/pytest", line 8, in
sys.exit(main())
File "/Users/harish/Work/workvenv/lib/python3.7/site-packages/_pytest/config/init.py", line 92, in main
config=config
File "/Users/harish/Work/workvenv/lib/python3.7/site-packages/pluggy/hooks.py", line 286, in call
return self._hookexec(self, self.get_hookimpls(), kwargs)
File "/Users/harish/Work/workvenv/lib/python3.7/site-packages/pluggy/manager.py", line 93, in _hookexec
return self._inner_hookexec(hook, methods, kwargs)
File "/Users/harish/Work/workvenv/lib/python3.7/site-packages/pluggy/manager.py", line 87, in
firstresult=hook.spec.opts.get("firstresult") if hook.spec else False,
File "/Users/harish/Work/workvenv/lib/python3.7/site-packages/pluggy/callers.py", line 208, in _multicall
return outcome.get_result()
File "/Users/harish/Work/workvenv/lib/python3.7/site-packages/pluggy/callers.py", line 80, in get_result
raise ex[1].with_traceback(ex[2])
File "/Users/harish/Work/workvenv/lib/python3.7/site-packages/pluggy/callers.py", line 187, in _multicall
res = hook_impl.function(*args)
File "/Users/harish/Work/workvenv/lib/python3.7/site-packages/pytest_cloud/plugin.py", line 136, in pytest_cmdline_main
check_options(config)
File "/Users/harish/Work/workvenv/lib/python3.7/site-packages/pytest_cloud/plugin.py", line 335, in check_options
config=config)
File "/Users/harish/Work/workvenv/lib/python3.7/site-packages/pytest_cloud/plugin.py", line 288, in get_nodes_specs
pytest.exit('None of the given test nodes are connectable')
File "/Users/harish/Work/workvenv/lib/python3.7/site-packages/_pytest/outcomes.py", line 85, in exit
raise Exit(msg, returncode)
_pytest.outcomes.Exit: None of the given test nodes are connectable
(workvenv) bash-3.2$ bash: python3.7: command not found

Can the version dependency be removed?

Currently the version of the pytest is <2.8.0
It is a bit outdated. Is there any particular reason for this limitation? The latest pytest version is 2.9.0

Fails with python3 (3.4.4) with raise RuntimeError('parallel is not found.')

I've tried to find a compatible version of paralel for python3 but couldn't. Is pytest-cloud supposed to be compatible with python3 in general?

> py.test --cloud-nodes delgado@{alekto,{anemoi,aurora}.devel} --cloud-python=/usr/bin/python3                                           git:(master) 11:06
Detected root dir: /home/delgado/projects/Customer/customer-project
Detecting connectable test nodes...
C_GetAttributeValue failed: 48
bind: Address already in use
channel_setup_fwd_listener_tcpip: cannot listen to port: 1080
bind: Address already in use
channel_setup_fwd_listener_tcpip: cannot listen to port: 15432
bind: Address already in use
channel_setup_fwd_listener_tcpip: cannot listen to port: 5672
bind: Address already in use
channel_setup_fwd_listener_tcpip: cannot listen to port: 6379
bind: Address already in use
channel_setup_fwd_listener_tcpip: cannot listen to port: 15672
Could not request local forwarding.
Warning: remote port forwarding failed for listen port 3128
Found 1 connectable test nodes: {'delgado@alekto'}
RSyncing directory structure
Traceback (most recent call last):
  File "/home/delgado/projects/Customer/customer-project/.venv/bin/py.test", line 10, in <module>
    sys.exit(main())
  File "/home/delgado/projects/Customer/customer-project/.venv/lib/python3.4/site-packages/_pytest/config/__init__.py", line 79, in main
    return config.hook.pytest_cmdline_main(config=config)
  File "/home/delgado/projects/Customer/customer-project/.venv/lib/python3.4/site-packages/pluggy/hooks.py", line 289, in __call__
    return self._hookexec(self, self.get_hookimpls(), kwargs)
  File "/home/delgado/projects/Customer/customer-project/.venv/lib/python3.4/site-packages/pluggy/manager.py", line 68, in _hookexec
    return self._inner_hookexec(hook, methods, kwargs)
  File "/home/delgado/projects/Customer/customer-project/.venv/lib/python3.4/site-packages/pluggy/manager.py", line 62, in <lambda>
    firstresult=hook.spec.opts.get("firstresult") if hook.spec else False,
  File "/home/delgado/projects/Customer/customer-project/.venv/lib/python3.4/site-packages/pluggy/callers.py", line 208, in _multicall
    return outcome.get_result()
  File "/home/delgado/projects/Customer/customer-project/.venv/lib/python3.4/site-packages/pluggy/callers.py", line 80, in get_result
    raise ex[1].with_traceback(ex[2])
  File "/home/delgado/projects/Customer/customer-project/.venv/lib/python3.4/site-packages/pluggy/callers.py", line 187, in _multicall
    res = hook_impl.function(*args)
  File "/home/delgado/projects/Customer/customer-project/.venv/lib/python3.4/site-packages/pytest_cloud/plugin.py", line 117, in pytest_cmdline_main
    check_options(config)
  File "/home/delgado/projects/Customer/customer-project/.venv/lib/python3.4/site-packages/pytest_cloud/plugin.py", line 312, in check_options
    config=config)
  File "/home/delgado/projects/Customer/customer-project/.venv/lib/python3.4/site-packages/pytest_cloud/plugin.py", line 268, in get_nodes_specs
    rsync.send()
  File "/home/delgado/projects/Customer/customer-project/.venv/lib/python3.4/site-packages/pytest_cloud/rsync.py", line 60, in send
    raise RuntimeError('parallel is not found.')
RuntimeError: parallel is not found.

ImportError: cannot import name '_psutil_linux' from partially initialized module 'psutil' (most likely due to a circular import). + "no tests ran"

Hi!

I wonder if you can help me with a problem I've been spending a couple of days trying to solve.

I run virtualenv venv && sudo venv/bin/pip install .[dev] to create a virtual environment with all my dependencies.

I've installed pytest-cloud on both my local computer and on the remote one, as well as parallel.

I then run

pytest tests/ --cloud-node=ubuntu@<local-ip-address> --cloud-virtualenv-path=venv/ --rsyncdir=.

and get the following

Detected root dir: /workspaces/ior
Detecting connectable test nodes...
Found 1 connectable test nodes: {'ubuntu@<local-ip-address>'}
RSyncing directory structure
RSync finished
Traceback (most recent call last):
  File "/workspaces/ior/venv/bin/pytest", line 8, in <module>
    sys.exit(console_main())
  File "/workspaces/ior/venv/lib/python3.8/site-packages/_pytest/config/__init__.py", line 185, in console_main
    code = main()
  File "/workspaces/ior/venv/lib/python3.8/site-packages/_pytest/config/__init__.py", line 162, in main
    ret: Union[ExitCode, int] = config.hook.pytest_cmdline_main(
  File "/workspaces/ior/venv/lib/python3.8/site-packages/pluggy/_hooks.py", line 265, in __call__
    return self._hookexec(self.name, self.get_hookimpls(), kwargs, firstresult)
  File "/workspaces/ior/venv/lib/python3.8/site-packages/pluggy/_manager.py", line 80, in _hookexec
    return self._inner_hookexec(hook_name, methods, kwargs, firstresult)
  File "/workspaces/ior/venv/lib/python3.8/site-packages/pluggy/_callers.py", line 60, in _multicall
    return outcome.get_result()
  File "/workspaces/ior/venv/lib/python3.8/site-packages/pluggy/_result.py", line 60, in get_result
    raise ex[1].with_traceback(ex[2])
  File "/workspaces/ior/venv/lib/python3.8/site-packages/pluggy/_callers.py", line 39, in _multicall
    res = hook_impl.function(*args)
  File "/workspaces/ior/venv/lib/python3.8/site-packages/pytest_cloud/plugin.py", line 184, in pytest_cmdline_main
    check_options(config)
  File "/workspaces/ior/venv/lib/python3.8/site-packages/pytest_cloud/plugin.py", line 409, in check_options
    node_specs = get_nodes_specs(
  File "/workspaces/ior/venv/lib/python3.8/site-packages/pytest_cloud/plugin.py", line 370, in get_nodes_specs
    caps = multi_channel.receive_each(True)
  File "/workspaces/ior/venv/lib/python3.8/site-packages/execnet/multi.py", line 259, in receive_each
    obj = ch.receive()
  File "/workspaces/ior/venv/lib/python3.8/site-packages/execnet/gateway_base.py", line 749, in receive
    raise self._getremoteerror() or EOFError()
execnet.gateway_base.RemoteError: Traceback (most recent call last):
  File "<string>", line 1088, in executetask
  File "/workspaces/ior/venv/lib/python3.8/site-packages/pytest_cloud/plugin.py", line 198, in get_node_capabilities
  File "/home/ubuntu/pytest_vscode_ior/venv/lib/python3.8/site-packages/psutil/__init__.py", line 99, in <module>
    from . import _pslinux as _psplatform
  File "/home/ubuntu/pytest_vscode_ior/venv/lib/python3.8/site-packages/psutil/_pslinux.py", line 26, in <module>
    from . import _psutil_linux as cext
ImportError: cannot import name '_psutil_linux' from partially initialized module 'psutil' (most likely due to a circular import) (/home/ubuntu/pytest_vscode_ior/venv/lib/python3.8/site-packages/psutil/__init__.py)

EDIT 1:

If I remove my psutil from my venv I get the following error instead

Detected root dir: /workspaces/ior
Detecting connectable test nodes...
Found 1 connectable test nodes: {'ubuntu@<local-ip-address>'}
RSyncing directory structure
RSync finished
Scheduling with 4 parallel test sessions
============================================================================================ test session starts ============================================================================================
platform linux -- Python 3.8.12, pytest-6.2.5, py-1.11.0, pluggy-1.0.0
rootdir: /workspaces/ior, configfile: pyproject.toml
plugins: xdist-2.4.0, forked-1.3.0, shutil-1.7.0, cloud-5.0.3, anyio-3.4.0, virtualenv-1.7.0
<local-ip-address>_0 I / <local-ip-address>_1 I / <local-ip-address>_2 I / <local-ip-address>_3 Ibash: pytest_vscode_ior/venv/bin/python3.8: No such file or directory
INTERNALERROR> Traceback (most recent call last):
INTERNALERROR>   File "/workspaces/ior/venv/lib/python3.8/site-packages/execnet/gateway_base.py", line 997, in _send
INTERNALERROR>     message.to_io(self._io)
INTERNALERROR>   File "/workspaces/ior/venv/lib/python3.8/site-packages/execnet/gateway_base.py", line 443, in to_io
INTERNALERROR>     io.write(header + self.data)
INTERNALERROR>   File "/workspaces/ior/venv/lib/python3.8/site-packages/execnet/gateway_base.py", line 410, in write
INTERNALERROR>     self.outfile.flush()
INTERNALERROR> BrokenPipeError: [Errno 32] Broken pipe
INTERNALERROR> 
INTERNALERROR> During handling of the above exception, another exception occurred:
INTERNALERROR> 
INTERNALERROR> Traceback (most recent call last):
INTERNALERROR>   File "/workspaces/ior/venv/lib/python3.8/site-packages/_pytest/main.py", line 267, in wrap_session
INTERNALERROR>     config.hook.pytest_sessionstart(session=session)
INTERNALERROR>   File "/workspaces/ior/venv/lib/python3.8/site-packages/pluggy/_hooks.py", line 265, in __call__
INTERNALERROR>     return self._hookexec(self.name, self.get_hookimpls(), kwargs, firstresult)
INTERNALERROR>   File "/workspaces/ior/venv/lib/python3.8/site-packages/pluggy/_manager.py", line 80, in _hookexec
INTERNALERROR>     return self._inner_hookexec(hook_name, methods, kwargs, firstresult)
INTERNALERROR>   File "/workspaces/ior/venv/lib/python3.8/site-packages/pluggy/_callers.py", line 60, in _multicall
INTERNALERROR>     return outcome.get_result()
INTERNALERROR>   File "/workspaces/ior/venv/lib/python3.8/site-packages/pluggy/_result.py", line 60, in get_result
INTERNALERROR>     raise ex[1].with_traceback(ex[2])
INTERNALERROR>   File "/workspaces/ior/venv/lib/python3.8/site-packages/pluggy/_callers.py", line 39, in _multicall
INTERNALERROR>     res = hook_impl.function(*args)
INTERNALERROR>   File "/workspaces/ior/venv/lib/python3.8/site-packages/xdist/dsession.py", line 78, in pytest_sessionstart
INTERNALERROR>     nodes = self.nodemanager.setup_nodes(putevent=self.queue.put)
INTERNALERROR>   File "/workspaces/ior/venv/lib/python3.8/site-packages/xdist/workermanage.py", line 66, in setup_nodes
INTERNALERROR>     return [self.setup_node(spec, putevent) for spec in self.specs]
INTERNALERROR>   File "/workspaces/ior/venv/lib/python3.8/site-packages/xdist/workermanage.py", line 66, in <listcomp>
INTERNALERROR>     return [self.setup_node(spec, putevent) for spec in self.specs]
INTERNALERROR>   File "/workspaces/ior/venv/lib/python3.8/site-packages/xdist/workermanage.py", line 69, in setup_node
INTERNALERROR>     gw = self.group.makegateway(spec)
INTERNALERROR>   File "/workspaces/ior/venv/lib/python3.8/site-packages/execnet/multi.py", line 145, in makegateway
INTERNALERROR>     channel = gw.remote_exec(
INTERNALERROR>   File "/workspaces/ior/venv/lib/python3.8/site-packages/execnet/gateway.py", line 132, in remote_exec
INTERNALERROR>     self._send(
INTERNALERROR>   File "/workspaces/ior/venv/lib/python3.8/site-packages/execnet/gateway_base.py", line 1003, in _send
INTERNALERROR>     raise IOError("cannot send (already closed?)")
INTERNALERROR> OSError: cannot send (already closed?)

EDIT 2:

It seems that my virtual environment python symlinks are broken on the remote after rsync when I look closer 🤔

image

EDIT 3:

It seems that my local computer has python installed in /usr/local/bin and the remote has python in /usr/bin which seems to cause issues with the virtualenv python symlinks. Have I done anything incorrect?

EDIT 4:

I created a symlink on the remote with sudo ln -s /usr/bin/python /usr/local/bin/python3 which seems to fix the above issue at least, the next error is that I get "no tests ran" 🤔

image

Fails on remote node without virtualenv

When I try to run on remote boxes which have the python dependencies installed globally (i.e. not in a virtualenv), then pytest-cloud fails with:

delgado@hoots:~AS[1]> py.test --cloud-node=delgado@alekto --cloud-python=/usr/bin/python36                                                 git:(master)  9:56
Detected root dir: /home/delgado/nobackup/git/Customer/myproject
Traceback (most recent call last):
  File "/home/delgado/nobackup/virtualenvs/myproject/bin/py.test", line 8, in <module>
    sys.exit(main())
  File "/home/delgado/nobackup/virtualenvs/myproject/lib/python3.6/site-packages/_pytest/config/__init__.py", line 92, in main
    config=config
  File "/home/delgado/nobackup/virtualenvs/myproject/lib/python3.6/site-packages/pluggy/hooks.py", line 286, in __call__
    return self._hookexec(self, self.get_hookimpls(), kwargs)
  File "/home/delgado/nobackup/virtualenvs/myproject/lib/python3.6/site-packages/pluggy/manager.py", line 93, in _hookexec
    return self._inner_hookexec(hook, methods, kwargs)
  File "/home/delgado/nobackup/virtualenvs/myproject/lib/python3.6/site-packages/pluggy/manager.py", line 87, in <lambda>
    firstresult=hook.spec.opts.get("firstresult") if hook.spec else False,
  File "/home/delgado/nobackup/virtualenvs/myproject/lib/python3.6/site-packages/pluggy/callers.py", line 208, in _multicall
    return outcome.get_result()
  File "/home/delgado/nobackup/virtualenvs/myproject/lib/python3.6/site-packages/pluggy/callers.py", line 80, in get_result
    raise ex[1].with_traceback(ex[2])
  File "/home/delgado/nobackup/virtualenvs/myproject/lib/python3.6/site-packages/pluggy/callers.py", line 187, in _multicall
    res = hook_impl.function(*args)
  File "/home/delgado/nobackup/virtualenvs/myproject/lib/python3.6/site-packages/pytest_cloud/plugin.py", line 132, in pytest_cmdline_main
    check_options(config)
  File "/home/delgado/nobackup/virtualenvs/myproject/lib/python3.6/site-packages/pytest_cloud/plugin.py", line 329, in check_options
    config=config)
  File "/home/delgado/nobackup/virtualenvs/myproject/lib/python3.6/site-packages/pytest_cloud/plugin.py", line 265, in get_nodes_specs
    **n_m.rsyncoptions)
UnboundLocalError: local variable 'n_m' referenced before assignment

(Backtrace slightly redacted via search + replace.)

Note that the local code repository has a related virtualenv (as seen in the backtrace) but the remote hosts do not have virtualenvs.

pytest-cloud uses unsupported arcfour cipher

With the release of OpenSSL 7.6, there was dropped support of arcfour https://www.openssh.com/txt/release-7.6

arcfour cipher is being used when negotiating connection with rsync https://github.com/pytest-dev/pytest-cloud/blob/master/pytest_cloud/rsync.py#L89

When unwrapped from parallel and executed from command line:

$ rsync -arHAXx --bwlimit=10000 --ignore-errors --numeric-ids --force --inplace --delete-excluded --delete -e "ssh -T -c arcfour -o Compression=no -x" . hostname:pytest_directory
Unable to negotiate with hostname port 22: no matching cipher found. Their offer: [email protected],aes128-ctr,aes192-ctr,aes256-ctr,[email protected],[email protected],aes128-cbc,aes192-cbc,aes256-cbc,blowfish-cbc,cast128-cbc,3des-cbc
rsync: connection unexpectedly closed (0 bytes received so far) [sender]
rsync error: unexplained error (code 255) at io.c(226) [sender=3.1.2]
$ echo $?
255
$ rsync -arHAXx --bwlimit=10000 --ignore-errors --numeric-ids --force --inplace --delete-excluded --delete -e "ssh -T -o Compression=no -x" . hostname:pytest_directory
$ echo $?
0

Both servers use the same version of OpenSSL

[source]$ ssh -Q key
ssh-ed25519
[email protected]
ssh-rsa
ssh-dss
ecdsa-sha2-nistp256
ecdsa-sha2-nistp384
ecdsa-sha2-nistp521
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
[dsmigiel@sj-avl-r1-1 dcp-test-utils]$ ssh -V
OpenSSH_7.4p1, OpenSSL 1.0.2k-fips  26 Jan 2017

---

[destination]$ ssh -Q key
ssh-ed25519
[email protected]
ssh-rsa
ssh-dss
ecdsa-sha2-nistp256
ecdsa-sha2-nistp384
ecdsa-sha2-nistp521
[email protected]
[email protected]
[email protected]
[email protected]
[email protected]
[destination]$ ssh -V
OpenSSH_7.4p1, OpenSSL 1.0.2k-fips  26 Jan 2017

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.