From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ivan Sokolov Subject: ob-js uses deprecated Node APIs Date: Wed, 11 Mar 2020 02:47:40 +0300 Message-ID: <7652301583883715@vla1-a6eaa355d163.qloud-c.yandex.net> Mime-Version: 1.0 Content-Type: text/plain Content-Transfer-Encoding: 7bit Return-path: Received: from eggs.gnu.org ([2001:470:142:3::10]:47269) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jBobE-00071n-Ud for emacs-orgmode@gnu.org; Tue, 10 Mar 2020 19:47:50 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1jBobD-0002Zi-4c for emacs-orgmode@gnu.org; Tue, 10 Mar 2020 19:47:47 -0400 Received: from forward101o.mail.yandex.net ([2a02:6b8:0:1a2d::601]:48955) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1jBobC-0002SL-BP for emacs-orgmode@gnu.org; Tue, 10 Mar 2020 19:47:47 -0400 Received: from forward101q.mail.yandex.net (forward101q.mail.yandex.net [IPv6:2a02:6b8:c0e:4b:0:640:4012:bb98]) by forward101o.mail.yandex.net (Yandex) with ESMTP id 84CD53C020CB for ; Wed, 11 Mar 2020 02:47:41 +0300 (MSK) Received: from mxback10q.mail.yandex.net (mxback10q.mail.yandex.net [IPv6:2a02:6b8:c0e:1b4:0:640:b6ef:cb3]) by forward101q.mail.yandex.net (Yandex) with ESMTP id 82C96CF40002 for ; Wed, 11 Mar 2020 02:47:41 +0300 (MSK) List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane-mx.org@gnu.org Sender: "Emacs-orgmode" To: emacs-orgmode@gnu.org 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)