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 bug: sshMaxArg main function was using only the first profile #1363

Merged
merged 2 commits into from
Nov 17, 2022
Merged

Fix bug: sshMaxArg main function was using only the first profile #1363

merged 2 commits into from
Nov 17, 2022

Conversation

aryoda
Copy link
Contributor

@aryoda aryoda commented Nov 15, 2022

  • Now all profiles with ssh mode are probed for the max ssh cmd length
  • Code doc for config property "sshMaxArgLength" updated (used to generate man pages)
  • Fix some minor documentation issues
  • Unit tests did work

Output is now:

> python3 sshMaxArg.py
Profile 1 - Main profile: Mode = local
Profile 2 - profile 2: Mode = local
Profile 3 - test2config: Mode = local
Profile 4 - ext dev test: Mode = local
Profile 5 - ssh-hello-world: Mode = ssh
Tried length 1,048,320... Python exception: "Argument list too long". Decrease by 524,160 and try again.
Tried length 524,160... Python exception: "Argument list too long". Decrease by 262,080 and try again.
Tried length 262,080... Python exception: "Argument list too long". Decrease by 131,040 and try again.
Tried length 131,040... Can be longer. Increase by 65,520 and try again.
Tried length 196,560... Python exception: "Argument list too long". Decrease by 32,760 and try again.
Tried length 163,800... Python exception: "Argument list too long". Decrease by 16,380 and try again.
Tried length 147,420... Python exception: "Argument list too long". Decrease by 8,190 and try again.
Tried length 139,230... Python exception: "Argument list too long". Decrease by 4,095 and try again.
Tried length 135,135... Python exception: "Argument list too long". Decrease by 2,048 and try again.
Tried length 133,087... Python exception: "Argument list too long". Decrease by 1,024 and try again.
Tried length 132,063... Python exception: "Argument list too long". Decrease by 512 and try again.
Tried length 131,551... Python exception: "Argument list too long". Decrease by 256 and try again.
Tried length 131,295... Python exception: "Argument list too long". Decrease by 128 and try again.
Tried length 131,167... Python exception: "Argument list too long". Decrease by 64 and try again.
Tried length 131,103... Python exception: "Argument list too long". Decrease by 32 and try again.
Tried length 131,071... stderr: "/bin/bash: Argument list too long". Decrease by 16 and try again.
Tried length 131,055... Can be longer. Increase by 8 and try again.
Tried length 131,063... Can be longer. Increase by 4 and try again.
Tried length 131,067... stderr: "/bin/bash: Argument list too long". Decrease by 2 and try again.
Tried length 131,065... stderr: "/bin/bash: Argument list too long". Decrease by 1 and try again.
Tried length 131,064... Found correct length. Adding length of "printf" to it.
Maximum SSH command length between "mycomputer" and "localhost" is 131,070.

* Now all profiles with ssh mode are probed for the max ssh cmd length
* Code doc for config property "sshMaxArgLength" updated (used to generate man pages)
@aryoda aryoda requested a review from buhtz November 15, 2022 20:18
* Now all profiles with ssh mode are probed for the max ssh cmd length
* Code doc for config property "sshMaxArgLength" updated (used to generate man pages)
Copy link
Member

@buhtz buhtz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very fine. It's a pleasure to work with you together. I learn a lot. (And hopefully improve my English.) ;)

@aryoda aryoda merged commit 675c8b4 into bit-team:master Nov 17, 2022
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.

2 participants