Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package maildir-utils for openSUSE:Factory 
checked in at 2023-04-24 22:31:25
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/maildir-utils (Old)
 and      /work/SRC/openSUSE:Factory/.maildir-utils.new.1533 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "maildir-utils"

Mon Apr 24 22:31:25 2023 rev:43 rq:1082365 version:1.10.3

Changes:
--------
--- /work/SRC/openSUSE:Factory/maildir-utils/maildir-utils.changes      
2023-04-09 20:32:58.660547577 +0200
+++ /work/SRC/openSUSE:Factory/.maildir-utils.new.1533/maildir-utils.changes    
2023-04-24 22:31:36.195649737 +0200
@@ -1,0 +2,9 @@
+Mon Apr 17 06:31:13 UTC 2023 - Michael Vetter <mvet...@suse.com>
+
+- Update to 1.10.3:
+  * fix logger unit-test build for some environments
+  * mu/mu4e: improve server error messages
+  * add 'uninstall' target to makefile
+  * reset mu4e--last-delta-unread (notifications)
+
+-------------------------------------------------------------------

Old:
----
  mu-1.10.2.tar.xz

New:
----
  mu-1.10.3.tar.xz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ maildir-utils.spec ++++++
--- /var/tmp/diff_new_pack.t6cJl3/_old  2023-04-24 22:31:36.867653732 +0200
+++ /var/tmp/diff_new_pack.t6cJl3/_new  2023-04-24 22:31:36.875653780 +0200
@@ -17,7 +17,7 @@
 
 
 Name:           maildir-utils
-Version:        1.10.2
+Version:        1.10.3
 Release:        0
 Summary:        Maildir indexer and searcher
 License:        GPL-3.0-or-later

++++++ mu-1.10.2.tar.xz -> mu-1.10.3.tar.xz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/mu-1.10.2/Makefile new/mu-1.10.3/Makefile
--- old/mu-1.10.2/Makefile      2023-04-09 14:05:50.000000000 +0200
+++ new/mu-1.10.3/Makefile      2023-04-15 22:20:37.000000000 +0200
@@ -37,7 +37,7 @@
 .PHONY: all
 .PHONY: check test test-verbose-if-fail test-valgrind test-helgrind
 .PHONY: benchmark coverage
-.PHONY: dist install clean distclean
+.PHONY: dist install uninstall clean distclean
 .PHONY: mu4e-doc-html
 
 # MESON_FLAGS, e.g. "-Dreadline=enabled"
@@ -57,14 +57,15 @@
 test: all
        @$(MESON) test $(VERBOSE) -C $(BUILDDIR)
 
-
 install: $(BUILDDIR)
        @cd $(BUILDDIR); $(MESON) install
 
+uninstall: $(BUILDDIR)
+       @$(NINJA) -C $(BUILDDIR) uninstall
+
 clean:
        @rm -rf $(BUILDDIR) $(COVERAGE_BUILDDIR)
 
-
 #
 # below targets are just for development/testing/debugging. They may or
 # may not work on your system.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/mu-1.10.2/README.org new/mu-1.10.3/README.org
--- old/mu-1.10.2/README.org    2023-04-09 14:05:50.000000000 +0200
+++ new/mu-1.10.3/README.org    2023-04-15 22:20:37.000000000 +0200
@@ -14,11 +14,9 @@
 
 Welcome to ~mu~!
 
-*Note*: you are looking at the *development* branch, which is where new code is
-being developed and tested, and which may occasionally break.
-
-Distributions and non-adventurous users are instead recommended to use the 
[[https://github.com/djcb/mu/tree/release/1.10][1.10
-Release Branch]] or to pick up one of the 
[[https://github.com/djcb/mu/releases][1.10 Releases]].
+*Note*: you are looking at the 1.10 *stable branch*, which is meant for common 
users
+and distributions - pick up one of the 
[[https://github.com/djcb/mu/releases][1.10 Releases]]. If you are interested in
+~mu~ development, you can check the [[https://github.com/djcb/mu][master 
branch]] where that happens.
 
 Given the enormous amounts of e-mail many people gather and the importance of
 e-mail message in our work-flows, it's essential to quickly deal with all that
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/mu-1.10.2/lib/mu-server.cc 
new/mu-1.10.3/lib/mu-server.cc
--- old/mu-1.10.2/lib/mu-server.cc      2023-04-09 14:05:50.000000000 +0200
+++ new/mu-1.10.3/lib/mu-server.cc      2023-04-15 22:20:37.000000000 +0200
@@ -33,6 +33,7 @@
 #include <cstring>
 #include <glib.h>
 #include <glib/gprintf.h>
+#include <unistd.h>
 
 #include "mu-maildir.hh"
 #include "mu-query.hh"
@@ -338,18 +339,15 @@
 
 G_GNUC_PRINTF(2, 3)
 static Sexp
-make_error(Error::Code errcode, const char* frm, ...)
+make_error(Error::Code code, const char* frm, ...)
 {
-       char*   msg{};
        va_list ap;
-
        va_start(ap, frm);
-       g_vasprintf(&msg, frm, ap);
+       auto err = Sexp().put_props(
+               ":error", Error::error_number(code),
+               ":message", vformat(frm, ap));
        va_end(ap);
 
-       auto err = Sexp().put_props(":error", static_cast<int>(errcode),
-                                   ":message", msg);
-       g_free(msg);
        return err;
 }
 
@@ -906,16 +904,16 @@
        if (docids.size() > 1) {
                if (!maildir.empty()) // ie. duplicate message-ids.
                        throw Mu::Error{Error::Code::Store,
-                               "can't move multiple messages at the same 
time"};
+                               "cannot move multiple messages at the same 
time"};
                // multi.
                for (auto&& docid : docids)
                        move_docid(docid, flagopt, rename, no_view);
                return;
        }
-       auto docid{docids.at(0)};
+       const auto docid{docids.at(0)};
        auto    msg = store().find_message(docid)
-               .or_else([]{throw Error{Error::Code::InvalidArgument,
-                                       "could not create message"};}).value();
+               .or_else([&]{throw Error{Error::Code::InvalidArgument,
+                                       "cannot find message %u", 
docid};}).value();
 
        /* if maildir was not specified, take the current one */
        if (maildir.empty())
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/mu-1.10.2/lib/utils/meson.build 
new/mu-1.10.3/lib/utils/meson.build
--- old/mu-1.10.2/lib/utils/meson.build 2023-04-09 14:05:50.000000000 +0200
+++ new/mu-1.10.3/lib/utils/meson.build 2023-04-15 22:20:37.000000000 +0200
@@ -69,6 +69,6 @@
      executable('test-logger', 'mu-logger.cc',
                 install: false,
                 cpp_args: ['-DBUILD_TESTS'],
-                dependencies: [glib_dep, lib_mu_utils_dep]))
+                dependencies: [glib_dep, lib_mu_utils_dep, thread_dep ]))
 
 subdir('tests')
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/mu-1.10.2/lib/utils/mu-error.hh 
new/mu-1.10.3/lib/utils/mu-error.hh
--- old/mu-1.10.2/lib/utils/mu-error.hh 2023-04-09 14:05:50.000000000 +0200
+++ new/mu-1.10.3/lib/utils/mu-error.hh 2023-04-15 22:20:37.000000000 +0200
@@ -22,6 +22,7 @@
 
 #include <stdexcept>
 #include <string>
+#include <errno.h>
 #include <cstdint>
 
 #include "mu-utils-format.hh"
@@ -29,47 +30,52 @@
 
 namespace Mu {
 
+// calculate an error enum value.
+constexpr uint32_t err_enum(uint8_t code, uint8_t rv, uint8_t cat) {
+       return static_cast<uint32_t>(code|(rv << 16)|cat<<24);
+}
+
 struct Error final : public std::exception {
 
        // 16 lower bits are for the error code the next 8 bits is for the 
return code
        // upper byte is for flags
-
-       static constexpr uint32_t SoftError = 1 << 23;
-
-#define ERROR_ENUM(RV,CAT) \
-       static_cast<uint32_t>(__LINE__ | ((RV) << 15) | (CAT))
+       static constexpr uint8_t SoftError = 1;
 
        enum struct Code: uint32_t {
-               AccessDenied        = ERROR_ENUM(1,0),
-               AssertionFailure    = ERROR_ENUM(1,0),
-               Command             = ERROR_ENUM(1,0),
-               Crypto              = ERROR_ENUM(1,0),
-               File                = ERROR_ENUM(1,0),
-               Index               = ERROR_ENUM(1,0),
-               Internal            = ERROR_ENUM(1,0),
-               InvalidArgument     = ERROR_ENUM(1,0),
-               Message             = ERROR_ENUM(1,0),
-               NoMatches           = ERROR_ENUM(2,SoftError),
-               NotFound            = ERROR_ENUM(1,0),
-               Parsing             = ERROR_ENUM(1,0),
-               Play                = ERROR_ENUM(1,0),
-               Query               = ERROR_ENUM(1,0),
-               SchemaMismatch      = ERROR_ENUM(11,0),
-               Script              = ERROR_ENUM(1,0),
-               ScriptNotFound      = ERROR_ENUM(1,0),
-               Store               = ERROR_ENUM(1,0),
-               StoreLock           = ERROR_ENUM(19,0),
-               UnverifiedSignature = ERROR_ENUM(1,0),
-               User                = ERROR_ENUM(1,0),
-               Xapian              = ERROR_ENUM(1,0),
-       };
+               Ok                      = err_enum(0,0,0),
 
+               // used by mu4e.
+               NoMatches               = err_enum(4,2,SoftError),
+               SchemaMismatch          = err_enum(110,11,0),
+
+               // other
+               AccessDenied            = err_enum(100,1,0),
+               AssertionFailure        = err_enum(101,1,0),
+               Command                 = err_enum(102,1,0),
+               Crypto                  = err_enum(103,1,0),
+               File                    = err_enum(104,1,0),
+               Index                   = err_enum(105,1,0),
+               Internal                = err_enum(106,1,0),
+               InvalidArgument         = err_enum(107,1,0),
+               Message                 = err_enum(108,1,0),
+               NotFound                = err_enum(109,1,0),
+               Parsing                 = err_enum(111,1,0),
+               Play                    = err_enum(112,1,0),
+               Query                   = err_enum(113,1,0),
+               Script                  = err_enum(115,1,0),
+               ScriptNotFound          = err_enum(116,1,0),
+               Store                   = err_enum(117,1,0),
+               StoreLock               = err_enum(118,19,0),
+               UnverifiedSignature     = err_enum(119,1,0),
+               User                    = err_enum(120,1,0),
+               Xapian                  = err_enum(121,1,0),
+       };
 
        /**
         * Construct an error
         *
         * @param codearg error-code
-        * #param msgarg the error diecription
+        * @param msgarg the error description
         */
        Error(Code codearg, const std::string& msgarg) : code_{codearg}, 
what_{msgarg} {}
        Error(Code codearg, std::string&& msgarg) : code_{codearg}, 
what_{std::move(msgarg)} {}
@@ -92,7 +98,7 @@
                va_end(args);
        }
 
-       Error(Error&& rhs)      = default;
+       Error(Error&& rhs)      = default;
        Error(const Error& rhs) = default;
 
        /**
@@ -142,6 +148,16 @@
         */
        Code code() const noexcept { return code_; }
 
+       /**
+        * Get the error number (e.g. for reporting to mu4e) for some error.
+        *
+        * @param c error code
+        *
+        * @return the error number
+        */
+       static constexpr uint32_t error_number(Code c) noexcept {
+               return static_cast<uint32_t>(c) & 0xffff;
+       }
 
        /**
         * Is this is a 'soft error'?
@@ -153,10 +169,9 @@
        }
 
        constexpr uint8_t exit_code() const {
-               return ((static_cast<uint32_t>(code_) >> 15) & 0xff);
+               return ((static_cast<uint32_t>(code_) >> 16) & 0xff);
        }
 
-
        /**
         * Fill a GError with the error information
         *
@@ -169,10 +184,10 @@
 
 private:
        static inline GQuark error_quark (void) {
-       static GQuark error_domain = 0;
-       if (G_UNLIKELY(error_domain == 0))
-               error_domain = g_quark_from_static_string("mu-error-quark");
-       return error_domain;
+               static GQuark error_domain = 0;
+               if (G_UNLIKELY(error_domain == 0))
+                       error_domain = 
g_quark_from_static_string("mu-error-quark");
+               return error_domain;
        }
 
        const Code  code_;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/mu-1.10.2/meson.build new/mu-1.10.3/meson.build
--- old/mu-1.10.2/meson.build   2023-04-09 14:05:50.000000000 +0200
+++ new/mu-1.10.3/meson.build   2023-04-15 22:20:37.000000000 +0200
@@ -17,7 +17,7 @@
 
################################################################################
 # project setup
 project('mu', ['c', 'cpp'],
-        version: '1.10.2',
+        version: '1.10.3',
         meson_version: '>= 0.56.0',
         license: 'GPL-3.0-or-later',
         default_options : [
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/mu-1.10.2/mu/mu-cmd-server.cc 
new/mu-1.10.3/mu/mu-cmd-server.cc
--- old/mu-1.10.2/mu/mu-cmd-server.cc   2023-04-09 14:05:50.000000000 +0200
+++ new/mu-1.10.3/mu/mu-cmd-server.cc   2023-04-15 22:20:37.000000000 +0200
@@ -103,7 +103,7 @@
 static void
 report_error(const Mu::Error& err) noexcept
 {
-       output_sexp_stdout(Sexp(":error"_sym, static_cast<size_t>(err.code()),
+       output_sexp_stdout(Sexp(":error"_sym, Error::error_number(err.code()),
                                ":message"_sym, err.what()),
                           Server::OutputFlags::Flush);
 }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/mu-1.10.2/mu4e/mu4e-notification.el 
new/mu-1.10.3/mu4e/mu4e-notification.el
--- old/mu-1.10.2/mu4e/mu4e-notification.el     2023-04-09 14:05:50.000000000 
+0200
+++ new/mu-1.10.3/mu4e/mu4e-notification.el     2023-04-15 22:20:37.000000000 
+0200
@@ -38,8 +38,6 @@
   :type 'function
   :group 'mu4e-notification)
 
-(defvar mu4e--last-delta-unread 0
-  "Last notified number.")
 (defvar mu4e--notification-id nil
   "The last notification id, so we can replace it.")
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/mu-1.10.2/mu4e/mu4e-query-items.el 
new/mu-1.10.3/mu4e/mu4e-query-items.el
--- old/mu-1.10.2/mu4e/mu4e-query-items.el      2023-04-09 14:05:50.000000000 
+0200
+++ new/mu-1.10.3/mu4e/mu4e-query-items.el      2023-04-15 22:20:37.000000000 
+0200
@@ -67,6 +67,7 @@
 the latest query-items.")
 (defvar mu4e--query-items-baseline-tstamp nil
   "Timestamp for when the query-items baseline was updated.")
+(defvar mu4e--last-delta-unread 0 "Last notified number.")
 
 (defun mu4e--bookmark-query (bm)
   "Get the query string for some bookmark BM."
@@ -122,7 +123,8 @@
     (setq mu4e--query-items-baseline nil
           mu4e--query-items-baseline-tstamp nil
           mu4e--bookmark-items-cached nil
-          mu4e--maildir-items-cached nil))
+          mu4e--maildir-items-cached nil
+          mu4e--last-delta-unread 0))
   (mu4e--server-queries
    ;; note: we must apply the rewrite function here, since the query does not 
go
    ;; through mu4e-search.

Reply via email to