Dax
fcbeaf3114
[Tweets] Fix tweet age calc for TZ!=UTC
...
dt is a naive datetime object, so its timezone is assumed to be the system timezone. However, the actual timezone from the API is UTC. Therefore, we need to set tzinfo before doing the calculation. See the note at https://docs.python.org/3/library/datetime.html#datetime.datetime.timestamp for more info.
Ideally this would be fixed in tweepy, but there's a report of this on forums from 7 years ago so let's just fix it in BitBot.
This bug found by an anonymous contributor. Thank you 😺 !
2020-11-05 06:00:45 +00:00
jesopo
49d9cbdb87
exports.get_one() -> exports.get()
2020-03-08 14:14:00 +00:00
jesopo
8f9c063114
only do to_pretty_time as relative when requested
2020-02-24 10:18:55 +00:00
jesopo
d0d5cc4d08
split utils.datetime out in to .parse and .format
2020-01-30 21:20:56 +00:00
jesopo
a4e827cbb5
switch tweets to use utils.datetime.to_pretty_time()
2020-01-28 15:31:49 +00:00
jesopo
5d01db8514
move all datetime-related code from utils/__init__ to utils.datetime
2019-11-15 13:59:09 +00:00
jesopo
f7aa56b8eb
also support twitter mobile urls
2019-10-20 17:10:01 +01:00
jesopo
0331b763ff
refactor multi-line-to-line normalisation to utils.parse.line_normalise(), use it in rss.py
...
closes #174
2019-10-10 10:33:18 +01:00
jesopo
5aba3f509e
format multi-line tweets on a single line using things like double spaces
2019-10-09 15:35:20 +01:00
jesopo
1b3ee1cb89
only show twitter url when one was not provided initially
2019-10-08 14:21:15 +01:00
jesopo
d8ad79c153
request tweet stream as tweet_mode="extended"
2019-09-25 15:03:43 +01:00
jesopo
d4bfde1a71
use tweet_mode="extended" for !tw user_timeline() calls too
2019-09-05 14:46:39 +01:00
jesopo
03c7e8f066
return matching string from buffer.find() as most uses were redundantly regexing
2019-08-13 13:48:03 +01:00
jesopo
5b1b26160a
use "extended" tweet mode so long tweets are not truncated
2019-07-15 14:27:37 +01:00
jesopo
ae9d099a41
Refactor set/channelset/serverset/botset in to 'utils.Setting' objects
2019-06-28 23:16:05 +01:00
jesopo
6a3af7f496
DEBUG log when we get a tweet from a stream
2019-06-28 07:24:06 +01:00
jesopo
1926aafacb
format._tweet()
takes a server
param now
2019-06-26 21:23:38 +01:00
jesopo
c5785a2d14
implement @utils.kwarg() magic, use it for command.regex hooks
2019-06-26 14:37:41 +01:00
jesopo
12181bfec6
Add system to have multiple url shorteners and chose which to use
2019-06-25 17:53:00 +01:00
jesopo
98e1202c78
Allow command.regex hooks to opt-in to being triggered from a /me
...
closes #68
2019-06-16 18:40:25 +01:00
jesopo
b782657b69
manage tweet thread ourselves to make sure it's a daemon
2019-06-09 15:15:50 +01:00
jesopo
62289ff41b
Remove debug print
2019-06-09 14:25:24 +01:00
jesopo
3a2404d1c9
Fixes for tweet streaming found from finally testing it
2019-06-07 22:01:13 +01:00
jesopo
2f6dda9030
First draft of following/unfollowing tweets in channels
2019-05-29 12:19:53 +01:00
jesopo
76b268e60e
Switch to using tweepy for tweets module
2019-05-27 14:52:08 +01:00