Closed GoogleCodeExporter closed 9 years ago
I am not sure if it is a good idea to remove this... For instance, people might
prefer "Marvel", or "Marvel Comics", or "Marvel Publishing"... having the
publishers file is an easy way to let anyone choose what they like. I do use it
this way.
Original comment by theotoco...@gmail.com
on 28 Sep 2010 at 11:01
Fixed for the next release of Comic Vine Scraper (still a few weeks off):
I've re-done the way publishers and imprints are handled in the scraper. Now,
all publisher names are scraped exactly as they appear in Comic Vine (and Comic
Vine itself takes care of making sure that there is only one consistent name
for each publisher.)
Also, I've started using the Comic Vine publisher list to keep the scraper's
list of known imprints up-to-date:
http://www.comicvine.com/publishers/
---------------
@theotocopulitos: sorry, there's no publishers.py file anymore. :( But since
you were editing code for that change anyway, there's another option. Once the
next release is available, you can still get it to work the way you want by
adding an "if" statement at the beginning of the "save_issue_to_book" function
in bookutils.py.
if issue.publisher_s == "Marvel"
issue.publisher_s = "Marvel Comics"
if issue.publisher_s == "DC Comics"
issue.publisher_s = "D.C."
etc, etc.
Original comment by cban...@gmail.com
on 11 Nov 2010 at 11:36
Thanks for the tip!
I agree that the simpler the better for the main code, but it is great to have
a way to keep it the way it was!
Thanks again.
Original comment by theotoco...@gmail.com
on 14 Nov 2010 at 3:02
@theotocupulitos:
In 1.0.33, the "save_issue_to_book" function is actually moved to comicbook.py
(in the ComicBook object), and it is now just called "save_issue".
Original comment by cban...@gmail.com
on 3 Jan 2011 at 6:00
Hi, great work on the comicvine scraper! I have no experience with python, and
I'm trying to add the "if" statement to comicbook.py to make the publishers
stay the way I want them ("Marvel" remaining "Marvel Comics" especially) and
it's not working. When I do it, it breaks comicvine scraper. I don't know
exactly where in the code to place it, and I don't know if I'm putting the
right spaces or tabs when I put it in. Is there any way you could show exactly
where and how to put it in the script? Also, does it matter what text editor
you use to add the lines? Thanks!
Original comment by jstrat0...@gmail.com
on 2 Mar 2011 at 7:24
Hi!
I notice I left colons out of my suggested code up there, so that's probably
why it's not working for you. It doesn't matter what text editor you use
(just don't use Word or anything that lets you do formatting, in a pinch
notepad should work fine.)
Spacing in python is very important, so make sure everything lines up (use the
spacebar, not the tab key).
The file you want to change is comicbook.py, which, if you're using the latest
release, should look like this:
http://code.google.com/p/comic-vine-scraper/source/browse/src/libs/utils/comicbo
ok.py?spec=svn540f0d062a3468d2c0c79e88729092485d672edc&r=9ef86cb39be4f34ac196999
30ac5d5954ba9e4a1
You can add the following 4 lines into the "save_issue" function, right after
the comment (i.e. add them at line 115 on the link above):
if issue.publisher_s == "Marvel":
issue.publisher_s = "Marvel Comics"
if issue.publisher_s == "DC Comics":
issue.publisher_s = "D.C."
Of course, you can modify this part to suit your tastes, or only add the first
two lines, etc.
As I said, spacing is very important in python, so make sure the lines that
begin with "if" are lined up exactly with the comment text above, and the
existing code below. The 2 indented lines in my example should be indented
exactly 3 spaces.
Original comment by cban...@gmail.com
on 2 Mar 2011 at 10:26
Thank you so much, it works perfectly now! I appreciate you taking your time to
reply, and on making a great plug-in! Thanks again!
Original comment by jstrat0...@gmail.com
on 4 Mar 2011 at 8:03
Original issue reported on code.google.com by
cban...@gmail.com
on 28 Sep 2010 at 8:04