Skip to content

Commit

Permalink
manifest: Skip updating appdata if last source is not external
Browse files Browse the repository at this point in the history
or no main source is found

Closes #346
  • Loading branch information
bbhtt committed Jun 3, 2024
1 parent bf14aa1 commit 0fbed2f
Showing 1 changed file with 13 additions and 4 deletions.
17 changes: 13 additions & 4 deletions src/manifest.py
Original file line number Diff line number Diff line change
Expand Up @@ -486,10 +486,19 @@ def _update_appdata(self):
elif data.source_path == self._root_manifest_path:
selected_data = data
else:
# Guess that the last external source in the root manifest is the one
# corresponding to the main application bundle.
assert selected_data is not None
log.warning("Guessed upstream source: %s", selected_data)
if selected_data is not None:
# Guess that the last external source in the root manifest is the one
# corresponding to the main application bundle.
log.warning("Guessed last source as main source: %s", selected_data)
else:
log.error(
(
"Found no main source and the last source was not "
"external in %s. Not updating appdata"
),
self._root_manifest_path,
)
return

last_update = selected_data.new_version

Expand Down

0 comments on commit 0fbed2f

Please sign in to comment.