Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package libmodulemd for openSUSE:Factory checked in at 2021-06-05 23:30:17 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/libmodulemd (Old) and /work/SRC/openSUSE:Factory/.libmodulemd.new.1898 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "libmodulemd" Sat Jun 5 23:30:17 2021 rev:12 rq:896309 version:2.12.1 Changes: -------- --- /work/SRC/openSUSE:Factory/libmodulemd/libmodulemd.changes 2021-02-07 15:17:52.293652859 +0100 +++ /work/SRC/openSUSE:Factory/.libmodulemd.new.1898/libmodulemd.changes 2021-06-05 23:30:35.772340322 +0200 @@ -1,0 +2,21 @@ +Mon May 31 08:36:31 UTC 2021 - Marcus Meissner <meiss...@suse.com> + +- Updated to 2.12.1 + This is a bug-fix release fully compatible with the previous 2.12.0 + version. Notable changes: + + Enhancements: + + - Improve diagnostic messages for compression tests. + - Tests performed in a GitHub continues integration are faster. + - Use GitHub actions to perform CI tests also on ArchLinux, Mageia, + Mandriva, and OpenSUSE. + + Fixes: + + - Relax context value up to 13 characters including an underscore + character in modulemd v2 format. This reenables scratch-builds in MBS. + Migrate Packit tests from a deprecated current_version_command to + a newer actions/get-current-version. + +------------------------------------------------------------------- Old: ---- modulemd-2.12.0.tar.xz New: ---- modulemd-2.12.1.tar.xz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ libmodulemd.spec ++++++ --- /var/tmp/diff_new_pack.yCn0qM/_old 2021-06-05 23:30:36.316341268 +0200 +++ /var/tmp/diff_new_pack.yCn0qM/_new 2021-06-05 23:30:36.320341275 +0200 @@ -1,6 +1,7 @@ # # spec file for package libmodulemd # +# Copyright (c) 2021 SUSE LLC # Copyright (c) 2020-2021 Neal Gompa <ngomp...@gmail.com>. # # All modifications and additions to the file contributed by third parties @@ -12,13 +13,13 @@ # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. -# Please submit bugfixes or comments via http://bugs.opensuse.org/ +# Please submit bugfixes or comments via https://bugs.opensuse.org/ # %global majorversion 2 %global minorversion 12 -%global patchversion 0 +%global patchversion 1 %global majorminorversion %{majorversion}.%{minorversion} %global nsversion %{majorversion}.0 @@ -28,26 +29,25 @@ %global devname %{name}-devel %global girname typelib-1_0-Modulemd-%{majorversion}_0 - Name: libmodulemd Version: %{libmodulemd_version} Release: 0 Summary: Module metadata manipulation library -Group: System/Packages License: MIT +Group: System/Packages URL: https://github.com/fedora-modularity/libmodulemd -Source0: %{url}/releases/download/%{name}-%{libmodulemd_version}/modulemd-%{libmodulemd_version}.tar.xz +Source0: %{url}/releases/download/%{libmodulemd_version}/modulemd-%{libmodulemd_version}.tar.xz +BuildRequires: file-devel +BuildRequires: gcc BuildRequires: help2man BuildRequires: meson >= 0.47.0 -BuildRequires: gcc +BuildRequires: python3-gobject +BuildRequires: rpm-devel BuildRequires: pkgconfig(gobject-2.0) BuildRequires: pkgconfig(gobject-introspection-1.0) -BuildRequires: pkgconfig(yaml-0.1) BuildRequires: pkgconfig(gtk-doc) -BuildRequires: python3-gobject -BuildRequires: rpm-devel -BuildRequires: file-devel +BuildRequires: pkgconfig(yaml-0.1) # For tests BuildRequires: gcc-c++ @@ -94,8 +94,8 @@ %package -n %{devname} Summary: Development files for %{name} Group: Development/Libraries/C and C++ -Requires: %{libname}%{?_isa} = %{libmodulemd_version}-%{release} Requires: %{girname}%{?_isa} = %{libmodulemd_version}-%{release} +Requires: %{libname}%{?_isa} = %{libmodulemd_version}-%{release} %description -n %{devname} This package provides files for developing applications to use %{name}. ++++++ modulemd-2.12.0.tar.xz -> modulemd-2.12.1.tar.xz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/modulemd-2.12.0/.packit.yml new/modulemd-2.12.1/.packit.yml --- old/modulemd-2.12.0/.packit.yml 2021-01-15 03:08:36.851415400 +0100 +++ new/modulemd-2.12.1/.packit.yml 2021-05-03 15:15:23.572000000 +0200 @@ -3,7 +3,8 @@ upstream_project_url: https://github.com/fedora-modularity/libmodulemd downstream_package_name: libmodulemd -current_version_command: [ ./get_version.sh ] +actions: + get-current-version: ./get_version.sh synced_files: - fedora/ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/modulemd-2.12.0/meson.build new/modulemd-2.12.1/meson.build --- old/modulemd-2.12.0/meson.build 2021-01-15 03:08:36.853415500 +0100 +++ new/modulemd-2.12.1/meson.build 2021-05-03 15:15:23.575000000 +0200 @@ -12,7 +12,7 @@ project( 'modulemd', 'c', -version : '2.12.0', +version : '2.12.1', default_options : ['buildtype=debugoptimized', 'c_std=c11', 'warning_level=1', 'b_asneeded=true'], license : 'MIT', meson_version : '>=0.47.0' diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/modulemd-2.12.0/modulemd/include/private/modulemd-module-stream-v2-private.h new/modulemd-2.12.1/modulemd/include/private/modulemd-module-stream-v2-private.h --- old/modulemd-2.12.0/modulemd/include/private/modulemd-module-stream-v2-private.h 2021-01-15 03:08:36.859415500 +0100 +++ new/modulemd-2.12.1/modulemd/include/private/modulemd-module-stream-v2-private.h 2021-05-03 15:15:23.582000000 +0200 @@ -13,6 +13,7 @@ #pragma once +#include "modulemd-module-stream.h" #include "modulemd-module-stream-v2.h" #include "modulemd-subdocument-info.h" #include <glib-object.h> @@ -23,6 +24,17 @@ /** + * MODULEMD_MODULE_STREAM_V2_MAXCONTEXTLEN: + * + * The ModuleStream v3 specification defines the maximum lenth of the context + * field. Just before building, the v3 format is converted to v2 format. But + * if a scratch build was requested, an underscore with a decimal number (e.g. + * "_1") is appended to the v2 context. Allow up to 99 scratch builds here. + */ +#define MODULEMD_MODULE_STREAM_V2_MAXCONTEXTLEN (MMD_MAXCONTEXTLEN + 3) + + +/** * SECTION: modulemd-module-stream-v2-private * @title: Modulemd.ModuleStreamV2 (Private) * @stability: private diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/modulemd-2.12.0/modulemd/meson.build new/modulemd-2.12.1/modulemd/meson.build --- old/modulemd-2.12.0/modulemd/meson.build 2021-01-15 03:08:36.861415600 +0100 +++ new/modulemd-2.12.1/modulemd/meson.build 2021-05-03 15:15:23.584000000 +0200 @@ -271,6 +271,7 @@ 'component_module' : [ 'tests/test-modulemd-component-module.c' ], 'component_rpm' : [ 'tests/test-modulemd-component-rpm.c' ], 'compression' : [ 'tests/test-modulemd-compression.c' ], +'context' : [ 'tests/test-modulemd-context.c' ], 'defaults' : [ 'tests/test-modulemd-defaults.c' ], 'defaultsv1' : [ 'tests/test-modulemd-defaults-v1.c' ], 'dependencies' : [ 'tests/test-modulemd-dependencies.c' ], diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/modulemd-2.12.0/modulemd/modulemd-module-stream-v2.c new/modulemd-2.12.1/modulemd/modulemd-module-stream-v2.c --- old/modulemd-2.12.0/modulemd/modulemd-module-stream-v2.c 2021-01-15 03:08:36.865415600 +0100 +++ new/modulemd-2.12.1/modulemd/modulemd-module-stream-v2.c 2021-05-03 15:15:23.589000000 +0200 @@ -1237,7 +1237,7 @@ modulemd_module_stream_v2_validate_context (const gchar *context, GError **error) { - /* must be string of up to MMD_MAXCONTEXTLEN [a-zA-Z0-9] */ + /* must be string of up to MODULEMD_MODULE_STREAM_V2_MAXCONTEXTLEN [a-zA-Z0-9_] */ if (context == NULL || *context == '\0') { @@ -1246,26 +1246,27 @@ return FALSE; } - if (strlen (context) > MMD_MAXCONTEXTLEN) + if (strlen (context) > MODULEMD_MODULE_STREAM_V2_MAXCONTEXTLEN) { g_set_error (error, MODULEMD_ERROR, MMD_ERROR_VALIDATE, "Stream context '%s' exceeds maximum length (%d)", context, - MMD_MAXCONTEXTLEN); + MODULEMD_MODULE_STREAM_V2_MAXCONTEXTLEN); return FALSE; } for (const gchar *i = context; *i != '\0'; i++) { - if (!g_ascii_isalnum (*i)) + if (!g_ascii_isalnum (*i) && *i != '_') { - g_set_error (error, - MODULEMD_ERROR, - MMD_ERROR_VALIDATE, - "Non-alphanumeric character in stream context '%s'", - context); + g_set_error ( + error, + MODULEMD_ERROR, + MMD_ERROR_VALIDATE, + "Stream context '%s' can only contain [a-zA-Z0-9_] characters", + context); return FALSE; } } diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/modulemd-2.12.0/modulemd/tests/test-modulemd-compression.c new/modulemd-2.12.1/modulemd/tests/test-modulemd-compression.c --- old/modulemd-2.12.0/modulemd/tests/test-modulemd-compression.c 2021-01-15 03:08:36.872415500 +0100 +++ new/modulemd-2.12.1/modulemd/tests/test-modulemd-compression.c 2021-05-03 15:15:23.597000000 +0200 @@ -140,13 +140,13 @@ filename = g_strdup_printf ("%s/compression/%s", g_getenv ("TEST_DATA_PATH"), expected_magic[j].filename); + g_debug ("Getting compression type for %s", filename); filestream = g_fopen (filename, "rbe"); g_assert_nonnull (filestream); fd = fileno (filestream); - g_assert_cmpint (modulemd_detect_compression (filename, fd, &error), - ==, - expected_magic[j].type); + result = modulemd_detect_compression (filename, fd, &error); g_assert_no_error (error); + g_assert_cmpint (result, ==, expected_magic[j].type); g_clear_error (&error); g_clear_pointer (&filestream, fclose); g_clear_pointer (&filename, g_free); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/modulemd-2.12.0/modulemd/tests/test-modulemd-context.c new/modulemd-2.12.1/modulemd/tests/test-modulemd-context.c --- old/modulemd-2.12.0/modulemd/tests/test-modulemd-context.c 1970-01-01 01:00:00.000000000 +0100 +++ new/modulemd-2.12.1/modulemd/tests/test-modulemd-context.c 2021-05-03 15:15:23.597000000 +0200 @@ -0,0 +1,226 @@ +/* + * This file is part of libmodulemd + * Copyright (C) 2021 Red Hat, Inc. + * + * Fedora-License-Identifier: MIT + * SPDX-2.0-License-Identifier: MIT + * SPDX-3.0-License-Identifier: MIT + * + * This program is free software. + * For more information on the license, see COPYING. + * For more information on free software, see <https://www.gnu.org/philosophy/free-sw.en.html>. + */ + +#include <locale.h> +#include <glib.h> +#include "modulemd.h" +#include "config.h" + +static void +test_modulemd_v3_context_valid (void) +{ + const gchar *yaml_string = NULL; + g_autoptr (GError) error = NULL; + g_autoptr (GObject) object = NULL; + GType type = G_TYPE_INVALID; + + yaml_string = + "---\n" + "document: modulemd-packager\n" + "version: 3\n" + "data:\n" + " name: trivialname\n" + " stream: trivialstream\n" + " summary: Trivial Summary\n" + " description: >-\n" + " Trivial Description\n" + " license: [MIT]\n" + " configurations:\n" + " - context: a234567890\n" + " platform: foo\n" + "...\n"; + type = modulemd_read_packager_string (yaml_string, &object, &error); + g_assert_true (type == MODULEMD_TYPE_PACKAGER_V3); + g_assert_no_error (error); +} + + +static void +test_modulemd_v3_context_overlong (void) +{ + const gchar *yaml_string = NULL; + g_autoptr (GError) error = NULL; + g_autoptr (GObject) object = NULL; + GType type = G_TYPE_INVALID; + + yaml_string = + "---\n" + "document: modulemd-packager\n" + "version: 3\n" + "data:\n" + " name: trivialname\n" + " stream: trivialstream\n" + " summary: Trivial Summary\n" + " description: >-\n" + " Trivial Description\n" + " license: [MIT]\n" + " configurations:\n" + " - context: a2345678901\n" + " platform: foo\n" + "...\n"; + type = modulemd_read_packager_string (yaml_string, &object, &error); + g_assert_true (type == G_TYPE_INVALID); + g_assert_error (error, MODULEMD_ERROR, MMD_ERROR_VALIDATE); +} + + +static void +test_modulemd_v3_context_bad_underscore (void) +{ + const gchar *yaml_string = NULL; + g_autoptr (GError) error = NULL; + g_autoptr (GObject) object = NULL; + GType type = G_TYPE_INVALID; + + yaml_string = + "---\n" + "document: modulemd-packager\n" + "version: 3\n" + "data:\n" + " name: trivialname\n" + " stream: trivialstream\n" + " summary: Trivial Summary\n" + " description: >-\n" + " Trivial Description\n" + " license: [MIT]\n" + " configurations:\n" + " - context: _\n" + " platform: foo\n" + "...\n"; + type = modulemd_read_packager_string (yaml_string, &object, &error); + g_assert_true (type == G_TYPE_INVALID); + g_assert_error (error, MODULEMD_ERROR, MMD_ERROR_VALIDATE); +} + + +static void +test_modulemd_v2_context_valid (void) +{ + const gchar *yaml_string = NULL; + g_autoptr (GError) error = NULL; + g_autoptr (GObject) object = NULL; + GType type = G_TYPE_INVALID; + + yaml_string = + "---\n" + "document: modulemd\n" + "version: 2\n" + "data:\n" + " name: trivialname\n" + " stream: trivialstream\n" + " summary: Trivial Summary\n" + " description: >-\n" + " Trivial Description\n" + " license:\n" + " module: [MIT]\n" + " static_context: true\n" + " context: a234567890_23\n" + "...\n"; + type = modulemd_read_packager_string (yaml_string, &object, &error); + g_assert_true (type == MODULEMD_TYPE_MODULE_STREAM_V2); + g_assert_no_error (error); + /* Reading v2 document does not validate it; validating explictly */ + g_assert_true ( + modulemd_module_stream_validate (MODULEMD_MODULE_STREAM (object), &error)); +} + + +static void +test_modulemd_v2_context_overlong (void) +{ + const gchar *yaml_string = NULL; + g_autoptr (GError) error = NULL; + g_autoptr (GObject) object = NULL; + GType type = G_TYPE_INVALID; + + yaml_string = + "---\n" + "document: modulemd\n" + "version: 2\n" + "data:\n" + " name: trivialname\n" + " stream: trivialstream\n" + " summary: Trivial Summary\n" + " description: >-\n" + " Trivial Description\n" + " license:\n" + " module: [MIT]\n" + " static_context: true\n" + " context: a234567890_234\n" + "...\n"; + type = modulemd_read_packager_string (yaml_string, &object, &error); + g_assert_true (type == MODULEMD_TYPE_MODULE_STREAM_V2); + g_assert_no_error (error); + /* Reading v2 document does not validate it; validating explictly */ + g_assert_false ( + modulemd_module_stream_validate (MODULEMD_MODULE_STREAM (object), &error)); +} + + +static void +test_modulemd_v2_context_bad_character (void) +{ + const gchar *yaml_string = NULL; + g_autoptr (GError) error = NULL; + g_autoptr (GObject) object = NULL; + GType type = G_TYPE_INVALID; + + yaml_string = + "---\n" + "document: modulemd\n" + "version: 2\n" + "data:\n" + " name: trivialname\n" + " stream: trivialstream\n" + " summary: Trivial Summary\n" + " description: >-\n" + " Trivial Description\n" + " license:\n" + " module: [MIT]\n" + " static_context: true\n" + " context: '-'\n" + "...\n"; + type = modulemd_read_packager_string (yaml_string, &object, &error); + g_assert_true (type == MODULEMD_TYPE_MODULE_STREAM_V2); + g_assert_no_error (error); + /* Reading v2 document does not validate it; validating explictly */ + g_assert_false ( + modulemd_module_stream_validate (MODULEMD_MODULE_STREAM (object), &error)); +} + + +int +main (int argc, char *argv[]) +{ + setlocale (LC_ALL, ""); + g_test_init (&argc, &argv, NULL); + g_test_set_nonfatal_assertions (); + g_test_bug_base ("https://github.com/fedora-modularity/libmodulemd/issues/"); + g_test_bug ("549"); + + g_test_add_func ("/modulemd/v3/context/valid", + test_modulemd_v3_context_valid); + g_test_add_func ("/modulemd/v3/context/overlong", + test_modulemd_v3_context_overlong); + g_test_add_func ("/modulemd/v3/context/bad_underscore", + test_modulemd_v3_context_bad_underscore); + + g_test_add_func ("/modulemd/v2/context/valid", + test_modulemd_v2_context_valid); + g_test_add_func ("/modulemd/v2/context/overlong", + test_modulemd_v2_context_overlong); + g_test_add_func ("/modulemd/v2/context/bad_character", + test_modulemd_v2_context_bad_character); + + return g_test_run (); +} diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/modulemd-2.12.0/yaml_specs/modulemd_stream_v2.yaml new/modulemd-2.12.1/yaml_specs/modulemd_stream_v2.yaml --- old/modulemd-2.12.0/yaml_specs/modulemd_stream_v2.yaml 2021-01-15 03:08:36.883415700 +0100 +++ new/modulemd-2.12.1/yaml_specs/modulemd_stream_v2.yaml 2021-05-03 15:15:23.616000000 +0200 @@ -88,7 +88,7 @@ # Mandatory for module metadata in a yum/dnf repository. # # If 'static_context' is set to True: - # The context flag is a string of up to ten [a-zA-Z0-9] characters + # The context flag is a string of up to thirteen [a-zA-Z0-9_] characters # representing a build and runtime configuration for this stream. This # string is arbitrary but must be unique in this module stream. #