Skip to content

Commit

Permalink
Fix actions
Browse files Browse the repository at this point in the history
  • Loading branch information
gamecss committed Jul 22, 2023
1 parent 2209d63 commit ca9deef
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 3 deletions.
1 change: 1 addition & 0 deletions .github/workflows/python.yml
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ jobs:
id: build
run: |
pdm build
echo ::set-output name=exit_code::$?
- uses: actions/upload-artifact@v3
if: ${{ steps.build.outputs.exit_code == 0 }}
with:
Expand Down
15 changes: 12 additions & 3 deletions debug.patch
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
diff --git a/pyfsd/protocol/client.py b/pyfsd/protocol/client.py
index d9cdf55..8b8a770 100644
index d9cdf55..829c823 100644
--- a/pyfsd/protocol/client.py
+++ b/pyfsd/protocol/client.py
@@ -57,6 +57,21 @@ class FSDClientProtocol(LineReceiver):
Expand All @@ -9,7 +9,7 @@ index d9cdf55..8b8a770 100644
+ _write = self.transport.write
+
+ def writer(data: bytes) -> None:
+ host: str = self.transport.getPeer().host
+ host: str = self.transport.getPeer().host # type: ignore[attr-defined]
+ self.logger.debug(
+ "{time} {data} ===> {cs}",
+ time=time(),
Expand All @@ -24,6 +24,15 @@ index d9cdf55..8b8a770 100644

def sendLines(
self, *lines: bytes, auto_newline: bool = True, togerher: bool = True
@@ -232,7 +247,7 @@ class FSDClientProtocol(LineReceiver):

try:
cid_str = cid.decode("utf-8")
- pwd_str = password.decode("utf-8")
+ pwd_str = password.decode("utf-8") # noqa: F841
except UnicodeDecodeError:
self.sendError(FSDErrors.ERR_CIDINVALID, env=cid, fatal=True)
return
@@ -302,7 +317,8 @@ class FSDClientProtocol(LineReceiver):
)
self.factory.triggerEvent("newClientCreated", (self,), {})
Expand All @@ -38,7 +47,7 @@ index d9cdf55..8b8a770 100644
# Acquire without lock it (nearly)
pass

+ host: str = self.transport.getPeer().host
+ host: str = self.transport.getPeer().host # type: ignore[attr-defined]
+ self.logger.debug(
+ "{time} {line} <=== {cs}",
+ time=time(),
Expand Down

0 comments on commit ca9deef

Please sign in to comment.