Fixing error: praw.exceptions.ClientException: Required configuration setting ‘client_id’ missing.

If you use a project on Github that uses the Reddit API, you can get errors like this:

Traceback (most recent call last):
  File "subredditarchive.py", line 23, in 
    r = praw.Reddit(useragent='searchandarchive by ')
  File "/usr/local/lib/python2.7/dist-packages/praw-4.0.0b17-py2.7.egg/praw/reddit.py", line 101, in __init__
    raise ClientException(required_message.format(attribute))
praw.exceptions.ClientException: Required configuration setting 'client_id' missing.
This setting can be provided in a praw.ini file, as a keyword argument to the `Reddit` class constructor, or as an environment variable.

The API library in Python is called “praw” – you most likely have the wrong version.

To see the version, do this:

pip freeze | grep praw

Then uninstall:

pip uninstall praw

Then install the right version:

easy_install praw==3.5.0

One Reply to “Fixing error: praw.exceptions.ClientException: Required configuration setting ‘client_id’ missing.”

Leave a Reply

Your email address will not be published. Required fields are marked *