Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Failed to get version when building charm with version 3.0.7 #673

Open
dosaboy opened this issue Apr 18, 2024 · 4 comments
Open

Failed to get version when building charm with version 3.0.7 #673

dosaboy opened this issue Apr 18, 2024 · 4 comments

Comments

@dosaboy
Copy link

dosaboy commented Apr 18, 2024

Using charm-tools 3.0.7 (+git-0-b7128ec)

Getting the following error building the ovn-central charm:

:: charmtools.build.tactics: Copying Interface prometheus_scrape: /root/parts/charm/build/ovn-central/hooks/relations/prometheus_scrape
:: charmtools.build.tactics: Trying to determine version with: git
:: utils: b'fatal: not a git repository (or any of the parent directories): .git\n'
:: utils: process: git describe --dirty --always (128)
:: charmtools.build.tactics: Failed to get version
:: charmtools.build.tactics: Trying to determine version with: bzr
:: charmtools.build.tactics: [Errno 2] No such file or directory: 'bzr'
:: charmtools.build.tactics: Trying to determine version with: hg
:: charmtools.build.tactics: [Errno 2] No such file or directory: 'hg'
:: build:
:: build: ---------------------------------------
:: build: Build Report
:: build: ---------------------------------------
:: build: New build; all files were modified.
:: build: Cleaning up /root/.cache/charm/977
:: proof: I: display-name not provided, add for custom naming in the UI
:: proof: I: DEPRECATED: series parameter is ignored by charmcraft,use bases in charmcraft.yaml

@dosaboy
Copy link
Author

dosaboy commented Apr 18, 2024

The above was from charmcraft, if i run it manually it fails at the same point:

$ charm build
build: Build dir not specified via command-line or environment; defaulting to /tmp/charm-builds
build: The lockfile /home/ubuntu/git/ovn-central/src/build.lock was not found; building using latest versions.
build: Destination charm directory: /tmp/charm-builds/ovn-central
build: Processing layer: layer:options
build: Processing layer: layer:basic
build: Processing layer: layer:openstack
build: Processing layer: layer:leadership
build: Processing layer: layer:coordinator
build: Processing layer: layer:snap
build: Processing layer: ovn-central (from .)
build: Processing interface: tls-certificates
build: Processing interface: nrpe-external-master
build: Processing interface: ovsdb
build: Processing interface: ovsdb-cluster
build: Processing interface: ovsdb-cluster
build: Processing interface: ovsdb-cms
build: Processing interface: prometheus_scrape
^\/snap/charm/745/bin/wrappers/charm: line 84: 51356 Quit                    (core dumped) charm-$@

@dosaboy
Copy link
Author

dosaboy commented Apr 18, 2024

hmm a second attempt of the build did succeed. The version that charmcraft is using is one commit behind HEAD:

$ git cherry -v b7128ec

But that does not seem related to the issue.

@dosaboy
Copy link
Author

dosaboy commented Apr 18, 2024

The latest version of the charm snap in 3.x/stable does not contain the above patch and I think that is the reason why charmcraft buildis failing in CI but not when run the build locally. When I run it locally I get setuptools 59.6.0-1.2ubuntu0.22.04.1 but in the CI it needs that upgrade step to get the same version hence why it is failing. So we need to get a new build of this snap that include that patch so that charmcraft can consume it.

@dosaboy
Copy link
Author

dosaboy commented Apr 22, 2024

tested with the latest version that includes that patch and it still fails

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant