|
17 | 17 | import ch.cyberduck.core.exception.BackgroundException; |
18 | 18 | import ch.cyberduck.core.vault.VaultException; |
19 | 19 | import ch.cyberduck.core.vault.VaultRegistry; |
| 20 | +import ch.cyberduck.core.vault.VaultUnlockCancelException; |
20 | 21 |
|
21 | 22 | import org.apache.http.HttpStatus; |
22 | 23 | import org.apache.logging.log4j.LogManager; |
@@ -75,13 +76,19 @@ public AttributedList<Path> list(final Path directory, final ListProgressListene |
75 | 76 | throw new VaultException(String.format("Unsupported storage configuration %s", storageProfile.getProtocol().name())); |
76 | 77 | } |
77 | 78 | final HubUVFVault vault = new HubUVFVault(vaultDto.getId(), vaultMetadata.storage().getDefaultPath()); |
78 | | - registry.add(vault.load(session, prompt)); |
79 | | - vaults.add(vault.getHome()); |
80 | | - listener.chunk(directory, vaults); |
| 79 | + try { |
| 80 | + registry.add(vault.load(session, prompt)); |
| 81 | + vaults.add(vault.getHome()); |
| 82 | + listener.chunk(directory, vaults); |
| 83 | + } |
| 84 | + catch(VaultUnlockCancelException e) { |
| 85 | + log.warn("Skip vault {} with failure {} loading", vaultDto, e); |
| 86 | + continue; |
| 87 | + } |
81 | 88 | } |
82 | 89 | catch(ApiException e) { |
83 | 90 | if(HttpStatus.SC_FORBIDDEN == e.getCode()) { |
84 | | - log.warn("Skip vault {} with insufficient permissions", vaultDto); |
| 91 | + log.warn("Skip vault {} with insufficient permissions {}", vaultDto, e); |
85 | 92 | continue; |
86 | 93 | } |
87 | 94 | throw e; |
|
0 commit comments