Skip to content

Commit

Permalink
Remove Python 2 handling code (#2098)
Browse files Browse the repository at this point in the history
* Remove Python 2 update modal

* Remove Python 2 handling code

* Remove backports dependencies

* Remove uses of future and __future__

* Fix import

* Remove requirements

* Update lib folder

* Clean up imports and blank lines

---------

Co-authored-by: JonnyWong16 <9099342+JonnyWong16@users.noreply.github.com>
  • Loading branch information
zdimension and JonnyWong16 committed May 10, 2024
1 parent dcec1f6 commit de3393d
Show file tree
Hide file tree
Showing 97 changed files with 7,442 additions and 2,916 deletions.
1 change: 0 additions & 1 deletion Tautulli.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@
# Ensure lib added to path, before any other imports
sys.path.insert(0, os.path.join(os.path.dirname(os.path.abspath(__file__)), 'lib'))

from future.builtins import str

import argparse
import datetime
Expand Down
34 changes: 0 additions & 34 deletions data/interfaces/default/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -212,28 +212,6 @@ <h4 class="modal-title">Raw Stream Info: <strong><span id="raw-stream-info-title
</div>
</div>
</div>
<% from plexpy.helpers import anon_url %>
<div id="python2-modal" class="modal fade wide" tabindex="-1" role="dialog" aria-labelledby="python2-modal">
<div class="modal-dialog" role="document">
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-hidden="true"><i class="fa fa-remove"></i></button>
<h4 class="modal-title">Unable to Update</h4>
</div>
<div class="modal-body" style="text-align: center;">
<p>Tautulli is still running using Python 2 and cannot be updated past v2.6.3.</p>
<p>Python 3 is required to continue receiving updates.</p>
<p>
<strong>Please see the <a href="${anon_url('https://github.com/Tautulli/Tautulli/wiki/Upgrading-to-Python-3-%28Tautulli-v2.5%29')}" target="_blank" rel="noreferrer">wiki</a>
for instructions on how to upgrade to Python 3.</strong>
</p>
</div>
<div class="modal-footer">
<input type="button" class="btn btn-bright" data-dismiss="modal" value="Close">
</div>
</div>
</div>
</div>
% endif

<div class="modal fade" id="ip-info-modal" tabindex="-1" role="dialog" aria-labelledby="ip-info-modal">
Expand Down Expand Up @@ -1067,16 +1045,4 @@ <h4 class="modal-title">Unable to Update</h4>
});
</script>
% endif
% if _session['user_group'] == 'admin':
<script>
const queryString = window.location.search;
const urlParams = new URLSearchParams(queryString);
if (urlParams.get('update') === 'python2') {
$("#python2-modal").modal({
backdrop: 'static',
keyboard: false
});
}
</script>
% endif
</%def>
2 changes: 1 addition & 1 deletion data/interfaces/default/newsletter_preview.html
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<%
from six.moves.urllib.parse import urlencode
from urllib.parse import urlencode
%>
<!doctype html>

Expand Down
2 changes: 1 addition & 1 deletion lib/backports/__init__.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__path__ = __import__('pkgutil').extend_path(__path__, __name__) # type: ignore
__path__ = __import__("pkgutil").extend_path(__path__, __name__)
Loading

0 comments on commit de3393d

Please sign in to comment.