Comments (12)
Hi, thanks for using the bot.
Yes, it is possible to self host, but it may be difficult as I am constantly updating the bot so you may run to some errors as the GitHub is not updated as frequently. You only need to create a config file with the bot token and if you want the Reddit command as well, you'll need to include the Reddit info as well to host it.
from coronavirus-bot.
Hi, thanks for the reply! Would you be able to give me a template of the config file? As for the reddit thing, do I need an api key?
from coronavirus-bot.
Yes, if you wish to use the Reddit command you would need to make an Reddit application for requests.
Format for the config file the format should be:
token = ' '
redditID = ' '
redditSecret = ' '
redditPW = ' '
user_agent = ' '
redditName = ' '
from coronavirus-bot.
ah ok, thanks for the info. I tried installing dependencies by running pip install -r requirements.txt
but it says "module google not found" when I run python covid-19.py
. I also tried pip install google
but same response. Any idea on how to fix this?
from coronavirus-bot.
@GenryMg I am hosting the bot on google cloud and I am using google logging as well. I didn't plan for people to self host so that is not in the requirements. If you wish you can get rid of all the logging (recommended option, unless you're planning to host on google as well). If you do host on google and want to log to it, then you have to install the library with pip install --upgrade google-cloud-logging
from coronavirus-bot.
I don't think I need the logging. Does the logging code only appear in covid-19.py? or is it all over the bot folder
from coronavirus-bot.
btw, I just remove this part right
import google.cloud.logging
from google.cloud.logging.handlers import CloudLoggingHandler
logging_client = google.cloud.logging.Client()
cloud_logger = logging_client.logger('covid-19')
logger = logging.getLogger('covid-19')
logger.setLevel(logging.DEBUG)
handler = CloudLoggingHandler(logging_client)
handler.setFormatter(logging.Formatter('%(asctime)s:%(levelname)s:%(name)s: %(message)s'))
logger.addHandler(handler)```
from coronavirus-bot.
Yes and any other instances of logging in the other files
from coronavirus-bot.
alright, thanks for your help! I will try again
from coronavirus-bot.
Uh, I tried to delete the lines dealing with logging. However, I don't know which ones to delete (Not familiar with GCP and google logging) Would you be able to tell me which files/lines I need to get rid of?
from coronavirus-bot.
Just CTRL+F anything with logger in in. Also, not to be rude, but as I said before I didn't plan for people to self host the bot so I can't help you with every issue.
from coronavirus-bot.
ok np. thanks for your help
from coronavirus-bot.
Related Issues (20)
- Keep the sources HOT 1
- US Recovery Rate Missing HOT 2
- Stats down HOT 2
- UK stat isn't consistent
- Bot Offline HOT 5
- .c graph doesn't support US States
- introduce <period> arg for `.c graph`
- Suggestion: display current cases at voice channel name HOT 5
- Bot is offline HOT 1
- error
- It can't be invited to a server. HOT 1
- Self host broken
- Suggestion: log scale option HOT 3
- Use API instead of GitHub files HOT 2
- No Graph HOT 3
- Feature request : growth factor value HOT 4
- Lost data for NJ HOT 5
- Data not showing for The Netherlands HOT 2
- Google HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from coronavirus-bot.