Skip to content
This repository has been archived by the owner on Jun 12, 2024. It is now read-only.

cp: cannot stat './handle-task-event': No such file or directory #19

Open
gregb122 opened this issue Jan 4, 2024 · 0 comments
Open

Comments

@gregb122
Copy link

gregb122 commented Jan 4, 2024

Hi,

I have encountered an error

Caution

cp: cannot stat './handle-task-event': No such file or directory

Caution

Command 'set -eE && ( ./handle-task-event || (TEMPLATE_PREVIEW=$(mktemp); cp ./handle-task-event $TEMPLATE_PREVIEW) ) && ( if test $TEMPLATE_PREVIEW; then ( echo "Opening the failing template preview" && $EDITOR $TEMPLATE_PREVIEW ); fi )' returned non-zero exit status 1.

To reproduce

  1. Install all the requitements listed in README
  2. Install poetry with pipx
  3. Run: copier copy --trust --vcs-ref HEAD "$SKELETON" iteapot-backend
  4. Answer prompts

Expected behaviour

The repository and the project files are successfully created without any error and I can find them in my file system.

Env

VS Code integrated terminal connected to WSL2 with the following version of Ubuntu

Distributor ID: Ubuntu
Description:    Ubuntu 22.04.3 LTS
Release:        22.04
Codename:       jammy

Full error

Similar error was raised when repository name was open, so I think it is not related.

→ Running copier hook...
Previous license name: Custom
Set license name: MIT
Generating documentation symlinks...
  docs/changelog.md -> ../CHANGELOG.md
Generated 1 documentation symlinks
🛈 Copier hook exited with code 0.
→ Removing copier hook...

→ Initializing git repository...
🛈 Main branch: main
GraphQL: Name already exists on this account (createRepository)
cp: cannot stat './handle-task-event': No such file or directory
Traceback (most recent call last):
  File "/home/gregb12/.local/bin/copier", line 8, in <module>
    sys.exit(copier_app_run())
             ^^^^^^^^^^^^^^^^
  File "/home/gregb12/.local/pipx/venvs/copier/lib/python3.12/site-packages/plumbum/cli/application.py", line 638, in run
    inst, retcode = subapp.run(argv, exit=False)
                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/gregb12/.local/pipx/venvs/copier/lib/python3.12/site-packages/plumbum/cli/application.py", line 633, in run
    retcode = inst.main(*tailargs)
              ^^^^^^^^^^^^^^^^^^^^
  File "/home/gregb12/.local/pipx/venvs/copier/lib/python3.12/site-packages/decorator.py", line 232, in fun
    return caller(func, *(extras + args), **kw)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/gregb12/.local/pipx/venvs/copier/lib/python3.12/site-packages/copier/cli.py", line 72, in handle_exceptions
    return method(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/gregb12/.local/pipx/venvs/copier/lib/python3.12/site-packages/copier/cli.py", line 265, in main
    with self._worker(
  File "/home/gregb12/.local/pipx/venvs/copier/lib/python3.12/site-packages/copier/main.py", line 205, in __exit__
    raise value
  File "/home/gregb12/.local/pipx/venvs/copier/lib/python3.12/site-packages/copier/cli.py", line 272, in main
    worker.run_copy()
  File "/home/gregb12/.local/pipx/venvs/copier/lib/python3.12/site-packages/copier/main.py", line 758, in run_copy
    self._execute_tasks(self.template.tasks)
  File "/home/gregb12/.local/pipx/venvs/copier/lib/python3.12/site-packages/copier/main.py", line 284, in _execute_tasks
    subprocess.run(task_cmd, shell=use_shell, check=True, env=local.env)
  File "/usr/lib/python3.12/subprocess.py", line 571, in run
    raise CalledProcessError(retcode, process.args,
subprocess.CalledProcessError: Command 'set -eE && ( ./handle-task-event || (TEMPLATE_PREVIEW=$(mktemp); cp ./handle-task-event $TEMPLATE_PREVIEW) ) && ( if test $TEMPLATE_PREVIEW; then ( echo "Opening the failing template preview" && $EDITOR $TEMPLATE_PREVIEW ); fi )' returned non-zero exit status 1.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant