diff --git a/src/octoprint/comm/protocol/reprap/__init__.py b/src/octoprint/comm/protocol/reprap/__init__.py index 601212562..344a5804b 100644 --- a/src/octoprint/comm/protocol/reprap/__init__.py +++ b/src/octoprint/comm/protocol/reprap/__init__.py @@ -1217,7 +1217,7 @@ class ReprapGcodeProtocol( elif heater == "chamber": command = self.flavor.command_set_chamber_temp(temperature, wait=wait) else: - self._logger.warn( + self._logger.warning( "Got unknown heater identifier to set temperature on: {}".format(heater) ) return @@ -2156,7 +2156,7 @@ class ReprapGcodeProtocol( "Resetting state to be on the safe side." ) self.process_protocol_log(message) - self._logger.warn(message) + self._logger.warning(message) self._on_external_reset() diff --git a/src/octoprint/comm/transport/serialtransport.py b/src/octoprint/comm/transport/serialtransport.py index b9c16f4d5..8b5b57413 100644 --- a/src/octoprint/comm/transport/serialtransport.py +++ b/src/octoprint/comm/transport/serialtransport.py @@ -233,7 +233,7 @@ class SerialTransport(Transport): try: written += try_to_write(to_send) except serial.SerialTimeoutException: - self._logger.warn( + self._logger.warning( "Serial timeout while writing to serial port, trying again." ) try: @@ -256,8 +256,8 @@ class SerialTransport(Transport): passes += 1 if passes > self.max_write_passes: message = ( - "Could not write anything to the serial port in {} tries, something appears to be " - "wrong with the printer communication".format( + "Could not write anything to the serial port in {} tries, " + "something appears to be wrong with the communication".format( self.max_write_passes ) )