Skip to content

Commit

Permalink
Remove kodi_six: import directly
Browse files Browse the repository at this point in the history
  • Loading branch information
oddstr13 committed Jun 11, 2024
1 parent 8cabd4e commit cd53329
Show file tree
Hide file tree
Showing 26 changed files with 51 additions and 26 deletions.
4 changes: 3 additions & 1 deletion jellyfin_kodi/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,9 @@

import os

from kodi_six import xbmc, xbmcaddon, xbmcvfs
import xbmc
import xbmcaddon
import xbmcvfs

from .helper import translate, window, settings, addon_id, dialog, LazyLogger
from .helper.utils import create_id, translate_path
Expand Down
3 changes: 2 additions & 1 deletion jellyfin_kodi/connect.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@

##################################################################################################

from kodi_six import xbmc, xbmcaddon
import xbmc
import xbmcaddon

from . import client
from .database import get_credentials, save_credentials
Expand Down
3 changes: 2 additions & 1 deletion jellyfin_kodi/database/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@
import sys
import re

from kodi_six import xbmc, xbmcvfs
import xbmc
import xbmcvfs

from . import jellyfin_db
from ..helper import translate, settings, window, dialog
Expand Down
3 changes: 2 additions & 1 deletion jellyfin_kodi/dialogs/context.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@

import os

from kodi_six import xbmcgui, xbmcaddon
import xbmcgui
import xbmcaddon

from ..helper import window, addon_id
from ..helper import LazyLogger
Expand Down
2 changes: 1 addition & 1 deletion jellyfin_kodi/dialogs/loginmanual.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

##################################################################################################

from kodi_six import xbmcgui
import xbmcgui

from ..helper import translate, LazyLogger, kodi_version

Expand Down
3 changes: 2 additions & 1 deletion jellyfin_kodi/dialogs/resume.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@

##################################################################################################

from kodi_six import xbmc, xbmcgui
import xbmc
import xbmcgui

from ..helper import LazyLogger

Expand Down
3 changes: 2 additions & 1 deletion jellyfin_kodi/dialogs/serverconnect.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@

##################################################################################################

from kodi_six import xbmc, xbmcgui
import xbmc
import xbmcgui

from ..helper import translate
from ..jellyfin.connection_manager import CONNECTION_STATE
Expand Down
2 changes: 1 addition & 1 deletion jellyfin_kodi/dialogs/servermanual.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

import re

from kodi_six import xbmcgui
import xbmcgui

from ..helper import translate
from ..jellyfin.connection_manager import CONNECTION_STATE
Expand Down
2 changes: 1 addition & 1 deletion jellyfin_kodi/dialogs/usersconnect.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

##################################################################################################

from kodi_six import xbmcgui
import xbmcgui

from ..helper import LazyLogger
from ..helper.utils import kodi_version
Expand Down
3 changes: 2 additions & 1 deletion jellyfin_kodi/entrypoint/context.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@
import json
import sys

from kodi_six import xbmc, xbmcaddon
import xbmc
import xbmcaddon

from .. import database
from ..dialogs import context
Expand Down
6 changes: 5 additions & 1 deletion jellyfin_kodi/entrypoint/default.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,11 @@
import os
from urllib.parse import parse_qsl, urlencode

from kodi_six import xbmc, xbmcvfs, xbmcgui, xbmcplugin, xbmcaddon
import xbmc
import xbmcvfs
import xbmcgui
import xbmcplugin
import xbmcaddon

from .. import client
from ..database import reset, get_sync, Database, jellyfin_db, get_credentials
Expand Down
3 changes: 2 additions & 1 deletion jellyfin_kodi/entrypoint/service.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@

# Workaround for threads using datetime: _striptime is locked
import _strptime # noqa:F401
from kodi_six import xbmc, xbmcgui
import xbmc
import xbmcgui

from .. import objects
from .. import connect
Expand Down
2 changes: 1 addition & 1 deletion jellyfin_kodi/full_sync.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
from contextlib import contextmanager
import datetime

from kodi_six import xbmc
import xbmc

from . import downloader as server
from .objects import Movies, TVShows, MusicVideos, Music
Expand Down
3 changes: 2 additions & 1 deletion jellyfin_kodi/helper/loghandler.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,8 @@
import logging
import traceback

from kodi_six import xbmc, xbmcaddon
import xbmc
import xbmcaddon

from .. import database
from . import settings, kodi_version
Expand Down
3 changes: 2 additions & 1 deletion jellyfin_kodi/helper/playutils.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,8 @@
from uuid import uuid4

import requests
from kodi_six import xbmc, xbmcvfs
import xbmc
import xbmcvfs

from .. import client
from .utils import translate_path
Expand Down
3 changes: 2 additions & 1 deletion jellyfin_kodi/helper/translate.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@

##################################################################################################

from kodi_six import xbmc, xbmcaddon
import xbmc
import xbmcaddon

from . import LazyLogger

Expand Down
5 changes: 4 additions & 1 deletion jellyfin_kodi/helper/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,10 @@

from dateutil import tz, parser

from kodi_six import xbmc, xbmcaddon, xbmcgui, xbmcvfs
import xbmc
import xbmcaddon
import xbmcgui
import xbmcvfs

from . import LazyLogger
from .translate import translate
Expand Down
2 changes: 1 addition & 1 deletion jellyfin_kodi/helper/wrapper.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

#################################################################################################

from kodi_six import xbmcgui
import xbmcgui

from . import LazyLogger

Expand Down
3 changes: 2 additions & 1 deletion jellyfin_kodi/helper/xmls.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@
import os
import xml.etree.ElementTree as etree

from kodi_six import xbmc, xbmcvfs
import xbmc
import xbmcvfs

from .utils import translate_path
from . import translate, dialog, settings, LazyLogger
Expand Down
2 changes: 1 addition & 1 deletion jellyfin_kodi/jellyfin/ws_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
import threading
import time

from kodi_six import xbmc
import xbmc

from ..helper import LazyLogger, settings

Expand Down
3 changes: 2 additions & 1 deletion jellyfin_kodi/library.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@

import queue

from kodi_six import xbmc, xbmcgui
import xbmc
import xbmcgui

from .objects import Movies, TVShows, MusicVideos, Music
from .objects.kodi import Movies as KodiDb
Expand Down
2 changes: 1 addition & 1 deletion jellyfin_kodi/monitor.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
import json
import threading

from kodi_six import xbmc
import xbmc

from . import connect
from . import player
Expand Down
5 changes: 4 additions & 1 deletion jellyfin_kodi/objects/actions.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,10 @@
import json
from datetime import timedelta

from kodi_six import xbmc, xbmcgui, xbmcplugin, xbmcaddon
import xbmc
import xbmcgui
import xbmcplugin
import xbmcaddon

from ..helper import translate, playutils, api, window, settings, dialog
from ..dialogs import resume
Expand Down
3 changes: 2 additions & 1 deletion jellyfin_kodi/player.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@

import os

from kodi_six import xbmc, xbmcvfs
import xbmc
import xbmcvfs

from .objects.obj import Objects
from .helper import translate, api, window, settings, dialog, event, JSONRPC
Expand Down
2 changes: 1 addition & 1 deletion jellyfin_kodi/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
import xml.etree.ElementTree as etree
from urllib.parse import urlencode

from kodi_six import xbmcvfs
import xbmcvfs

from .database import Database, jellyfin_db, get_sync, save_sync
from .helper import translate, api, window, event
Expand Down
2 changes: 1 addition & 1 deletion service.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

import threading

from kodi_six import xbmc
import xbmc

from jellyfin_kodi.entrypoint.service import Service
from jellyfin_kodi.helper.utils import settings
Expand Down

0 comments on commit cd53329

Please sign in to comment.