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

Object_explorer is not working #54

Open
braiangama opened this issue Oct 4, 2016 · 4 comments
Open

Object_explorer is not working #54

braiangama opened this issue Oct 4, 2016 · 4 comments

Comments

@braiangama
Copy link

Hello,

I'm starting with the Py-StackExchange and when I run the object_explorer it shows me 256 site names from the StackExchange and after returns me this error:

Traceback (most recent call last):
File "object_explorer.py", line 162, in
site, site_def = choose_site()
File "object_explorer.py", line 34, in choose_site
print('%d) %s' % (i, site.name))
File "C:\Python27\lib\encodings\cp850.py", line 12, in encode
return codecs.charmap_encode(input,errors,encoding_map)
UnicodeEncodeError: 'charmap' codec can't encode characters in position 5-16: character maps to

How can I proceed?

I'm running it on Microsoft Windows 8.1

@peterbabinec
Copy link

Same issue here.

@goldiiman
Copy link

Another issue (maybe not related) on a Mac and Python 3+

Using the example code for object_explorer the output does not match the example

Should it not show Users object when dir after Users ?, output below:-

...
Site ID: 1 <------
Use function names you would when using the Site, etc. objects.
return: Move back up an object.
exit: Quits.
dir: Shows meaningful methods and properties on the current object.
dir_: Same as dir, but includes *all_ methods and properties.
code: Show the code you'd need to get to where you are now.
! before a non-function means "explore anyway."
a prompt ending in []> means the current item is a list.
Stack Overflow> user <------
<bound method Site.user of <stackexchange.site.Site object at 0x103d8bb00>>
Stack Overflow> dir
['all_badges', 'all_nontag_badges', 'all_tag_badges', 'all_tags', 'answer', 'answers', 'api_version', 'app_key', 'badge', 'badge_recipients', 'badges', 'be_inclusive', 'build', 'build_from_snippet', 'cache_options', 'check_filter', 'comment', 'comments', 'domain', 'error', 'force_http', 'impose_throttling', 'include_body', 'include_comments', 'info', 'moderators', 'moderators_elected', 'privileges', 'question', 'questions', 'recent_questions', 'revision', 'revisions', 'root_domain', 'search', 'search_advanced', 'similar', 'stats', 'tag', 'tag_related', 'tag_synonyms', 'tag_wiki', 'tags', 'throttle_stop', 'user', 'users', 'users_by_name', 'vectorise']
Stack Overflow>

@kumiDa
Copy link

kumiDa commented May 18, 2017

@goldiiman , I was able to go about this by providing a API key, this might seem naive but do give it a try.

@zlang19
Copy link

zlang19 commented Jun 21, 2018

@goldiiman same issue. After providing an API key, selecting StackOverflow, and trying to get a user, I am not prompted to input a nid(as shown on the wiki). It simply stats that user is a method.

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

5 participants