kislyuk / argcomplete

Python and tab completion, better together.
https://kislyuk.github.io/argcomplete/
Apache License 2.0
1.39k stars 129 forks source link

Test without pip build isolation #428

Closed hroncok closed 1 year ago

hroncok commented 1 year ago

This allows keeping running the tests in an offline environment with pip 23.1.2.

Without this, we get:

======================================================================
FAIL: test_console_script_module (test.test.TestBashGlobal.test_console_script_module)
Test completing a console_script for a module.
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/builddir/build/BUILD/argcomplete-2.0.0/test/test.py", line 1293, in test_console_script_module
    self._test_console_script()
  File "/builddir/build/BUILD/argcomplete-2.0.0/test/test.py", line 1283, in _test_console_script
    self.assertEqual(self.sh.run_command('echo $?'), '0\r\n', install_output)
AssertionError: '1\r\n' != '0\r\n'
- 1
+ 0
 : Processing /builddir/build/BUILD/argcomplete-2.0.0/test/test_package
  Installing build dependencies ... [?25l- \ | / - error
  error: subprocess-exited-with-error

  × pip subprocess to install build dependencies did not run successfully.
  │ exit code: 1
  ╰─> [7 lines of output]
      WARNING: Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection object at 0x7f5a0e412190>: Failed to establish a new connection: [Errno -3] Temporary failure in name resolution')': /simple/setuptools/
      WARNING: Retrying (Retry(total=3, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection object at 0x7f5a0ca518d0>: Failed to establish a new connection: [Errno -3] Temporary failure in name resolution')': /simple/setuptools/
      WARNING: Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection object at 0x7f5a0ca9fe90>: Failed to establish a new connection: [Errno -3] Temporary failure in name resolution')': /simple/setuptools/
      WARNING: Retrying (Retry(total=1, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection object at 0x7f5a0e61cd10>: Failed to establish a new connection: [Errno -3] Temporary failure in name resolution')': /simple/setuptools/
      WARNING: Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection object at 0x7f5a0e17e290>: Failed to establish a new connection: [Errno -3] Temporary failure in name resolution')': /simple/setuptools/
      ERROR: Could not find a version that satisfies the requirement setuptools>=40.8.0 (from versions: none)
      ERROR: No matching distribution found for setuptools>=40.8.0
      [end of output]

  note: This error originates from a subprocess, and is likely not a problem with pip.
error: subprocess-exited-with-error

× pip subprocess to install build dependencies did not run successfully.
│ exit code: 1
╰─> See above for output.

note: This error originates from a subprocess, and is likely not a problem with pip.
codecov-commenter commented 1 year ago

Codecov Report

Patch and project coverage have no change.

Comparison is base (f3f856b) 81.29% compared to head (6b72e13) 81.29%.

:exclamation: Your organization is not using the GitHub App Integration. As a result you may experience degraded service beginning May 15th. Please install the Github App Integration for your organization. Read more.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## develop #428 +/- ## ======================================== Coverage 81.29% 81.29% ======================================== Files 10 10 Lines 770 770 ======================================== Hits 626 626 Misses 144 144 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.

hroncok commented 1 year ago

Installing wheel is apparently enough to fix this, passing the flag is not actually necessary.