Skip to content

tools,tests: improve robustness of changelog script, add test for fips#412

Draft
Meulengracht wants to merge 10 commits intocanonical:core22from
Meulengracht:core22
Draft

tools,tests: improve robustness of changelog script, add test for fips#412
Meulengracht wants to merge 10 commits intocanonical:core22from
Meulengracht:core22

Conversation

@Meulengracht
Copy link
Member

No description provided.

with gzip.open(chl_path) as chl_fh:
return chl_fh.read().decode('utf-8')
else:
raise FileNotFoundError(f"no supported changelog found for package {pkg}")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

seems like other places use f strings

print(f"failed to resolve FIPS changelog for {pkg}/{new_v}")
raise KeyError
if re.match(r'.*\+esm[0-9]*$', new_v) or package_name(pkg) in pkg_no_changelog:
raise PackageNoChangelog('package ' + pkg + ' does not have changelog')
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same here

remote_url = subprocess.check_output(['git', 'remote', 'get-url', 'origin']).decode('ascii').strip()
if remote_url.startswith("git@github.com:"):
remote_url = remote_url.replace("git@github.com:", "https://github.com/")
return remote_url.removesuffix(".git")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this needs python 3.9 IIRC, so it should work on 22.04

artifact_file: core22.artifact
- variant: fips
artifact_name: core-fips-snap
artifact_file: core22-fips.artifact
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do you have access to the PPA from github CI?

return chl_fh.read().decode('utf-8')
else:
raise FileNotFoundError(f"no supported changelog found for package {pkg}")
raise FileNotFoundError("no supported changelog found for package " + pkg)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is still using + instead of f strings

@Meulengracht Meulengracht marked this pull request as draft March 18, 2026 09:31
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

Successfully merging this pull request may close these issues.

2 participants