Skip to content

Commit caeb80a

Browse files
committed
修改项目名称命名
1 parent b141c07 commit caeb80a

File tree

9 files changed

+13
-14
lines changed

9 files changed

+13
-14
lines changed

proxymanager.py

+3-4
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,11 @@ def __init__(self):
1111
self.index = 0
1212
self.proxys = []
1313

14-
self.update_proxy()
15-
16-
# self.address = 'http://127.0.0.1:8000'
17-
self.address = 'http://101.200.55.192:8000'
14+
self.address = 'http://127.0.0.1:8000'
1815
self.name = 'assetstore'
1916

17+
self.update_proxy()
18+
2019
def update_proxy(self):
2120
try:
2221
r = requests.get(url = '%s/select?name=%s' % (self.address, self.name), timeout = 10)

scrapy.cfg

+2-2
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@
44
# https://scrapyd.readthedocs.org/en/latest/deploy.html
55

66
[settings]
7-
default = UnityAssetStore.settings
7+
default = unityassetstore.settings
88

99
[deploy]
1010
#url = http://localhost:6800/
11-
project = UnityAssetStore
11+
project = unityassetstore
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

UnityAssetStore/settings.py renamed to unityassetstore/settings.py

+8-8
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# -*- coding: utf-8 -*-
22

3-
# Scrapy settings for UnityAssetStore project
3+
# Scrapy settings for unityassetstore project
44
#
55
# For simplicity, this file contains only settings considered important or
66
# commonly used. You can find more settings consulting the documentation:
@@ -9,13 +9,13 @@
99
# http://scrapy.readthedocs.org/en/latest/topics/downloader-middleware.html
1010
# http://scrapy.readthedocs.org/en/latest/topics/spider-middleware.html
1111

12-
BOT_NAME = 'UnityAssetStore'
12+
BOT_NAME = 'unityassetstore'
1313

14-
SPIDER_MODULES = ['UnityAssetStore.spiders']
15-
NEWSPIDER_MODULE = 'UnityAssetStore.spiders'
14+
SPIDER_MODULES = ['unityassetstore.spiders']
15+
NEWSPIDER_MODULE = 'unityassetstore.spiders'
1616

1717
# Crawl responsibly by identifying yourself (and your website) on the user-agent
18-
#USER_AGENT = 'UnityAssetStore (+http://www.yourdomain.com)'
18+
#USER_AGENT = 'unityassetstore (+http://www.yourdomain.com)'
1919

2020
#USER_AGENT = "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_6) AppleWebKit/537.36 (KHTML, like Gecko)
2121
# Chrome/54.0.2840.87 Safari/537.36"
@@ -49,16 +49,16 @@
4949
# Enable or disable spider middlewares
5050
# See http://scrapy.readthedocs.org/en/latest/topics/spider-middleware.html
5151
#SPIDER_MIDDLEWARES = {
52-
# 'UnityAssetStore.middlewares.MyCustomSpiderMiddleware': 543,
52+
# 'unityassetstore.middlewares.MyCustomSpiderMiddleware': 543,
5353
#}
5454

5555
# Enable or disable downloader middlewares
5656
# See http://scrapy.readthedocs.org/en/latest/topics/downloader-middleware.html
5757
DOWNLOADER_MIDDLEWARES = {
5858
#'scrapy.contrib.downloadermiddleware.httpproxy.HttpProxyMiddleware': 1020,
5959
'scrapy.contrib.downloadermiddleware.retry.RetryMiddleware': None,
60-
'UnityAssetStore.middlewares.ProxyMiddleware': 100,
61-
'UnityAssetStore.middlewares.CustomRetryMiddleware': 500,
60+
'unityassetstore.middlewares.ProxyMiddleware': 100,
61+
'unityassetstore.middlewares.CustomRetryMiddleware': 500,
6262
}
6363

6464
# Enable or disable extensions

0 commit comments

Comments
 (0)