Private GIT
Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
S
SickRage-1
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
vlbox
SickRage-1
Commits
a95d5ca9
Commit
a95d5ca9
authored
Oct 19, 2015
by
Dustyn Gibson
Browse files
Options
Downloads
Patches
Plain Diff
Limit twitter messages to 140 chars
Fixes
https://github.com/SiCKRAGETV/sickrage-issues/issues/3388
parent
fa18bcde
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
sickbeard/notifiers/tweet.py
+3
-3
3 additions, 3 deletions
sickbeard/notifiers/tweet.py
with
3 additions
and
3 deletions
sickbeard/notifiers/tweet.py
+
3
−
3
View file @
a95d5ca9
...
@@ -24,7 +24,7 @@ from sickrage.helper.exceptions import ex
...
@@ -24,7 +24,7 @@ from sickrage.helper.exceptions import ex
# parse_qsl moved to urlparse module in v2.6
# parse_qsl moved to urlparse module in v2.6
try
:
try
:
from
urlparse
import
parse_qsl
#@UnusedImport
from
urlparse
import
parse_qsl
#@UnusedImport
except
:
except
ImportError
:
from
cgi
import
parse_qsl
#@Reimport
from
cgi
import
parse_qsl
#@Reimport
import
oauth2
as
oauth
import
oauth2
as
oauth
...
@@ -128,7 +128,7 @@ class TwitterNotifier:
...
@@ -128,7 +128,7 @@ class TwitterNotifier:
api
=
twitter
.
Api
(
username
,
password
,
access_token_key
,
access_token_secret
)
api
=
twitter
.
Api
(
username
,
password
,
access_token_key
,
access_token_secret
)
try
:
try
:
api
.
PostUpdate
(
message
.
encode
(
'
utf8
'
))
api
.
PostUpdate
(
message
.
encode
(
'
utf8
'
)
[:
139
]
)
except
Exception
,
e
:
except
Exception
,
e
:
logger
.
log
(
u
"
Error Sending Tweet:
"
+
ex
(
e
),
logger
.
ERROR
)
logger
.
log
(
u
"
Error Sending Tweet:
"
+
ex
(
e
),
logger
.
ERROR
)
return
False
return
False
...
@@ -148,7 +148,7 @@ class TwitterNotifier:
...
@@ -148,7 +148,7 @@ class TwitterNotifier:
api
=
twitter
.
Api
(
username
,
password
,
access_token_key
,
access_token_secret
)
api
=
twitter
.
Api
(
username
,
password
,
access_token_key
,
access_token_secret
)
try
:
try
:
api
.
PostDirectMessage
(
dmdest
,
message
.
encode
(
'
utf8
'
))
api
.
PostDirectMessage
(
dmdest
,
message
.
encode
(
'
utf8
'
)
[:
139
]
)
except
Exception
,
e
:
except
Exception
,
e
:
logger
.
log
(
u
"
Error Sending Tweet (DM):
"
+
ex
(
e
),
logger
.
ERROR
)
logger
.
log
(
u
"
Error Sending Tweet (DM):
"
+
ex
(
e
),
logger
.
ERROR
)
return
False
return
False
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment