invoke 2.1.3 does not work when run inside bash
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 3/5
- Thời gian dự kiến
- 1-2 ngày
- Mức phù hợp với người mới
- 38/100
Hướng nghiên cứu
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.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
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.
...
- Ngôn ngữ chính
- Python
- Star
- 4.8k
- Fork
- 412
- Chỉ số merge pull request
- Không có pull request nào được merge trong 30 ngày
Chuẩn bị môi trường
Chúng tôi chưa kiểm tra các tệp thiết lập môi trường của dự án này. Hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của pyinvoke/invoke
-
[Security] Shell injection via Context.cd() path argument — metacharacters not escaped (CWE-78)Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 64/100
Tất cả issue của pyinvoke/invoke
Issue tương tự
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
PedestrianDynamics/pyFDS-Evac#199 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
521xueweihan/HelloGitHub#3790 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
sandialabs/atlas-ui-3#978 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
area: tests perceived difficulty: 2
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
Nitjsefnie-Harness-Commons/daedalus#1255 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
hf-audiolm-qwen: `generate_until` hardcodes `.to("cuda")` and aborts on non-CUDA acceleratorsĐang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 86/100
EleutherAI/lm-evaluation-harness#4256 ·
Maintainer thường phản hồi trong vòng 1 ngày