HibiAPI
HibiAPI copied to clipboard
pixiv rank Rate Limit?
What is this?
Now I get this error...
I often encounter this problem too. 我也经常遇到这个问题。 This problem seems to be caused by the user logging in elsewhere/the current token becoming invalid. 这个问题似乎是因为 用户在其他地方登录/当前令牌失效导致的。 You can try logging in again to obtain the token to solve the problem? 你可以尝试重新登录获取令牌来解决问题? If possible, you can try to add an automatic refresh token operation to the code. 如果可能的话,你可以尝试在代码中增加自动刷新令牌的操作。
Rate limiting is Pixiv first-party is limiting your API requests to their server.
You can configure multiple accounts to make load balance if there does have a large amount request. In this case, you may need preventing your instance from frequently restarting or using external caching (e.g. DiskCache or Redis) instead of in memory caching. For more information about caching, see #114 and #380.
I don't know if there is an IP-addresses based rate limit or something similar has been applied recently. It is completely black box for us. Increase caching size or adding more account to load-balancing (see comments in config file) request may help.
This problem seems to be caused by the user logging in elsewhere/the current token becoming invalid.
I haven't touched code for a time, but I remember there should be another error if the token became invalid.
If possible, you can try to add an automatic refresh token operation to the code.
There does have a token refreshing operation. Access Token will be refreshed after it expires (lazy refreshing, i.e. check if expired locally at each request and does refresh if it expired), by Refresh Token.
Refresh Token, however, should last more than one year if there are no manually logout operation, so that does not require frequently rotate. (and it can't be rotated automatically since there are a few captchas / firewalls existed).