Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

invoke 2.1.3 does not work when run inside bash

オープン
#955 コメント 0 件 リアクション 5 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
3/5
見積もり時間
1〜2日
初心者へのやさしさ
38/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
停滞
技術スタック
python
領域
cli

調査の方向性

Reproduce the issue with the shown tasks.py, tasks/init.py, tasks/build.py, and tasks/tests.py structure using both direct invocation and bash -c "invoke -l -d". Compare the loader output for each command, focusing on why the tasks.py module is selected in the shell case. Done means the defined tasks are discovered consistently in both invocation modes.

索引モデルが issue の本文から書いたものです。

説明

I have a typical folder structure with:

/tasks.py
/tasks/__init__.py
/tasks/build.py
/tasks/tests.py

Everything runes with 2.0.0, but after upgrading to 2.1.3 tasks are not found anymore.

When run invoke -l -d I get a working output:

invoke.program.parse_collection: No default namespace provided, trying to load one from disk
invoke.loader.find: FilesystemLoader find starting at '/Users/alexander.petermann/projects/abc'
invoke.loader.find: Found module: '/Users/alexander.petermann/projects/abc/tasks'
invoke.config._load_file: Didn't see any /Users/alexander.petermann/projects/abc/invoke.yaml, skipping.
....

but if I call invoke inside a bash script OR like bash -c "invoke -l -d", invoke will not find the defined tasks:

invoke.program.parse_collection: No default namespace provided, trying to load one from disk
invoke.loader.find: FilesystemLoader find starting at '/Users/alexander.petermann/projects/abc'
invoke.loader.find: Found module: ModuleSpec(name='tasks', loader=<_frozen_importlib_external.SourceFileLoader object at 0x1015fe1d0>, origin='/Users/alexander.petermann/projects/abc/tasks.py')
invoke.config._load_file: Didn't see any /Users/alexander.petermann/projects/abc/invoke.yaml, skipping.
...
主要言語
Python
スター
4.8k
フォーク
412
PR マージ指標
30日以内にマージされた PR はありません

コントリビューションガイド

このリポジトリのコントリビューションガイドは索引されていません

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

pyinvoke/invoke のほかの issue

pyinvoke/invoke の issue をすべて見る

似ている issue

Python の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。