Forum Settings
Forums
Pages (3) « 1 2 [3]
Post New Reply
Jul 29, 2016 12:30 AM
DB Administrator
Nyaa~☆

Offline
Joined: Sep 2008
Posts: 17903
@jswan: The first version of the script had an xml file as output. You had to import this xml file to AniDB and then export it in a special file which you could then you to import to MAL.

Then the script was updated (because A-P's structure has changed) and it seems the entire way of exporting/importing data was changed as well. It seems that the newest version of the script tries to automatically add the exported series to MAL and the problem lies in the authorization part.

Maybe @calophi can have a look at the script and provide a quick fix. Or anyone else who sees this.
 
Jul 29, 2016 1:13 AM
Offline
Joined: Jun 2010
Posts: 7
Thanks for the reply! I was kind of frustrated because I assumed I did something wrong. Honestly it's enough to know that it wasn't working, I'll find another time to transfer my list manually unless your friend can really fix it. (Which would be awesome!)
 
Jul 29, 2016 6:24 AM
Offline
Joined: Jun 2008
Posts: 6
Luna said:
@jswan: The first version of the script had an xml file as output. You had to import this xml file to AniDB and then export it in a special file which you could then you to import to MAL.

Then the script was updated (because A-P's structure has changed) and it seems the entire way of exporting/importing data was changed as well. It seems that the newest version of the script tries to automatically add the exported series to MAL and the problem lies in the authorization part.

Maybe @calophi can have a look at the script and provide a quick fix. Or anyone else who sees this.


You're in luck, I need to pull my AP data over again and noticed it's broken yesterday afternoon. I don't know why yet, I'm not that familiar with python. I'll try to figure it out.

I think it's because AP is defaulting to the poster view instead of table view! Might be a quick fix, hold on.

I can't get AP to send the table view to the script, so I have to try and re-code it to use the poster view. This is gonna take me a bit.

OK everyone and @jswan here you go.

http://pastebin.com/p2ygYZHa

Still throws a lot of errors because MAL's api search seems really picky about what goes into it and also because AP names some stuff differently. I have it outputting errors only so you can manually enter the the shows that didn't work. If you change debug to True it will also output information about successes.

If you look at my profile everything I added today (7/29) was through the script.

Looks like there was a big where full ep count wasn't put in for watch. I think I fixed it but also titles already in the DB aren't updating so I'm not sure what's up with that...

Mod edit: Combined quintuple posts
Modified by Ardanaz, Nov 3, 2016 1:19 PM
 
Jul 29, 2016 6:13 PM
Offline
Joined: Jun 2010
Posts: 7
Hey there @calophi! I just ran it and it was able to import about 100/200 of my list so that saved me a ton of time. I really appreciate what you've done, thanks!
 
Jul 29, 2016 7:13 PM
Offline
Joined: Jun 2008
Posts: 6
jswan said:
Hey there @calophi! I just ran it and it was able to import about 100/200 of my list so that saved me a ton of time. I really appreciate what you've done, thanks!


I'm adding something that is retrying some search results if they had a colon in the name, I think it's helping. I'll update it soon.

I updated the script. It doesn't look like it is adding anything listed under "watching", no idea why but even if mine didn't error they didn't get added to the list. If anyone else can pin it down I'll update the script.

Mod edit: Combined double posts
Modified by Ardanaz, Nov 3, 2016 1:18 PM
 
Jul 30, 2016 1:01 PM
Offline
Joined: Jun 2010
Posts: 7
I went over my list and it seems like it got pretty much everything!
 
Aug 5, 2016 7:28 PM
Offline
Joined: Jul 2014
Posts: 1
@calophi, importing this user's AP profile only gives 2 successes of ~450 shows.

http://myanimelist.net/profile/Superwedgee

Erased and One Punch Man were the only ones that imported.


 
Aug 6, 2016 9:29 PM
Offline
Joined: Jun 2008
Posts: 6
Don't know what to tell you. I do know that for whatever reason shows won't update without you changing the code and running the script again. It will only add new shows. I guess MAL changed something so it doesn't fail if it's in your list already so the script doesn't fall back to an update.

Feel free to poke at the code, I'm not gonna sit and debug it more right now.
 
Nov 2, 2016 9:45 PM

Offline
Joined: Jun 2009
Posts: 29
Yuyu090 said:
Hello, i wanted to import my Anime-Planet list to myanimelist.

1. Download and install Python from https://www.python.org/ftp/python/3.5.2/python-3.5.2.exe
2. Run this command (press 'Win+R' -> type 'cmd') to install beautifulsoup:
pip install beautifulsoup4
3. Download the importer script from http://pastebin.com/p2ygYZHa and save it as
%temp%\import.py
4. Fix the bugged part by replacing (keep the proper indentation, it's important for Python scripts)
        except:
            xmlData += "\t<score></score>\n"
            continue
to
        except:
            xmlData += "\t<score></score>\n"
and also replace all
http://myanimelist.net
to
https://myanimelist.net
5. Run the script using
python %temp%\import.py
command (or from the directory you downloaded it to).
6. Enter your mal/ap credentials as requested.
7. That's all.

But it's kind of difficult with all the stuff needed so you can try the script ported to a single exe using pyinstaller (the size because it's bundled with python34.dll). Just do a 6th step with it: http://rgho.st/6ZmbYksWk It may or may not work because I don't really want to debug.
A story has no beginning or end; arbitrarily one chooses that moment of experience from which to look back or from which to look ahead.
 
Jan 11, 2017 2:45 AM
Offline
Joined: Dec 2016
Posts: 1
Well actually it whas kind of easy cause you explained it good and thy this helped me a lot ^^

Little zip to anyone who tryes to do it and dont finds the :
xmlData += "\t<score></score>\n"
continue
part there is a search option or a find option above the script just click on file and then find <3
 
Jan 13, 2017 2:28 PM

Offline
Joined: Jan 2010
Posts: 104
ErgoSis said:

1. Download and install Python from https://www.python.org/ftp/python/3.5.2/python-3.5.2.exe

...

But it's kind of difficult with all the stuff needed so you can try the script ported to a single exe using pyinstaller (the size because it's bundled with python34.dll). Just do a 6th step with it: http://rgho.st/6ZmbYksWk It may or may not work because I don't really want to debug.


Thank you! Worked like a charm! This may bring me again to myanimelist. :D
 
Apr 12, 2017 6:41 AM

Offline
Joined: Apr 2017
Posts: 1
Thank you for writing this python code and explaining how to use it :) that was a great help. I knew nothing about using python and even I could do it. It was kind of a pain to me because I'm using linux so couldn't figure out how to open the code...

If you are using linux
Use python3 /destination of the file/file name.py code in terminal and don't name the file as "%temp%\import.py" because linux cannot find the destination of the file in that name... But you could name it without the symbols like this; import.py

And by the way couldn't we use the same method just modify the code a bit to add manga from anime planet... I'm kinda trying to it now but it skips a lot of manga or adds different ones so... After the end of the process I'll update you..

And THAAAANK YOU SO MUCH AGAIIIN :3

..........................................
Edit: well It kinda works but skips a lot like as I said... And at the middle of the process It stopped at one manga... Some of the not found ones have "-" symbols at anime planet but not here so ıf we could find a methot to ignore that symbols and try to search database without them they can appear.. For example At anime planet: Oko-sama Box at myanimelist: okosama box... I had like 1000 manga at anime planet and now with this code I have 667 of them in here XD kinda sucks (and plus there is also manga that was not in my other list in it -kinda added them on it's own-)... If anyone understands about python and want to look at fix or make a working code I could pass my modified version of the previous code :)
The strange thing is even I have 667 in my manga list; I can see like 90 manga at my profile o_O even after I logged In and out...

I used this code for my manga list
https://pastebin.com/HE5HET7n
to use this one, make the same things that you did to anime python...
(Sorry for terrible English T_T)
Modified by _UmiNeko_, Apr 12, 2017 7:59 AM
MakoHaru
 
May 29, 2017 4:47 AM

Offline
Joined: Mar 2012
Posts: 68
https://myanimelist.net/panel.php?go=export

here use this export list,next do a download mal list and then finally do a Anime planet and anidb so that's it.

Anime-Planet.com - anime | manga | watch anime online
 
Jun 16, 2017 2:17 AM
Offline
Joined: Jun 2017
Posts: 1
ErgoSis said:

1. Download and install Python from https://www.python.org/ftp/python/3.5.2/python-3.5.2.exe
2. Run this command (press 'Win+R' -> type 'cmd') to install beautifulsoup:
pip install beautifulsoup4
3. Download the importer script from http://pastebin.com/p2ygYZHa and save it as
%temp%\import.py
4. Fix the bugged part by replacing (keep the proper indentation, it's important for Python scripts)
        except:
            xmlData += "\t<score></score>\n"
            continue
to
        except:
            xmlData += "\t<score></score>\n"
and also replace all
http://myanimelist.net
to
https://myanimelist.net
5. Run the script using
python %temp%\import.py
command (or from the directory you downloaded it to).
6. Enter your mal/ap credentials as requested.
7. That's all.

But it's kind of difficult with all the stuff needed so you can try the script ported to a single exe using pyinstaller (the size because it's bundled with python34.dll). Just do a 6th step with it: http://rgho.st/6ZmbYksWk It may or may not work because I don't really want to debug.


Thanks for this! Worked like a charm :D
 
Jan 10, 2018 3:00 PM
Offline
Joined: Oct 2009
Posts: 2
@ErgoSis
Is possible modify the script so that:
1. Detected in the title from AP `tv`,` ova`, `special`,` movie` and modified the search criteria accordingly?
2. Modifiy the comparison criteria so that titles with special characters are treated as identical, eg: `blood the last vampire` (AP) and` Blood: the Last Vampire` (MAL)
 
Jan 11, 2018 12:52 AM

Offline
Joined: Jun 2009
Posts: 29
The names aren't really that compatible between sites in so it won't do you much to do 2 as it's already comparing names without ':', ')' and '(' cahracters in MAL name on lines 150, 157, 161, 165. Not sure about 1, probably possible, but needs coding and debugging and AP annoys me with Cloudfare protection, probably something to do with my shitty ISP. In short you'll need to make request to
/anime?sort=title&mylist_view=list
on AP to get cookies for table view, and then use request with them with parsing code adopted from older version of the script to parse the table to get anime type and then compare it with
<type>...</type>
field of response entry from MAL.
A story has no beginning or end; arbitrarily one chooses that moment of experience from which to look back or from which to look ahead.
 
Jan 14, 2018 6:07 AM
Offline
Joined: Oct 2009
Posts: 2
In my case I replace all special characters witch `space`, and compare all titles in response. If in response is 1 entry, or other fields can determinate title, or titles before cleaning are identical...

use this for bypas cloudflare https://github.com/Anorov/cloudflare-scrape or use useragnet and cookies from your browser
 
Mar 6, 2018 9:10 AM
Offline
Joined: Mar 2018
Posts: 3
ErgoSis said:
Yuyu090 said:
Hello, i wanted to import my Anime-Planet list to myanimelist.

1. Download and install Python from https://www.python.org/ftp/python/3.5.2/python-3.5.2.exe
2. Run this command (press 'Win+R' -> type 'cmd') to install beautifulsoup:
pip install beautifulsoup4
3. Download the importer script from http://pastebin.com/p2ygYZHa and save it as
%temp%import.py
4. Fix the bugged part by replacing (keep the proper indentation, it's important for Python scripts)
        except:
            xmlData += "t<score></score>n"
            continue
to
        except:
            xmlData += "t<score></score>n"
and also replace all
http://myanimelist.net
to
https://myanimelist.net
5. Run the script using
python %temp%import.py
command (or from the directory you downloaded it to).
6. Enter your mal/ap credentials as requested.
7. That's all.

But it's kind of difficult with all the stuff needed so you can try the script ported to a single exe using pyinstaller (the size because it's bundled with python34.dll). Just do a 6th step with it: http://rgho.st/6ZmbYksWk It may or may not work because I don't really want to debug.


Thanks you the exec file worked.
At first it said "Msvcr100.dll Not Found or Missing" that was because i dont have "Microsoft Visual C++ 2010" installed in my pc, after i installed the exec file run flawlessly, it ported 380 anime out of 449 in AP list. unfortunately it did not create any list for the anime that it did not port.
Is there a way to know which entries are missing?
 
Aug 25, 2018 6:50 PM
Offline
Joined: Dec 2013
Posts: 1
I did everything the recent method said, but it isn't working for me. Is there another way to get the list from AP, and import it to MAL?
 
Aug 26, 2018 12:20 PM
Offline
Joined: Apr 2017
Posts: 1
im pretty sure that the code is fine after the renditions however mal's api search is currently down i think or moved to a different address that isn't
http://myanimelist.net/api/anime/search.xml
 
Jan 22, 6:38 AM
Offline
Joined: Dec 2018
Posts: 2
... An export option is ongoing as far as I know, but it started in May 2018 with still on hiatus.
 
Mar 24, 12:34 PM
Offline
Joined: Oct 2018
Posts: 1
I get this error
Traceback (most recent call last):
File "anime.py", line 13, in <module>
html = urllib2.urlopen(baseURL).read()
File "C:\Python27\lib\urllib2.py", line 154, in urlopen
return opener.open(url, data, timeout)
File "C:\Python27\lib\urllib2.py", line 435, in open
response = meth(req, response)
File "C:\Python27\lib\urllib2.py", line 548, in http_response
'http', request, response, code, msg, hdrs)
File "C:\Python27\lib\urllib2.py", line 473, in error
return self._call_chain(*args)
File "C:\Python27\lib\urllib2.py", line 407, in _call_chain
result = func(*args)
File "C:\Python27\lib\urllib2.py", line 556, in http_error_default
raise HTTPError(req.get_full_url(), code, msg, hdrs, fp)
urllib2.HTTPError: HTTP Error 403: Forbidden
 
Top
Pages (3) « 1 2 [3]