fix: remove references, dependency for six
package
This commit is contained in:
parent
ff0af6732a
commit
f36759dc48
|
@ -24,7 +24,6 @@ classifiers = [
|
|||
]
|
||||
dependencies = [
|
||||
"rattail[db]",
|
||||
"six",
|
||||
"sqlsoup",
|
||||
]
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
################################################################################
|
||||
#
|
||||
# Rattail -- Retail Software Framework
|
||||
# Copyright © 2010-2018 Lance Edgar
|
||||
# Copyright © 2010-2024 Lance Edgar
|
||||
#
|
||||
# This file is part of Rattail.
|
||||
#
|
||||
|
@ -24,13 +24,10 @@
|
|||
Tempmon server daemon
|
||||
"""
|
||||
|
||||
from __future__ import unicode_literals, absolute_import
|
||||
|
||||
import time
|
||||
import datetime
|
||||
import logging
|
||||
|
||||
import six
|
||||
import humanize
|
||||
from sqlalchemy import orm
|
||||
from sqlalchemy.exc import OperationalError
|
||||
|
@ -91,7 +88,7 @@ class TempmonServerDaemon(Daemon):
|
|||
# first time after DB stop. but in the case of DB stop,
|
||||
# subsequent errors will instead match the second test
|
||||
if error.connection_invalidated or (
|
||||
'could not connect to server: Connection refused' in six.text_type(error)):
|
||||
'could not connect to server: Connection refused' in str(error)):
|
||||
|
||||
# only suppress logging for 3 failures, after that we let them go
|
||||
# TODO: should make the max attempts configurable
|
||||
|
@ -99,7 +96,7 @@ class TempmonServerDaemon(Daemon):
|
|||
log_error = False
|
||||
log.debug("database connection failure #%s: %s",
|
||||
self.failed_checks,
|
||||
six.text_type(error))
|
||||
str(error))
|
||||
|
||||
# send error email unless we're suppressing it for now
|
||||
if log_error:
|
||||
|
|
Loading…
Reference in a new issue