Uploaded image for project: 'Funtoo Linux'
  1. Funtoo Linux
  2. FL-8984

metatools: cargo support requires latest rust

      I have noticed that sometimes the cargo autogen support will fail if rust is not updated. It will happen because certain features might be required for cargo to work. This is what the traceback looks like.

      error: failed to parse manifest at `/home/prod/repo_tmp/tmp/artifact_extract/cargo-c-0.9.5.tar.gz/lu-zero-carg
      o-c-96241fe/Cargo.toml`Caused by:
        feature `edition2021` is required  The package requires the Cargo feature called `edition2021`, but that feature is not stabilized in this version of Cargo (1.55.0 (32da73ab1 2021-08-23)).
        Consider trying a newer version of Cargo (this may require the nightly release).
        See https://doc.rust-lang.org/nightly/cargo/reference/unstable.html#edition-2021 for more information about the status of this feature.
      ERROR:asyncio:Exception in callback _handle_task_result(<Task finishe...r directory')>) at /home/prod/development/funtoo-metatools/funtoo/pkgtools/autogen.py:175
      handle: <Handle _handle_task_result(<Task finishe...r directory')>) at /home/prod/development/funtoo-metatools/funtoo/pkgtools/autogen.py:175>
      Traceback (most recent call last):
        File "/usr/lib/python3.7/asyncio/events.py", line 88, in _run
          self._context.run(self._callback, *self._args)
        File "/home/prod/development/funtoo-metatools/funtoo/pkgtools/autogen.py", line 181, in _handle_task_result
          raise e
        File "/home/prod/development/funtoo-metatools/funtoo/pkgtools/autogen.py", line 177, in _handle_task_result
          task.result()
        File "/home/prod/development/funtoo-metatools/funtoo/pkgtools/autogen.py", line 261, in gen_wrapper
          await generate(hub, **pkginfo)
        File "/home/prod/repo_tmp/source-trees/kit-fixups/dev-kit/curated/dev-util/cargo-c/autogen.py", line 24, in generate
          artifacts = await hub.pkgtools.rust.generate_crates_from_artifact(src_artifact)
        File "/home/prod/development/funtoo-metatools/funtoo/pkgtools/rust.py", line 43, in generate_crates_from_artifact
          artifacts = await get_crates_artifacts(cargo_lock_path)
        File "/home/prod/development/funtoo-metatools/funtoo/pkgtools/rust.py", line 13, in get_crates_artifacts
          with open(lock_path, "r") as f:
      FileNotFoundError: [Errno 2] No such file or directory: '/home/prod/repo_tmp/tmp/artifact_extract/cargo-c-0.9.5.tar.gz/lu-zero-cargo-c-96241fe/Cargo.lock'
      Fastpull enabled: True

      This is fixable by upgrading rust but I wanted to report it as it does create a dependence of metatools on having the latest version of rust or rust-bin installed.

            Unassigned Unassigned
            drobbins drobbins
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: