-
Notifications
You must be signed in to change notification settings - Fork 69
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
"UnboundLocalError: cannot access local variable 'workid' where it is not associated with a value" when listing bookmarks #99
Comments
Were you able to find a workaround for this? I'm running into a similar issue. |
I haven’t really worked with this code in 5 months, so take this reply with a grain of salt. Having said that, I remember I did continue trying a bit after posting this issue. This is a collection of my hazy memories:
I hope these give you at least something to start from! |
That does help somewhat. I've considered instead just getting the HTML of my bookmarks per page using BS4 and requests to work around the request limit (I unfortunately have too many bookmarks), then fiddling around with some of AO3's methods afterwards. For the external bookmarks and uncaught exceptions, I fortunately do not have the former as far as I remember, but I'll keep that in mind moving forward. Thank you! |
The request limit is easily worked around by backing off for a few seconds when you encounter an error then retrying. Just write a wrapper to catch the |
A short prelude to say:
Summary
I'm trying to retrieve all my bookmarks, but I'm getting the following error:
I suspect this is due to some of my bookmarked works only being available to registered users. HOWEVER, I am passing a session when creating a user, so I'd assume it should be able to use this session to also retrieve the bookmarks.
Code
Additional Information
get_bookmarks()
method does not accept asession
argument and neither do_load_bookmarks()
andget_work_from_banner()
The text was updated successfully, but these errors were encountered: