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

Fix deprecations for AppStream 0.16 #2015

Merged
merged 3 commits into from Apr 11, 2023
Merged

Fix deprecations for AppStream 0.16 #2015

merged 3 commits into from Apr 11, 2023

Conversation

meisenzahl
Copy link
Member

Since AppStream 0.16 AppCenter could no longer be compiled:

../../../downloads/elementary/appcenter/master/https_github.com_elementary_appcenter/src/Core/FlatpakBackend.vala:1044.74-1044.105: error: The name `COLLECTION' does not exist in the context of `AppStream.FormatStyle' (appstream)
 1044 |         user_appstream_pool.add_extra_data_location (user_metadata_path, AppStream.FormatStyle.COLLECTION);
      |                                                                          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../../../downloads/elementary/appcenter/master/https_github.com_elementary_appcenter/src/Core/FlatpakBackend.vala:1079.78-1079.109: error: The name `COLLECTION' does not exist in the context of `AppStream.FormatStyle' (appstream)
 1079 |         system_appstream_pool.add_extra_data_location (system_metadata_path, AppStream.FormatStyle.COLLECTION);
      |                                                                              ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../../../downloads/elementary/appcenter/master/https_github.com_elementary_appcenter/src/Core/FlatpakBackend.vala:133.40-133.77: warning: `AppStream.PoolFlags.LOAD_OS_COLLECTION' is deprecated. Use LOAD_OS_CATALOG
  133 |         user_appstream_pool.set_flags (AppStream.PoolFlags.LOAD_OS_COLLECTION);
      |                                        ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../../../downloads/elementary/appcenter/master/https_github.com_elementary_appcenter/src/Core/FlatpakBackend.vala:141.42-141.79: warning: `AppStream.PoolFlags.LOAD_OS_COLLECTION' is deprecated. Use LOAD_OS_CATALOG
  141 |         system_appstream_pool.set_flags (AppStream.PoolFlags.LOAD_OS_COLLECTION);
      |                                          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../../../downloads/elementary/appcenter/master/https_github.com_elementary_appcenter/src/Core/PackageKitBackend.vala:172.72-172.103: error: The name `COLLECTION' does not exist in the context of `AppStream.FormatStyle' (appstream)
  172 |         appstream_pool.add_extra_data_location ("/usr/share/app-info", AppStream.FormatStyle.COLLECTION);
      |                                                                        ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Compilation failed: 3 error(s), 2 warning(s)

Building for Fedora 37:

Before

After

@meisenzahl meisenzahl mentioned this pull request Apr 11, 2023
6 tasks
@tintou
Copy link
Member

tintou commented Apr 11, 2023

That's upstream issue, opened ximion/appstream#477

@meisenzahl
Copy link
Member Author

@tintou thanks for submitting upstream the pull request.

Do we still want to refactor the code to stop showing the warnings?

Copy link
Member

@tintou tintou left a comment

Choose a reason for hiding this comment

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

yes :) thanks

@tintou tintou merged commit 8e437af into master Apr 11, 2023
4 checks passed
@tintou tintou deleted the appstream-0-16 branch April 11, 2023 08:06
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.

None yet

2 participants