diff options
| author | metalgamer | 2020-12-07 21:53:53 +0100 |
|---|---|---|
| committer | metalgamer | 2020-12-07 21:53:53 +0100 |
| commit | 998231e994cf58c9bd5851eb4d8f39581a60f65b (patch) | |
| tree | e4434cbe2bbfcf12ecb73a8b8d3c6d20f6f11acd | |
| parent | 95f47606d64db938901074fb4c011004c391e7e4 (diff) | |
| download | patternutils-998231e994cf58c9bd5851eb4d8f39581a60f65b.tar.gz patternutils-998231e994cf58c9bd5851eb4d8f39581a60f65b.zip | |
Fail with error message, if feedparser not found.
| -rw-r--r-- | patternutils/commands/prss.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/patternutils/commands/prss.py b/patternutils/commands/prss.py index 814672e..cc81ee1 100644 --- a/patternutils/commands/prss.py +++ b/patternutils/commands/prss.py @@ -3,7 +3,11 @@ import os.path from typing import Generator import click -import feedparser + +try: + import feedparser +except ImportError: + click.secho("feedparser not installed!", fg="red", err=True) from .. import utils |
