Commit 1f2a85e
fix(cli): clear stale last-used sandbox on deletion (#510)
* fix(cli): clear stale last-used sandbox on deletion
When a sandbox is deleted, the locally stored last-used record now gets
cleared if it matches the deleted sandbox name. This prevents subsequent
commands from falling back to a sandbox that no longer exists, which
previously caused confusing gRPC errors.
Adds clear_last_sandbox_if_matches() to openshell-bootstrap and calls
it from sandbox_delete() after each successful deletion.
Closes #172
Signed-off-by: Serge Panev <spanev@nvidia.com>
* style: fix rustfmt import ordering and line wrapping
Signed-off-by: Serge Panev <spanev@nvidia.com>
* fix(cli): pass gateway to sandbox_delete in finalize_sandbox_create_session
Signed-off-by: John Myers <johntmyers@users.noreply.github.com>
---------
Signed-off-by: Serge Panev <spanev@nvidia.com>
Signed-off-by: John Myers <johntmyers@users.noreply.github.com>
Co-authored-by: John Myers <johntmyers@users.noreply.github.com>1 parent 834f8aa commit 1f2a85e
File tree
4 files changed
+29
-10
lines changed- crates
- openshell-bootstrap/src
- openshell-cli/src
4 files changed
+29
-10
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
48 | 48 | | |
49 | 49 | | |
50 | 50 | | |
51 | | - | |
52 | | - | |
53 | | - | |
54 | | - | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
55 | 55 | | |
56 | 56 | | |
57 | 57 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
271 | 271 | | |
272 | 272 | | |
273 | 273 | | |
| 274 | + | |
| 275 | + | |
| 276 | + | |
| 277 | + | |
| 278 | + | |
| 279 | + | |
| 280 | + | |
| 281 | + | |
| 282 | + | |
| 283 | + | |
| 284 | + | |
| 285 | + | |
| 286 | + | |
| 287 | + | |
274 | 288 | | |
275 | 289 | | |
276 | 290 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2268 | 2268 | | |
2269 | 2269 | | |
2270 | 2270 | | |
2271 | | - | |
| 2271 | + | |
2272 | 2272 | | |
2273 | 2273 | | |
2274 | 2274 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
16 | 16 | | |
17 | 17 | | |
18 | 18 | | |
19 | | - | |
20 | | - | |
21 | | - | |
22 | | - | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
23 | 23 | | |
24 | 24 | | |
25 | 25 | | |
| |||
1904 | 1904 | | |
1905 | 1905 | | |
1906 | 1906 | | |
| 1907 | + | |
1907 | 1908 | | |
1908 | 1909 | | |
1909 | 1910 | | |
1910 | 1911 | | |
1911 | 1912 | | |
1912 | 1913 | | |
1913 | | - | |
| 1914 | + | |
1914 | 1915 | | |
1915 | 1916 | | |
1916 | 1917 | | |
| |||
2380 | 2381 | | |
2381 | 2382 | | |
2382 | 2383 | | |
| 2384 | + | |
2383 | 2385 | | |
2384 | 2386 | | |
2385 | 2387 | | |
| |||
2415 | 2417 | | |
2416 | 2418 | | |
2417 | 2419 | | |
| 2420 | + | |
2418 | 2421 | | |
2419 | 2422 | | |
2420 | 2423 | | |
| |||
2824 | 2827 | | |
2825 | 2828 | | |
2826 | 2829 | | |
| 2830 | + | |
2827 | 2831 | | |
2828 | 2832 | | |
2829 | 2833 | | |
| |||
2864 | 2868 | | |
2865 | 2869 | | |
2866 | 2870 | | |
| 2871 | + | |
2867 | 2872 | | |
2868 | 2873 | | |
2869 | 2874 | | |
| |||
0 commit comments