Skip to content

Commit

Permalink
Add source pcolle
Browse files Browse the repository at this point in the history
  • Loading branch information
mvdctop committed May 25, 2023
1 parent 3514377 commit b5adda5
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
2 changes: 1 addition & 1 deletion config.ini
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ image_naming_with_number = 0
update_check = 1

[priority]
website = javbus,airav,jav321,fanza,xcity,mgstage,fc2,avsox,dlsite,carib,madou,getchu,javdb,gcolle,javday,javmenu,caribpr
website = javbus,airav,jav321,fanza,xcity,mgstage,fc2,avsox,dlsite,carib,madou,getchu,javdb,gcolle,javday,javmenu,pcolle,caribpr

[escape]
literals = \()/
Expand Down
4 changes: 3 additions & 1 deletion scrapinglib/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ class Scraping:
"""
adult_full_sources = ['javlibrary', 'javdb', 'javbus', 'airav', 'fanza', 'xcity', 'jav321',
'mgstage', 'fc2', 'avsox', 'dlsite', 'carib', 'madou',
'getchu', 'gcolle', 'javday', 'pissplay', 'javmenu', 'caribpr'
'getchu', 'gcolle', 'javday', 'pissplay', 'javmenu', 'pcolle', 'caribpr'
]

general_full_sources = ['tmdb', 'imdb']
Expand Down Expand Up @@ -218,6 +218,8 @@ def insert(sources, source):
file_number):
sources = insert(sources, "getchu")
sources = insert(sources, "dlsite")
elif "pcolle" in sources and "pcolle" in lo_file_number:
sources = insert(sources, "pcolle")
elif "fc2" in lo_file_number:
if "fc2" in sources:
sources = insert(sources, "fc2")
Expand Down
4 changes: 3 additions & 1 deletion scrapinglib/parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
import re
from lxml import etree, html

import config
from . import httprequest
from .utils import getTreeElement, getTreeAll

Expand Down Expand Up @@ -166,7 +167,8 @@ def dictformat(self, htmltree):
}
dic = self.extradict(dic)
except Exception as e:
#print(e)
if config.getInstance().debug():
print(e)
dic = {"title": ""}
js = json.dumps(dic, ensure_ascii=False, sort_keys=True, separators=(',', ':'))
return js
Expand Down

0 comments on commit b5adda5

Please sign in to comment.