internetarchive / internetarchive/openlibrary-bots

Issues raised by running to doctests

Open
#57 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
81
Forks
67
PR merge metrics
No merged PRs in 30d

Description

% `pytest --doctest-modules .`
```
_______ ERROR collecting NY-Times-Bestseller-Bot/nyt_bestsellers_bot.py ________
NY-Times-Bestseller-Bot/nyt_bestsellers_bot.py:5: in
import urllib2
E ModuleNotFoundError: No module named 'urllib2'

During handling of the above exception, another exception occurred:
NY-Times-Bestseller-Bot/nyt_bestsellers_bot.py:8: in
import urllib2.request as urllib2
E ModuleNotFoundError: No module named 'urllib2'
_______________ ERROR collecting goodreads-scrape/script_add.py ________________
goodreads-scrape/script_add.py:14: in
root = ET.fromstring(r.content) #Parsing XML response from Goodreads
/opt/hostedtoolcache/Python/3.9.0/x64/lib/python3.9/xml/etree/ElementTree.py:1347: in XML
parser.feed(text)
E File "", line None
E xml.etree.ElementTree.ParseError: syntax error: line 1, column 0
___________ ERROR collecting google-books-bot/google_books_search.py ___________
google-books-bot/google_books_search.py:5: in
from apiclient.discovery import build
E ModuleNotFoundError: No module named 'apiclient'
_________________ ERROR collecting ia-sync-bot/extract-isbn.py _________________
ia-sync-bot/extract-isbn.py:21: in
with open(infile) as f:
E FileNotFoundError: [Errno 2] No such file or directory: '--doctest-modules'
_________________ ERROR collecting ia-sync-bot/update-ocaid.py _________________
ia-sync-bot/update-ocaid.py:30: in
with open(infile) as f:
E FileNotFoundError: [Errno 2] No such file or directory: 'olids-to-update.txt'
____________ ERROR collecting ia-wishlist-bot/add_wishlist_works.py ____________
ia-wishlist-bot/add_wishlist_works.py:31: in
with open('data/ol_works.csv', 'r') as csvfile:
E FileNotFoundError: [Errno 2] No such file or directory: 'data/ol_works.csv'
__________ ERROR collecting ia-wishlist-bot/add_works_via_wishlist.py __________
ia-wishlist-bot/add_works_via_wishlist.py:67: in
newly_added_book = ol.create_book(added_book)
/opt/hostedtoolcache/Python/3.9.0/x64/lib/python3.9/site-packages/olclient/openlibrary.py:926: in create_book
if len(_author.name.split(" ")) > 1:
E AttributeError: 'list' object has no attribute 'split'
_____________ ERROR collecting ia-wishlist-bot/fetch_bookcovers.py _____________
ia-wishlist-bot/fetch_bookcovers.py:19: in
from bs4 import BeautifulSoup
E ModuleNotFoundError: No module named 'bs4'
__________ ERROR collecting ia-wishlist-bot/import_wishlist_final.py ___________
ia-wishlist-bot/import_wishlist_final.py:36: in
with open(FILE, "rt") as infile:
E FileNotFoundError: [Errno 2] No such file or directory: 'data/wishlist_works_may_2018.csv'
_________________ ERROR collecting modern-import-bot/import.py _________________
modern-import-bot/import.py:12: in
with open(fname, 'r') as f:
E FileNotFoundError: [Errno 2] No such file or directory: '--doctest-modules'
_________________ ERROR collecting old-onix-bot/onix-import.py _________________
old-onix-bot/onix-import.py:7: in
import infogami.tdb as tdb
/opt/hostedtoolcache/Python/3.9.0/x64/lib/python3.9/site-packages/infogami/__init__.py:6: in
import web
E ModuleNotFoundError: No module named 'web'
____________________ ERROR collecting old-onix-bot/onix.py _____________________
old-onix-bot/onix.py:11: in
from .sax_utils import *
E ImportError: attempted relative import with no known parent package
____________________ ERROR collecting old-onix-bot/parse.py ____________________
old-onix-bot/parse.py:11: in
from lang import *
E ModuleNotFoundError: No module named 'lang'
__________________ ERROR collecting old-onix-bot/sax_utils.py __________________
old-onix-bot/sax_utils.py:7: in
import urlparse
E ModuleNotFoundError: No module named 'urlparse'
__________________ ERROR collecting onix-bot/OnixParserOld.py __________________
onix-bot/OnixParserOld.py:6: in
import onixcheck
E ModuleNotFoundError: No module named 'onixcheck'
___________________ ERROR collecting onix-bot/onixparser.py ____________________
onix-bot/onixparser.py:27: in
import onixcheck
E ModuleNotFoundError: No module named 'onixcheck'
_______________ ERROR collecting twitter-borrowbot/twitterbot.py _______________
twitter-borrowbot/twitterbot.py:7: in
import tweepy
E ModuleNotFoundError: No module named 'tweepy'
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.