Content-Length: 264963 | pFad | http://github.com/coder/jetbrains-coder/issues/533

78 Add logging around CLI download fallback case · Issue #533 · coder/jetbrains-coder · GitHub
Skip to content

Add logging around CLI download fallback case #533

@angrycub

Description

@angrycub

In CoderCLIManager, we have a fallback behavior to download the CLI to the data-dir. We should log something somewhere to let folks know that this is happening.

// If downloads are enabled download the new version.
if (settings.enableDownloads) {
indicator?.invoke("Downloading Coder CLI...")
try {
cli.download()
return cli
} catch (e: java.nio.file.AccessDeniedException) {
// Might be able to fall back to the data directory.
val binPath = settings.binPath(deploymentURL)
val dataDir = settings.dataDir(deploymentURL)
if (binPath.parent == dataDir || !settings.enableBinaryDirectoryFallback) {
throw e
}
}
}
// Try falling back to the data directory.
val dataCLI = CoderCLIManager(deploymentURL, settings, true)
val dataCLIMatches = dataCLI.matchesVersion(buildVersion)
if (dataCLIMatches == true) {
return dataCLI
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions









      ApplySandwichStrip

      pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


      --- a PPN by Garber Painting Akron. With Image Size Reduction included!

      Fetched URL: http://github.com/coder/jetbrains-coder/issues/533

      Alternative Proxies:

      Alternative Proxy

      pFad Proxy

      pFad v3 Proxy

      pFad v4 Proxy