-
Notifications
You must be signed in to change notification settings - Fork 258
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
Can't login in PixivUtil2 #1397
Comments
I still can't login in PixivUtil2. I tried using Chrome browser user-agent and cookie to login, but now I get a different error:
I put in the Chrome user-agent and the Chrome cookie, and the above is the resulting error. I'm able to login and use Pixiv website on both browsers completely fine, so I don't understand why my login information isn't working in PixivUtil2 anymore. Anyone have any idea what else I can do? edit: I shortened the user-agent to just Mozilla/5.0 while using the chrome information. The result is the same error message from my first post. |
tldr, my bodged solution: diff --git a/PixivBrowserFactory.py b/PixivBrowserFactory.py
index 1ecfdd7..9164fa6 100644
--- a/PixivBrowserFactory.py
+++ b/PixivBrowserFactory.py
@@ -594,7 +594,7 @@ class PixivBrowser(mechanize.Browser):
PixivHelper.print_and_log('info', f'My User Id: {self._myId}.')
else:
# var dataLayer = [{ login: 'yes', gender: "male", user_id: "3145410", lang: "en", illustup_flg: 'not_uploaded', premium: 'no', }];
- temp = re.findall(r"var dataLayer = .*user_id: \"(\d+)\"", parsed)
+ temp = re.findall(r"var dataLayer = .*user_id:'(\d+)'", parsed)
if self._myId == 0 and temp is not None and len(temp) > 0:
self._myId = int(temp[0])
PixivHelper.print_and_log('info', f'My User Id: {self._myId}.') i.e. change I received the same error message and I took a look in it. In my case, 'use strict'; var dataLayer = [{login:'yes',gender:'<MYGENDER>',user_id:'<MYID>',lang:'ja',illustup_flg:'not_uploaded',premium:'no',default_service_is_touch:'yes'}]; Not sure this is my fault, I did tinker some config values while trying to solve issue by searching through issues here. I don't think this warrants deep debug dive, but maybe proper parsing of dataLayer array instead of regex parsing would be nice. Always grateful for your work, Nandaka and all contributors! |
I have same problem too. about 2 week before this error message happen, I'm use this version and it work normally. I have done fix by following instruction, I'm still get this error. Thank you in advance for fixing it. |
Where I can find this file PixivBrowserFactory.py in .exe version? |
i got this same error 403 |
You have to run from the source code. Not super easy in Windows especially for non-programmers, but it can be done. |
I'm using the latest release of PixivUtil2 (v20240703). As of today, when I try to launch PixivUtil2, I get an error message:
I logged out of Pixiv site and logged back in, copied the new cookie value over to config.ini, but I'm still getting the same error message in PixivUtil2. I also tried the method of changing my password and getting the cookie, but that didn't work either. I also updated my user-agent with information from my Firefox browser, but that didn't fix it either.
The text was updated successfully, but these errors were encountered: