avocado icon indicating copy to clipboard operation
avocado copied to clipboard

Local avocado egg in podman spawner is not working

Open richtja opened this issue 2 years ago • 0 comments

Describe the bug It is not possible to use local avocado egg for podman spawner

Steps to reproduce avocado configuration file:

[spawner.podman]
avocado_spawner_egg = "~/Avocado/avocado/dist/avocado_framework-97.0-py3.9.egg"

avocado command:

avocado run --nrunner-spawner=podman /bin/true

Expected behavior

$ avocado run --nrunner-spawner=podman /bin/true
JOB ID     : ce45f5b54db90df32bda056b8e43edfa44dc1085
JOB LOG    : /home/jarichte/avocado/job-results/job-2022-05-31T11.28-ce45f5b/job.log
 (1/1) /bin/true: STARTED
 (1/1) /bin/true: PASS (0.01 s)
RESULTS    : PASS 1 | ERROR 0 | FAIL 0 | SKIP 0 | WARN 0 | INTERRUPT 0 | CANCEL 0
JOB HTML   : /home/jarichte/avocado/job-results/job-2022-05-31T11.28-ce45f5b/results.html
JOB TIME   : 2.84 s

Current behavior

avocado run --nrunner-spawner=podman /bin/true 
JOB ID     : 707ba91995487636b096e987af3e44f38abf5303
JOB LOG    : /home/jarichte/avocado/job-results/job-2022-05-31T13.28-707ba91/job.log

Avocado crashed: OSError: Failed to fetch avocado_framework-97.0-py3.9.egg" (Can't fetch: 'urls' is not defined.).
Traceback (most recent call last):

  File "/home/jarichte/Avocado/avocado/avocado/core/job.py", line 609, in run_tests
    summary |= suite.run(self)

  File "/home/jarichte/Avocado/avocado/avocado/core/suite.py", line 296, in run
    return self.runner.run_suite(job, self)

  File "/home/jarichte/Avocado/avocado/avocado/plugins/runner_nrunner.py", line 287, in run_suite
    loop.run_until_complete(asyncio.wait_for(asyncio.gather(*workers),

  File "/home/jarichte/.pyenv/versions/3.9.0/lib/python3.9/asyncio/base_events.py", line 642, in run_until_complete
    return future.result()

  File "/home/jarichte/.pyenv/versions/3.9.0/lib/python3.9/asyncio/tasks.py", line 440, in wait_for
    return await fut

  File "/home/jarichte/Avocado/avocado/avocado/core/task/statemachine.py", line 297, in run
    await self.start()

  File "/home/jarichte/Avocado/avocado/avocado/core/task/statemachine.py", line 229, in start
    start_ok = await self._spawner.spawn_task(runtime_task)

  File "/home/jarichte/Avocado/avocado/avocado/plugins/spawners/podman.py", line 234, in spawn_task
    eggs = self.get_eggs_paths(major, minor)

  File "/home/jarichte/Avocado/avocado/avocado/plugins/spawners/podman.py", line 140, in get_eggs_paths
    path = self._fetch_asset(url)

  File "/home/jarichte/Avocado/avocado/avocado/plugins/spawners/podman.py", line 119, in _fetch_asset
    return asset.fetch()

  File "/home/jarichte/Avocado/avocado/avocado/utils/asset.py", line 401, in fetch
    raise OSError(f"Failed to fetch {self.asset_name} ({error}).")

OSError: Failed to fetch avocado_framework-97.0-py3.9.egg" (Can't fetch: 'urls' is not defined.).

Please include the traceback info and command line used on your bug report
Report bugs visiting https://github.com/avocado-framework/avocado/issues/new

System information (please complete the following information):

  • OS: LSB Version: :core-4.1-amd64:core-4.1-noarch Distributor ID: Fedora Description: Fedora release 36 (Thirty Six) Release: 36 Codename: ThirtySix
  • Avocado version: Avocado 97.0
  • Avocado installation method: github

richtja avatar May 31 '22 11:05 richtja