Skip to content

Commit f83e138

Browse files
committed
Lint fixes
1 parent 0653931 commit f83e138

File tree

4 files changed

+6
-7
lines changed

4 files changed

+6
-7
lines changed

moonraker_octoeverywhere/moonrakerclient.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ def GetIsKlippyReady(self) -> bool:
111111

112112
# Actually starts the client running, trying to connect the websocket and such.
113113
# This is done after the first connection to OctoEverywhere has been established, to ensure
114-
# the connection is setup before this, incase something needs to use it.
114+
# the connection is setup before this, in case something needs to use it.
115115
def StartRunningIfNotAlready(self, octoKey:str) -> None:
116116
# Always update the octokey, to make sure we are current.
117117
self.MoonrakerCompat.SetOctoKey(octoKey)
@@ -641,7 +641,7 @@ def _TryToGetWebsocketAuth(self) -> bool:
641641
return True
642642

643643
# If we didn't get an new API key, try to get a oneshot token.
644-
# Note that we might already have an existing Moonraker API key, so we will include it incase.
644+
# Note that we might already have an existing Moonraker API key, so we will include it in case.
645645
#
646646
# For some systems we need auth for the websocket, but no auth for the oneshot token API, which makes no sense.
647647
# But if that's the case, we try to get a one_shot token.

moonraker_octoeverywhere/moonrakerhost.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -320,7 +320,7 @@ def OnPrimaryConnectionEstablished(self, octoKey:str, connectedAccounts:List[str
320320
LinkHelper.RunLinkPluginConsolePrinterAsync(self.Logger, printerId, "moonraker_host")
321321

322322
# Now that we are connected, start the moonraker client.
323-
# We do this after the connection incase it needs to send any notifications or messages when starting.
323+
# We do this after the connection in case it needs to send any notifications or messages when starting.
324324
MoonrakerClient.Get().StartRunningIfNotAlready(octoKey)
325325

326326

octoeverywhere/sentry.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -133,8 +133,7 @@ def _setupSentryInternal(versionString:str, distType:str, isDevMode:bool, canEna
133133
environment= "dev" if isDevMode else "production",
134134
before_send= Sentry._beforeSendFilter,
135135
sample_rate= errorSampleRate,
136-
# Only enable these if we enable profiling. We can't do it in OctoPrint, because it picks up a lot of OctoPrint functions.
137-
enable_tracing= True if tracingSampleRate > 0.0 else False,
136+
enable_tracing= tracingSampleRate > 0.0,
138137
traces_sample_rate= tracingSampleRate,
139138
profiles_sample_rate= profilingSampleRate,
140139
)
@@ -355,4 +354,4 @@ def IsCommonConnectionException(e:Exception) -> bool:
355354
return True
356355
except Exception:
357356
pass
358-
return False
357+
return False

octoeverywhere/websocketimpl.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -300,7 +300,7 @@ def _SendQueueThread(self):
300300
self.handleWsError(e)
301301
finally:
302302
# When the send queue closes, make sure the websocket is closed.
303-
# This is a safety, incase for some reason the websocket was open and we were told to close.
303+
# This is a safety, in case for some reason the websocket was open and we were told to close.
304304
self._Close()
305305

306306

0 commit comments

Comments
 (0)