Giter Club home page Giter Club logo

tweetstats's People

Contributors

brawl345 avatar deathbybandaid avatar jmcq87 avatar mwoolweaver avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Forkers

jmcq87 jwshields

tweetstats's Issues

json.decoder.JSONDecodeError: Expecting ',' delimiter: line 22 column 5 (char 895)

When i run the python 3 script i get the following error. Do you know how to fix?

~/tweetStats $ python3 tweetStats.py
0
Traceback (most recent call last):
File "tweetStats.py", line 40, in
main()
File "tweetStats.py", line 36, in main
tweet_it(ga(cfgt()))
File "/home/pi/tweetStats/lib/get_config.py", line 39, in get_cfgt
cfg = js.load(data)
File "/usr/lib/python3.7/json/init.py", line 296, in load
parse_constant=parse_constant, object_pairs_hook=object_pairs_hook, **kw)
File "/usr/lib/python3.7/json/init.py", line 348, in loads
return _default_decoder.decode(s)
File "/usr/lib/python3.7/json/decoder.py", line 337, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File "/usr/lib/python3.7/json/decoder.py", line 353, in raw_decode
obj, end = self.scan_once(s, idx)
json.decoder.JSONDecodeError: Expecting ',' delimiter: line 22 column 5 (char 895)

See attachment for the pythonscript trowing the error. Cant find out where it goes wrong, the [ ] and ( ) and all the comma's are used correctly. Please help
Knipsel

cronjob running from a script

Hi there, its me again :). When a cronjob has to run multiple local scripts in Debian it cant find the rest of the file in Debian/Raspbian. I always have to make a bash script for it like the one below. If you are interested you can use it in your tweetStats ๐Ÿ‘ .

Cronjob

Run: sudo crontab -e
Add the following line: 00 12 * * * sudo bash /home/pi/tweetStats/tweetStats.sh >> /home/pi/tweetStats/tweetStat/twitter_bot.txt 2>&1

Bash script tweetstats.sh

#!/bin/bash
cd /home/pi/tweetStats
sudo python3 /home/pi/tweetStats/tweetStats.py
cd ~


When i run your script I get the follow error

Debug Variable = 0
tweetStats.py -h for more info
[{'code': 89, 'message': 'Invalid or expired token.'}]This your down fall
[{'code': 89, 'message': 'Invalid or expired token.'}]This your down fall
Traceback (most recent call last):
File "/home/pi/Desktop/tweetStats/tweetStats.py", line 46, in
main()
File "/home/pi/Desktop/tweetStats/tweetStats.py", line 42, in main
tweet_it(ga(cfgt()))
File "/home/pi/Desktop/tweetStats/tweetStats.py", line 14, in tweet_it
print(ga(cfgt())[3])
TypeError: 'NoneType' object is not subscriptable

I think its a typo somewhere. Will look more into it after work :)!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.