From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id 4Hv6K7CNxV5+FAAA0tVLHw (envelope-from ) for ; Wed, 20 May 2020 20:06:08 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2 with LMTPS id ONTzJ7CNxV6PMQAAB5/wlQ (envelope-from ) for ; Wed, 20 May 2020 20:06:08 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 9169F94014C for ; Wed, 20 May 2020 20:06:07 +0000 (UTC) Received: from localhost ([::1]:49724 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jbUyb-0002te-Hj for larch@yhetil.org; Wed, 20 May 2020 16:06:05 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:40826) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jbUyE-0002tR-O3 for emacs-orgmode@gnu.org; Wed, 20 May 2020 16:05:42 -0400 Received: from wout2-smtp.messagingengine.com ([64.147.123.25]:53151) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jbUyD-00080Y-BF for emacs-orgmode@gnu.org; Wed, 20 May 2020 16:05:42 -0400 Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailout.west.internal (Postfix) with ESMTP id 4019E18EB; Wed, 20 May 2020 16:05:38 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute4.internal (MEProxy); Wed, 20 May 2020 16:05:38 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=imapmail.org; h= from:to:subject:in-reply-to:message-id:references:date :mime-version:content-type; s=fm3; bh=k2z/YpZ+IKRUIXFP7YqbslTxgG Ci+Dg+s56ZBMJiFSE=; b=txm47s2PGssZfe3mjFVP9p7H2cxqAxTVTPQD40xMnL DwvuPaUgV+C/PDWjaUkv50IOW+TSImlqjaPQO7vNc5l0iLpioTobcutO9TMEylN3 hQvczwrXwyStwnUDHK91DcA/IcdDvsWFzIOSOqR/1ytKLNIhEezPi6EEB9xTLaUF Rwb163MUBIwAVvgfaqT5IUKSmUzcr7tcHw6BMpGWWS0YN80oO2x2q0eL+1GepkGN 7TEklf+FrUy8RCZWVRY4ns7dpHhlG9gBWy6Q3oQV/g3elOEa/qbFbsYYA4amYgAy n6O/cup6GApUWarCiOdpww3y4QsXRhVTX7f8eJtxVFzA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-proxy :x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm2; bh=k2z/Yp Z+IKRUIXFP7YqbslTxgGCi+Dg+s56ZBMJiFSE=; b=NYoRiEWHJ339gW17gF+m8P INYzRgV6H+b27K/PmfOMfCi8V2dLNYvPgDzcr0igLU6X/rpiEtdVrwe8HN1CjYCm OapCGe7EaHA1fPhmqM1MB3eRxHHCW1J79oD++barAolmyAq2FaUU1fvRsGLuyOo0 uXDT8ISvYLgn2JuEr8U0BGXtVM1zc7wcDzJJ6fI3euTQDObVnfZQeitJ5OX1GGYl knNP7T1zezZ8CzyDd0SuwsVo7WXbzjOj7YFvaVru/+FR22BqtTS/eFQCTUClFXUw UQM5lPPTMsADmAZ+FjgBQ63vhbjkQzY9Jb/kau5UQn+F/2iD/zkg2303dQ/beRLw == X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduhedruddtledgudegfecutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfgh necuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmd enucfjughrpefhvffujgfkfhffgggtsehttdertddttddtnecuhfhrohhmpeforghtthhh vgifucfnuhhnughinhcuoehmughlsehimhgrphhmrghilhdrohhrgheqnecuggftrfgrth htvghrnheptddvteejhfekgfejhffflefhfeekleeludekteetleejteelvedthfffledv uefhnecuffhomhgrihhnpehnohguvghjshdrohhrghenucfkphepjeeirdduiedrudefhe drudduleenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhm pehmughlsehimhgrphhmrghilhdrohhrgh X-ME-Proxy: Received: from localhost (c-76-16-135-119.hsd1.il.comcast.net [76.16.135.119]) by mail.messagingengine.com (Postfix) with ESMTPA id 4A5AC306640A; Wed, 20 May 2020 16:05:37 -0400 (EDT) From: Matthew Lundin To: Ivan Sokolov , emacs-orgmode@gnu.org Subject: Re: ob-js uses deprecated Node APIs In-Reply-To: <7652301583883715@vla1-a6eaa355d163.qloud-c.yandex.net> Message-ID: <874ksa2x2h.fsf@fastmail.fm> References: <7652301583883715@vla1-a6eaa355d163.qloud-c.yandex.net> Date: Wed, 20 May 2020 15:05:36 -0500 MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=64.147.123.25; envelope-from=mdl@imapmail.org; helo=wout2-smtp.messagingengine.com X-detected-operating-system: by eggs.gnu.org: First seen = 2020/05/20 15:53:59 X-ACL-Warn: Detected OS = Linux 2.2.x-3.x [generic] [fuzzy] X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: "Emacs-orgmode" X-Scanner: scn0 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=imapmail.org header.s=fm3 header.b=txm47s2P; dkim=pass header.d=messagingengine.com header.s=fm2 header.b=NYoRiEWH; dmarc=pass (policy=none) header.from=imapmail.org; spf=pass (aspmx1.migadu.com: domain of emacs-orgmode-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=emacs-orgmode-bounces@gnu.org X-Spam-Score: -1.71 X-TUID: kuHtkk8o583p Ivan Sokolov writes: > I ran into problems with ob-js. When resolving them, I found that require ('sys') is deprecated, there is a patch. > > diff --git a/lisp/ob-js.el b/lisp/ob-js.el > index 7592040ab..d459e8069 100644 > --- a/lisp/ob-js.el > +++ b/lisp/ob-js.el > @@ -65,7 +65,7 @@ > :safe #'stringp) > > (defvar org-babel-js-function-wrapper > - "require('sys').print(require('sys').inspect(function(){\n%s\n}()));" > + "require('process').stdout.write(require('util').inspect(function(){%s}()));" > "Javascript code to print value of body.") > > (defun org-babel-execute:js (body params) I can confirm that I just encountered this bug today and that Ivan's patch resolves the issue. See here for more information: https://nodejs.org/api/deprecations.html#deprecations_dep0025_require_sys Best, Matt