Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix #356 #617

Merged
merged 1 commit into from
Oct 13, 2024
Merged

Fix #356 #617

merged 1 commit into from
Oct 13, 2024

Conversation

DomiiBunn
Copy link
Contributor

Tick the checkbox if you understand [x]:

  • I have read and understand the pull request rules.

Description

Fixes #356

Added a more graceful disconnect when removing an agent to ensure socket.io is not in a "stuck" state where it attempts to keep an open connection to a deleted agent as well as a re-trigger of sendAgentList to ensure the UI has a quick update on agent deletion.

Type of change

  • Bug fix (non-breaking change which fixes an issue)

Checklist

  • My code follows the style guidelines of this project
  • I ran ESLint and other linters for modified files
  • I have performed a self-review of my own code and tested it
  • I have commented my code, particularly in hard-to-understand areas
    (including JSDoc for methods)
  • My changes generate no new warnings

@DomiiBunn
Copy link
Contributor Author

DomiiBunn commented Sep 24, 2024

I see https://github.com/louislam/dockge/actions/runs/11011056962/job/30574312169?pr=617#logs failing.

I did not change anything in the files it mentions so I don't know what happened exactly.

If someone else wants to fix that CI fail be my guest. I am fixing the issue I had with dockge spamming my DNS server with queries to no longer existing services.

@Jayllyz
Copy link

Jayllyz commented Sep 24, 2024

I see louislam/dockge/actions/runs/11011056962/job/30574312169?pr=617#logs failing.

I did not change anything in the files it mentions so I don't know what happened exactly.

If someone else wants to fix that CI fail be my guest. I am fixing the issue I had with dockge spamming my DNS server with queries to no longer existing services.

I assume that you are using Windows and your editor has formatted the file with CRLF.

pnpm run fmt should fix it. (if not https://stackoverflow.com/questions/27810758/how-to-replace-crlf-with-lf-in-a-single-file)

@DomiiBunn
Copy link
Contributor Author

Thanks @Jayllyz

Oddly enough nothing

domi > dockge >  (fix-for-#356) >  20.11.0 > 13:58 > npm run fmt

> [email protected] fmt
> eslint "**/*.{ts,vue}" --fix


/domi/projects/dockge/backend/log.ts
    6:14  warning  Identifier 'CONSOLE_STYLE_Reset' is not in camel case         camelcase
    7:14  warning  Identifier 'CONSOLE_STYLE_Bright' is not in camel case        camelcase
    8:14  warning  Identifier 'CONSOLE_STYLE_Dim' is not in camel case           camelcase
    9:14  warning  Identifier 'CONSOLE_STYLE_Underscore' is not in camel case    camelcase
   10:14  warning  Identifier 'CONSOLE_STYLE_Blink' is not in camel case         camelcase
   11:14  warning  Identifier 'CONSOLE_STYLE_Reverse' is not in camel case       camelcase
   12:14  warning  Identifier 'CONSOLE_STYLE_Hidden' is not in camel case        camelcase
   14:14  warning  Identifier 'CONSOLE_STYLE_FgBlack' is not in camel case       camelcase
   15:14  warning  Identifier 'CONSOLE_STYLE_FgRed' is not in camel case         camelcase
   16:14  warning  Identifier 'CONSOLE_STYLE_FgGreen' is not in camel case       camelcase
   17:14  warning  Identifier 'CONSOLE_STYLE_FgYellow' is not in camel case      camelcase
   18:14  warning  Identifier 'CONSOLE_STYLE_FgBlue' is not in camel case        camelcase
   19:14  warning  Identifier 'CONSOLE_STYLE_FgMagenta' is not in camel case     camelcase
   20:14  warning  Identifier 'CONSOLE_STYLE_FgCyan' is not in camel case        camelcase
   21:14  warning  Identifier 'CONSOLE_STYLE_FgWhite' is not in camel case       camelcase
   22:14  warning  Identifier 'CONSOLE_STYLE_FgGray' is not in camel case        camelcase
   23:14  warning  Identifier 'CONSOLE_STYLE_FgOrange' is not in camel case      camelcase
   24:14  warning  Identifier 'CONSOLE_STYLE_FgLightGreen' is not in camel case  camelcase
   25:14  warning  Identifier 'CONSOLE_STYLE_FgLightBlue' is not in camel case   camelcase
   26:14  warning  Identifier 'CONSOLE_STYLE_FgViolet' is not in camel case      camelcase
   27:14  warning  Identifier 'CONSOLE_STYLE_FgBrown' is not in camel case       camelcase
   28:14  warning  Identifier 'CONSOLE_STYLE_FgPink' is not in camel case        camelcase
   30:14  warning  Identifier 'CONSOLE_STYLE_BgBlack' is not in camel case       camelcase
   31:14  warning  Identifier 'CONSOLE_STYLE_BgRed' is not in camel case         camelcase
   32:14  warning  Identifier 'CONSOLE_STYLE_BgGreen' is not in camel case       camelcase
   33:14  warning  Identifier 'CONSOLE_STYLE_BgYellow' is not in camel case      camelcase
   34:14  warning  Identifier 'CONSOLE_STYLE_BgBlue' is not in camel case        camelcase
   35:14  warning  Identifier 'CONSOLE_STYLE_BgMagenta' is not in camel case     camelcase
   36:14  warning  Identifier 'CONSOLE_STYLE_BgCyan' is not in camel case        camelcase
   37:14  warning  Identifier 'CONSOLE_STYLE_BgWhite' is not in camel case       camelcase
   38:14  warning  Identifier 'CONSOLE_STYLE_BgGray' is not in camel case        camelcase
   41:5   warning  Identifier 'CONSOLE_STYLE_FgCyan' is not in camel case        camelcase
   42:5   warning  Identifier 'CONSOLE_STYLE_FgGreen' is not in camel case       camelcase
   43:5   warning  Identifier 'CONSOLE_STYLE_FgLightGreen' is not in camel case  camelcase
   44:5   warning  Identifier 'CONSOLE_STYLE_FgBlue' is not in camel case        camelcase
   45:5   warning  Identifier 'CONSOLE_STYLE_FgLightBlue' is not in camel case   camelcase
   46:5   warning  Identifier 'CONSOLE_STYLE_FgMagenta' is not in camel case     camelcase
   47:5   warning  Identifier 'CONSOLE_STYLE_FgOrange' is not in camel case      camelcase
   48:5   warning  Identifier 'CONSOLE_STYLE_FgViolet' is not in camel case      camelcase
   49:5   warning  Identifier 'CONSOLE_STYLE_FgBrown' is not in camel case       camelcase
   50:5   warning  Identifier 'CONSOLE_STYLE_FgPink' is not in camel case        camelcase
   54:13  warning  Identifier 'CONSOLE_STYLE_FgCyan' is not in camel case        camelcase
   55:13  warning  Identifier 'CONSOLE_STYLE_FgYellow' is not in camel case      camelcase
   56:14  warning  Identifier 'CONSOLE_STYLE_FgRed' is not in camel case         camelcase
   57:14  warning  Identifier 'CONSOLE_STYLE_FgGray' is not in camel case        camelcase
  127:24  warning  Identifier 'CONSOLE_STYLE_FgCyan' is not in camel case        camelcase
  127:53  warning  Identifier 'CONSOLE_STYLE_Reset' is not in camel case         camelcase
  128:57  warning  Identifier 'CONSOLE_STYLE_Reset' is not in camel case         camelcase
  129:54  warning  Identifier 'CONSOLE_STYLE_Reset' is not in camel case         camelcase
  138:27  warning  Identifier 'CONSOLE_STYLE_FgRed' is not in camel case         camelcase
  138:55  warning  Identifier 'CONSOLE_STYLE_Reset' is not in camel case         camelcase
  145:28  warning  Identifier 'CONSOLE_STYLE_FgGray' is not in camel case        camelcase
  145:57  warning  Identifier 'CONSOLE_STYLE_Reset' is not in camel case         camelcase
  148:31  warning  Identifier 'CONSOLE_STYLE_FgGray' is not in camel case        camelcase
  148:60  warning  Identifier 'CONSOLE_STYLE_Reset' is not in camel case         camelcase

/domi/projects/dockge/backend/socket-handlers/main-socket-handler.ts
  7:28  warning  'twoFaRateLimiter' is defined but never used  no-unused-vars
  7:28  warning  'twoFaRateLimiter' is defined but never used  @typescript-eslint/no-unused-vars

/domi/projects/dockge/backend/stack.ts
  15:5  warning  'PROGRESS_TERMINAL_ROWS' is defined but never used  no-unused-vars
  15:5  warning  'PROGRESS_TERMINAL_ROWS' is defined but never used  @typescript-eslint/no-unused-vars

/domi/projects/dockge/backend/util-server.ts
  3:10  warning  'randomBytes' is defined but never used  no-unused-vars
  3:10  warning  'randomBytes' is defined but never used  @typescript-eslint/no-unused-vars

/domi/projects/dockge/frontend/src/components/Terminal.vue
  21:9  warning  Prop 'name' requires default value to be set         vue/require-default-prop
  26:9  warning  Prop 'endpoint' requires default value to be set     vue/require-default-prop
  32:9  warning  Prop 'stackName' requires default value to be set    vue/require-default-prop
  37:9  warning  Prop 'serviceName' requires default value to be set  vue/require-default-prop

/domi/projects/dockge/frontend/src/pages/Compose.vue
   66:28  warning  Variable 'url' is already declared in the upper scope       vue/no-template-shadow
  101:60  warning  Variable 'endpoint' is already declared in the upper scope  vue/no-template-shadow

/domi/projects/dockge/frontend/src/pages/DashboardHome.vue
  43:38  warning  Variable 'agent' is already declared in the upper scope  vue/no-template-shadow

✖ 68 problems (0 errors, 68 warnings)

domi > dockge >  (fix-for-#356) >  20.11.0 > 13:58 > git add .
domi > dockge >  (fix-for-#356) >  20.11.0 > 13:59 > git commit -m "Fix New Lines"
On branch fix-for-#356
Your branch is up to date with 'origin/fix-for-#356'.

nothing to commit, working tree clean

This is confusing me as my previous commit didn't even touch these files.

@louislam louislam merged commit 9e89f49 into louislam:master Oct 13, 2024
6 checks passed
@DomiiBunn DomiiBunn deleted the fix-for-#356 branch October 13, 2024 15:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[agents] Error from the socket server after agent removed
3 participants