From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#48228: json-serialize should signal error when dll is not found [MS Windows] Date: Tue, 04 May 2021 20:42:18 +0300 Message-ID: <83eeem4cqt.fsf@gnu.org> References: <83o8dq4h2s.fsf@gnu.org> <3b2dba36-1714-6c19-556b-6cfe52fdb222@yandex.ru> <87fsz28n5x.fsf@gmail.com> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="32438"; mail-complaints-to="usenet@ciao.gmane.io" Cc: rpluim@gmail.com, p.stephani2@gmail.com, 48228@debbugs.gnu.org To: Dmitry Gutov Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue May 04 19:44:04 2021 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1ldz5Y-0008Jx-K6 for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 04 May 2021 19:44:04 +0200 Original-Received: from localhost ([::1]:35360 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ldz5X-0000SU-LR for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 04 May 2021 13:44:03 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:51954) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ldz4h-0000Ru-SH for bug-gnu-emacs@gnu.org; Tue, 04 May 2021 13:43:12 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:42935) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1ldz4X-0006ZJ-V4 for bug-gnu-emacs@gnu.org; Tue, 04 May 2021 13:43:07 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1ldz4X-0003qt-Sr for bug-gnu-emacs@gnu.org; Tue, 04 May 2021 13:43:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 04 May 2021 17:43:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 48228 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 48228-submit@debbugs.gnu.org id=B48228.162015016114791 (code B ref 48228); Tue, 04 May 2021 17:43:01 +0000 Original-Received: (at 48228) by debbugs.gnu.org; 4 May 2021 17:42:41 +0000 Original-Received: from localhost ([127.0.0.1]:54480 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ldz4C-0003qV-Ml for submit@debbugs.gnu.org; Tue, 04 May 2021 13:42:40 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:43592) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ldz4A-0003qM-7U for 48228@debbugs.gnu.org; Tue, 04 May 2021 13:42:39 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:56788) by eggs.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ldz44-0006M7-IX; Tue, 04 May 2021 13:42:32 -0400 Original-Received: from 84.94.185.95.cable.012.net.il ([84.94.185.95]:2509 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1ldz43-0001S6-2U; Tue, 04 May 2021 13:42:32 -0400 In-Reply-To: (message from Dmitry Gutov on Tue, 4 May 2021 19:59:15 +0300) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:205639 Archived-At: > Cc: Eli Zaretskii , p.stephani2@gmail.com, 48228@debbugs.gnu.org > From: Dmitry Gutov > Date: Tue, 4 May 2021 19:59:15 +0300 > > On 04.05.2021 19:43, Robert Pluim wrote: > > What makes it error-prone? Those existing testing functions (on > > Windows) attempt to load the relevant DLL's using the exact same > > mechanisms as the actual code, so the failure (and success) modes are > > identical. > > When somebody write code using json-serialize, and it can't do what it > was asked to do, it should raise an error. > > I have code like this in a separate project: > > (cond ((fboundp 'json-parse-buffer) > (json-parse-buffer > :array-type 'list > :object-type 'alist > :null-object nil)) > (t > (let ((json-array-type 'list)) > (json-read)))) > > It has been there for a couple of years. And only now I find out that it > can fail on MS Windows, because that failure is not reproducible on any > other platform. How is that different from similar code that relies on, say, librsvg to display SVG images?