exercism / exercism/python

[Error Handling]: ImportError while importing test module (Error-Handling Messaging & Exercises)

Đang mở
#2,275 8 bình luận 0 reaction 1 người được giao Được @BethanyG nhận Xem trên GitHub
maintainer action required❕ maintainer chore 🔧 smolder🍲
Ngôn ngữ chính
Python
Star
2.5k
Fork
1.5k
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Mô tả

Good day. I first offer the obligatory "I'm not GitHub-savvy" apology. I _did_ look for an answer as prescribed [here](https://exercism.io/faqs), following steps in subheading **Opening an Issue**. But I have not seen anything. I've seen some fixes on Stack Overflow. But they make no sense to me. Please don't crush me if I'm doing this wrong.

I'm working on a new linux install. On my previous installation, I ran pytest successfully many times (28 to be precise). With this new installation, I've run it once successfully on exercise _Twelve Days of Christmas_. It's giving me this error now:

```
$ /home/dan/.local/bin/pytest meetup_test.py
============================= test session starts ==============================
platform linux -- Python 3.8.5, pytest-6.1.2, py-1.9.0, pluggy-0.13.1
rootdir: /home/dan/exercism/python/meetup
collected 0 items / 1 error

==================================== ERRORS ====================================
_______________________ ERROR collecting meetup_test.py ________________________
ImportError while importing test module '/home/dan/exercism/python/meetup/meetup_test.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
/usr/lib/python3.8/importlib/__init__.py:127: in import_module
return _bootstrap._gcd_import(name[level:], package, level)
meetup_test.py:4: in
from meetup import meetup, MeetupDayException
E ImportError: cannot import name 'MeetupDayException' from 'meetup' (/home/dan/exercism/python/meetup/meetup.py)
=========================== short test summary info ============================
ERROR meetup_test.py
!!!!!!!!!!!!!!!!!!!! Interrupted: 1 error during collection !!!!!!!!!!!!!!!!!!!!
=============================== 1 error in 0.09s ===============================
$
```
I tried removing the meetup directory and re-downloading from the CLI. I get this error no matter what the contents of meetup.py are. So, I'm guessing that I have some issue either with they way pytest is configured or with my meetup_pytest file.

Any assistance greatly appreciated.

Thank you so much.
Dan.

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Đánh giá

Issue này chưa được đánh giá.

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.