Modified refs to hold Twitter modules to use the new sessions package

This commit is contained in:
Manuel Cortez 2018-08-16 17:26:19 -05:00
parent 1e27056902
commit 0966739296
5 changed files with 9 additions and 10 deletions

View File

@ -18,11 +18,11 @@ import sound
import languageHandler
import logging
import youtube_utils
from twitter import compose, utils
from sessions.twitter import compose, utils
from mysc.thread_utils import call_threaded
from twython import TwythonError
from pubsub import pub
from long_tweets import twishort, tweets
from sessions.twitter.long_tweets import twishort, tweets
log = logging.getLogger("controller.buffers")

View File

@ -3,7 +3,7 @@ import widgetUtils
import output
from wxUI.dialogs import lists
from twython import TwythonError
from twitter import compose, utils
from sessions.twitter import compose, utils
from pubsub import pub
class listsController(object):

View File

@ -18,7 +18,7 @@ if system == "Windows":
# from issueReporter import issueReporter
elif system == "Linux":
from gtkUI import (view, commonMessageDialogs)
from twitter import utils, compose
from sessions.twitter import utils, compose
from sessionmanager import manager, sessionManager
import buffersController

View File

@ -17,7 +17,7 @@ if system == "Windows":
from extra.AudioUploader import audioUploader
elif system == "Linux":
from gtkUI.dialogs import message
from twitter import utils
from sessions.twitter import utils
class basicTweet(object):
""" This class handles the tweet main features. Other classes should derive from this class."""

View File

@ -3,7 +3,6 @@
import wx
import urllib2
import config
import twitter
from keys import keyring
import session_exceptions as Exceptions
import paths
@ -11,7 +10,7 @@ import output
import time
import sound
import logging
from twitter import utils, compose
from sessions.twitter import client, utils, compose
from twython import TwythonError, TwythonRateLimitError, TwythonAuthError
import config_utils
import shelve
@ -20,7 +19,7 @@ import os
from mysc.thread_utils import stream_threaded, call_threaded
from pubsub import pub
log = logging.getLogger("sessionmanager.session")
from long_tweets import tweets, twishort
from sessions.twitter.long_tweets import tweets, twishort
from wxUI import authorisationDialog
sessions = {}
@ -136,7 +135,7 @@ class Session(object):
self.session_id = session_id
self.logged = False
self.settings = None
self.twitter = twitter.twitter.twitter()
self.twitter = client.twitter()
self.db={}
self.reconnection_function_active = False
self.counter = 0
@ -380,7 +379,7 @@ class Session(object):
log.debug("Restarting connection after 5 minutes.")
del self.twitter
self.logged = False
self.twitter = twitter.twitter.twitter()
self.twitter = client.twitter()
self.login(False)
self.counter = 0
if self.reconnection_function_active == True: return