Reddit-Bot | Making a Reddit Bot using Python | Bot library
kandi X-RAY | Reddit-Bot Summary
kandi X-RAY | Reddit-Bot Summary
This repo teaches you how to:. + Make a Reddit Bot using the [PRAW] (The Python Reddit API Wrapper) Python package + Deploy your Reddit Bot on [Heroku] - A platform as a service (PaaS) that enables developers to build, run, and operate applications entirely in the cloud + Install & use [Heroku Postgres] In this repo, I have made a Wordbook Bot which gives the meaning of particular word / phrase in the English / Slang language.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
- Run bot
- Reply to a given comment
- Dump a JSON object to a file
- Login to Reddit
Reddit-Bot Key Features
Reddit-Bot Examples and Code Snippets
Community Discussions
Trending Discussions on Reddit-Bot
QUESTION
I have Python27 installed in Windows 7
I am trying to build a reddit bot using this tutorial
I found instructions on how to install pip for windows from here
The page says that after installing pip, I can use pip freeze to check if the installation went correctly
It says pip freeze should display some information as shown below
Microsoft Windows [Version 6.2.9200] (c) 2012 Microsoft Corporation. All rights reserved.
C:\Users\Username>cd c:\Python27\Scripts
c:\Python27\Scripts>pip freeze
antiorm==1.1.1
enum34==1.0
requests==2.3.0 virtualenv==1.11.6
However pip freeze doesn't show me anything at all
Did pip install correctly, or is there any problem? Is there any other way i can test proper installation?
...ANSWER
Answered 2017-Jun-04 at 06:57If you want to test it thoroughly, you can use your actual pip installation to install something. For example, numpy would be a good sized example that can rule many problems out.
> pip install numpy
Now, run pip freeze
again to check if pip is working as expected. It should then have something to show.
If you want to test it even further, you can open a terminal and
QUESTION
I'm following along this tutorial: http://pythonforengineers.com/build-a-reddit-bot-part-1/ and in the Create Reddit App subsection it states that I should not have any login credentials directly in the script, because 'others might see them'.
Now, you need to update your praw ini file to remember these settings. Otherwise, you’ll have to put them in your script and thats dangerous (as others might see them).
Does my script get uploaded to Reddit, where it can then be read by other people? If not, why is it then unsafe?
...ANSWER
Answered 2018-Aug-23 at 18:20If you're only developing this bot as a proof of concept and always running it from the computer that you're developing it on there is little risk that your credentials will be leaked. However most code doesn't live it's life as only one copy on only one system. The vast majority of modern software development best practices are based around the assumption that different computers will develop the code, store versions of the code and actually run the code.
If you hard code your login credentials in your login script and are only running it from your computer this isn't going to be an issue. What if you need help debugging your bot? What if you're really proud of it and want to show it off? What if you want to store a backup on another system? What if you don't want to have it running on the same computer you developed it on? Suddenly code containing your login credentials are getting shared across multiple computers. The more systems your code is on the easier it will be for someone to get access to them. This is why it's a software development best practice to not hard code secrets, like login credentials, in scripts, or code.
In the case of the tutorial you're following they're instructing you to run your code on a VM and use git for source control. As soon as you commit your credentials into git they will always be a part of that repositories git history. If you ever host your repos on a remote system such as GitHub your credentials will be stored on a system outside your control.
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install Reddit-Bot
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page