Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add hooks before download and after download. #44

Open
songww opened this issue Jul 14, 2018 · 3 comments
Open

Add hooks before download and after download. #44

songww opened this issue Jul 14, 2018 · 3 comments

Comments

@songww
Copy link

songww commented Jul 14, 2018

我们想在下载前或者下载后加一些东西,比如保存整个url。或者针对不同的状态码做不同的处理,比如3xx的重定向,5xx时重试等。

@kwuite
Copy link
Collaborator

kwuite commented Sep 16, 2018

Google translate from @songww:

We want to add something before or after the download, such as saving the entire url. Or do different processing for different status codes, such as 3xx redirection, 5xx retry, etc.

@kwuite
Copy link
Collaborator

kwuite commented Sep 25, 2018

@songww ,

Can you elaborate a bit more on your before and afterhooks. I might be able to implement this for you if you specify a bit more in detail why you need this and how you would use it.

@songww
Copy link
Author

songww commented Sep 25, 2018

Just like middleware of scrapy.

@kwuite

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants