Skip to content

go module github.com/databricks/cli contains invalid paths when importing as dependency #1629

@sgerloff

Description

@sgerloff

Describe the issue

Inspired by my feature request, I wanted to explore building the functionality myself using github.com/databricks/cli/libs as a dependency to build on top. In essence, exposing your github.com/databricks/cli/libs as valid go modules enables your customers with special needs and fosters a community that voluntarily owns functionality you do not want to maintain.

Steps to reproduce the behavior

  1. Create dummy go project: go mod init whatever
  2. Add databricks cli as dependency go get github.com/databricks/cli

Expected Behavior

go get github.com/databricks/cli finishes without error

Actual Behavior

go get github.com/databricks/cli finishes with error:

go: downloading github.com/databricks/cli v0.224.1
go: github.com/databricks/cli/libs: create zip: libs/template/testdata/template-in-path/template/{{template `dir_name`}}/{{template `file_name`}}: malformed file path "libs/template/testdata/template-in-path/template/{{template `dir_name`}}/{{template `file_name`}}": invalid char '`'
libs/template/testdata/templated-defaults/template/{{template `dir_name`}}/{{template `file_name`}}: malformed file path "libs/template/testdata/templated-defaults/template/{{template `dir_name`}}/{{template `file_name`}}": invalid char '`'

Note

  • It's okay if you don't want to support this usage
  • This should not be read as an escalation of the previous issue, as I am just curious to play with go and find this is a good excuse.
  • I hope this is a trivial fix where ill-formed test data is excluded from the go modules archive.

Metadata

Metadata

Assignees

Labels

BugSomething isn't workingCLICLI related issues

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions