Commit 2ec3fe6
authored
fix(ssh): ssh.which returning None for POSIX paths when running on Windows (#2732)
* fix(ssh): use POSIX separator for path detection in ssh.which
On Windows, `os.path.sep` is '\\', which fails to detect POSIX paths.
Hardcoding '/' ensures consistent path detection since the `ssh`
module targets POSIX-compliant systems.
* Update CHANGELOG.md
* feat(context): add path_sep and pathlist_sep to context, make the path seperator dependent on the context.os
* fix(ssh): declare path separator as private member in ssh
* fix(ssh): remote path handling with pathlib
* fix(ssh): replace os.path.basename functions with pathlib for path handling
* fix(ssh): ensure remote paths are decoded to str1 parent f4205e5 commit 2ec3fe6
2 files changed
Lines changed: 22 additions & 11 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
136 | 136 | | |
137 | 137 | | |
138 | 138 | | |
| 139 | + | |
139 | 140 | | |
140 | 141 | | |
141 | 142 | | |
| |||
197 | 198 | | |
198 | 199 | | |
199 | 200 | | |
| 201 | + | |
200 | 202 | | |
201 | 203 | | |
202 | 204 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
| 3 | + | |
3 | 4 | | |
4 | 5 | | |
5 | 6 | | |
| |||
592 | 593 | | |
593 | 594 | | |
594 | 595 | | |
| 596 | + | |
| 597 | + | |
595 | 598 | | |
596 | 599 | | |
597 | 600 | | |
| |||
696 | 699 | | |
697 | 700 | | |
698 | 701 | | |
| 702 | + | |
| 703 | + | |
| 704 | + | |
| 705 | + | |
699 | 706 | | |
700 | 707 | | |
701 | 708 | | |
| |||
1122 | 1129 | | |
1123 | 1130 | | |
1124 | 1131 | | |
1125 | | - | |
| 1132 | + | |
1126 | 1133 | | |
1127 | 1134 | | |
1128 | 1135 | | |
| 1136 | + | |
1129 | 1137 | | |
1130 | 1138 | | |
1131 | 1139 | | |
1132 | | - | |
| 1140 | + | |
1133 | 1141 | | |
1134 | 1142 | | |
1135 | 1143 | | |
| |||
1471 | 1479 | | |
1472 | 1480 | | |
1473 | 1481 | | |
1474 | | - | |
1475 | | - | |
| 1482 | + | |
1476 | 1483 | | |
1477 | 1484 | | |
1478 | 1485 | | |
| |||
1541 | 1548 | | |
1542 | 1549 | | |
1543 | 1550 | | |
1544 | | - | |
| 1551 | + | |
| 1552 | + | |
1545 | 1553 | | |
1546 | 1554 | | |
1547 | 1555 | | |
| |||
1617 | 1625 | | |
1618 | 1626 | | |
1619 | 1627 | | |
| 1628 | + | |
| 1629 | + | |
1620 | 1630 | | |
1621 | | - | |
1622 | | - | |
| 1631 | + | |
| 1632 | + | |
| 1633 | + | |
1623 | 1634 | | |
1624 | 1635 | | |
1625 | 1636 | | |
| |||
1650 | 1661 | | |
1651 | 1662 | | |
1652 | 1663 | | |
1653 | | - | |
1654 | | - | |
1655 | | - | |
| 1664 | + | |
1656 | 1665 | | |
1657 | 1666 | | |
1658 | 1667 | | |
| |||
1909 | 1918 | | |
1910 | 1919 | | |
1911 | 1920 | | |
1912 | | - | |
| 1921 | + | |
1913 | 1922 | | |
1914 | 1923 | | |
1915 | 1924 | | |
| |||
0 commit comments