Your message dated Sun, 06 Feb 2022 18:07:07 +0000
with message-id <e1nglwj-000ftj...@fasolo.debian.org>
and subject line Bug#1003039: fixed in node-terser 4.8.0-2
has caused the Debian Bug report #1003039,
regarding node-terser: Please update node-commander dependency to version 8
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact ow...@bugs.debian.org
immediately.)


-- 
1003039: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1003039
Debian Bug Tracking System
Contact ow...@bugs.debian.org with problems
--- Begin Message ---
Package: node-terser
Version: 4.1.2-9
Severity: important
Tags: patch

Hi,

node-commander 8 changed option parsing. Here is a proposed patch to be
used in replacement of 1001_use_commander_4.patch
Description: support node module commander release 8
 same patch than uglifyjs
Author: Yadd <y...@debian.org>
Forwarded: no
Last-Update: 2022-01-03

--- a/bin/uglifyjs
+++ b/bin/uglifyjs
@@ -28,6 +28,15 @@
 program.version(info.name + " " + info.version);
 program.parseArgv = program.parse;
 program.parse = undefined;
+var argv = [];
+process.argv.forEach(function(arg){
+  if(arg.match(/^-([pcmbode]+)$/)) {
+    argv = argv.concat(RegExp.$1.split('').map(s => { return '-'+s }));
+  }
+  else argv.push(arg);
+});
+process.argv = argv;
+
 if (process.argv.includes("ast")) program.helpInformation = describe_ast;
 else if (process.argv.includes("options")) program.helpInformation = 
function() {
     var text = [];
@@ -65,10 +74,11 @@
 program.option("--warn", "Print warning messages.");
 program.option("--wrap <name>", "Embed everything as a function with “exports” 
corresponding to “name” globally.");
 program.arguments("[files...]").parseArgv(process.argv);
-if (program.configFile) {
-    options = JSON.parse(read_file(program.configFile));
+const opts = program.opts();
+if (opts.configFile) {
+    options = JSON.parse(read_file(opts.configFile));
 }
-if (!program.output && program.sourceMap && program.sourceMap.url != "inline") 
{
+if (!opts.output && opts.sourceMap && opts.sourceMap.url != "inline") {
     fatal("ERROR: cannot write source map to STDOUT");
 }
 [
@@ -82,83 +92,83 @@
     "toplevel",
     "wrap"
 ].forEach(function(name) {
-    if (name in program) {
-        options[name] = program[name];
+    if (name in opts) {
+        options[name] = opts[name];
     }
 });
-if ("ecma" in program) {
-    if (program.ecma != (program.ecma | 0)) fatal("ERROR: ecma must be an 
integer");
-    options.ecma = program.ecma | 0;
+if ("ecma" in opts) {
+    if (opts.ecma != (opts.ecma | 0)) fatal("ERROR: ecma must be an integer");
+    options.ecma = opts.ecma | 0;
 }
-if (program.beautify) {
-    options.output = typeof program.beautify == "object" ? program.beautify : 
{};
+if (opts.beautify) {
+    options.output = typeof opts.beautify == "object" ? opts.beautify : {};
     if (!("beautify" in options.output)) {
         options.output.beautify = true;
     }
 }
-if (program.comments) {
+if (opts.comments) {
     if (typeof options.output != "object") options.output = {};
-    options.output.comments = typeof program.comments == "string" ? 
program.comments : "some";
+    options.output.comments = typeof opts.comments == "string" ? opts.comments 
: "some";
 }
-if (program.define) {
+if (opts.define) {
     if (typeof options.compress != "object") options.compress = {};
     if (typeof options.compress.global_defs != "object") 
options.compress.global_defs = {};
-    for (var expr in program.define) {
-        options.compress.global_defs[expr] = program.define[expr];
+    for (var expr in opts.define) {
+        options.compress.global_defs[expr] = opts.define[expr];
     }
 }
-if (program.keepClassnames) {
+if (opts.keepClassnames) {
     options.keep_classnames = true;
 }
-if (program.keepFnames) {
+if (opts.keepFnames) {
     options.keep_fnames = true;
 }
-if (program.mangleProps) {
-    if (program.mangleProps.domprops) {
-        delete program.mangleProps.domprops;
+if (opts.mangleProps) {
+    if (opts.mangleProps.domprops) {
+        delete opts.mangleProps.domprops;
     } else {
-        if (typeof program.mangleProps != "object") program.mangleProps = {};
-        if (!Array.isArray(program.mangleProps.reserved)) 
program.mangleProps.reserved = [];
+        if (typeof opts.mangleProps != "object") opts.mangleProps = {};
+        if (!Array.isArray(opts.mangleProps.reserved)) 
opts.mangleProps.reserved = [];
     }
     if (typeof options.mangle != "object") options.mangle = {};
-    options.mangle.properties = program.mangleProps;
+    options.mangle.properties = opts.mangleProps;
 }
-if (program.nameCache) {
-    options.nameCache = JSON.parse(read_file(program.nameCache, "{}"));
+if (opts.nameCache) {
+    options.nameCache = JSON.parse(read_file(opts.nameCache, "{}"));
 }
-if (program.output == "ast") {
+if (opts.output == "ast") {
     options.output = {
         ast: true,
         code: false
     };
 }
-if (program.parse) {
-    if (!program.parse.acorn && !program.parse.spidermonkey) {
-        options.parse = program.parse;
-    } else if (program.sourceMap && program.sourceMap.content == "inline") {
+if (opts.parse) {
+    if (!opts.parse.acorn && !opts.parse.spidermonkey) {
+        options.parse = opts.parse;
+    } else if (opts.sourceMap && opts.sourceMap.content == "inline") {
         fatal("ERROR: inline source map only works with built-in parser");
     }
 }
 if (~program.rawArgs.indexOf("--rename")) {
     options.rename = true;
-} else if (!program.rename) {
+} else if (!opts.rename) {
     options.rename = false;
 }
 var convert_path = function(name) {
     return name;
 };
-if (typeof program.sourceMap == "object" && "base" in program.sourceMap) {
+if (typeof opts.sourceMap == "object" && "base" in opts.sourceMap) {
     convert_path = function() {
-        var base = program.sourceMap.base;
+        var base = opts.sourceMap.base;
         delete options.sourceMap.base;
         return function(name) {
             return path.relative(base, name);
         };
     }();
 }
-if (program.verbose) {
+if (opts.verbose) {
     options.warnings = "verbose";
-} else if (program.warn) {
+} else if (opts.warn) {
     options.warnings = true;
 }
 
@@ -196,24 +206,24 @@
     UglifyJS.AST_Node.warn_function = function(msg) {
         print_error("WARN: " + msg);
     };
-    var content = program.sourceMap && program.sourceMap.content;
+    var content = opts.sourceMap && opts.sourceMap.content;
     if (content && content !== "inline") {
         options.sourceMap.content = read_file(content, content);
     }
-    if (program.timings) options.timings = true;
+    if (opts.timings) options.timings = true;
     try {
-        if (program.parse) {
-            if (program.parse.acorn) {
+        if (opts.parse) {
+            if (opts.parse.acorn) {
                 files = convert_ast(function(toplevel, name) {
                     return require("acorn").parse(files[name], {
                         ecmaVersion: 2018,
                         locations: true,
                         program: toplevel,
                         sourceFile: name,
-                        sourceType: options.module || program.parse.module ? 
"module" : "script"
+                        sourceType: options.module || opts.parse.module ? 
"module" : "script"
                     });
                 });
-            } else if (program.parse.spidermonkey) {
+            } else if (opts.parse.spidermonkey) {
                 files = convert_ast(function(toplevel, name) {
                     var obj = JSON.parse(files[name]);
                     if (!toplevel) return obj;
@@ -252,7 +262,7 @@
             print_error(format_object(ex.defs));
         }
         fatal(ex);
-    } else if (program.output == "ast") {
+    } else if (opts.output == "ast") {
         if (!options.compress && !options.mangle) {
             result.ast.figure_out_scope({});
         }
@@ -286,7 +296,7 @@
             }
             return value;
         }, 2));
-    } else if (program.output == "spidermonkey") {
+    } else if (opts.output == "spidermonkey") {
         print(JSON.stringify(UglifyJS.minify(result.code, {
             compress: false,
             mangle: false,
@@ -295,16 +305,16 @@
                 code: false
             }
         }).ast.to_mozilla_ast(), null, 2));
-    } else if (program.output) {
-        fs.writeFileSync(program.output, result.code);
+    } else if (opts.output) {
+        fs.writeFileSync(opts.output, result.code);
         if (result.map) {
-            fs.writeFileSync(program.output + ".map", result.map);
+            fs.writeFileSync(opts.output + ".map", result.map);
         }
     } else {
         print(result.code);
     }
-    if (program.nameCache) {
-        fs.writeFileSync(program.nameCache, JSON.stringify(options.nameCache));
+    if (opts.nameCache) {
+        fs.writeFileSync(opts.nameCache, JSON.stringify(options.nameCache));
     }
     if (result.timings) for (var phase in result.timings) {
         print_error("- " + phase + ": " + result.timings[phase].toFixed(3) + 
"s");

--- End Message ---
--- Begin Message ---
Source: node-terser
Source-Version: 4.8.0-2
Done: Jonas Smedegaard <d...@jones.dk>

We believe that the bug you reported is fixed in the latest version of
node-terser, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 1003...@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Jonas Smedegaard <d...@jones.dk> (supplier of updated node-terser package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmas...@ftp-master.debian.org)


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512

Format: 1.8
Date: Sun, 06 Feb 2022 17:57:38 +0100
Source: node-terser
Architecture: source
Version: 4.8.0-2
Distribution: experimental
Urgency: medium
Maintainer: Debian Javascript Maintainers 
<pkg-javascript-de...@lists.alioth.debian.org>
Changed-By: Jonas Smedegaard <d...@jones.dk>
Closes: 1003039
Changes:
 node-terser (4.8.0-2) experimental; urgency=medium
 .
   * update copyright info:
     + use Reference field (not License-Reference);
       tighten lintian overrides
     + update coverage
   * simplify source helper script copyright-check
   * declare compliance with Debian Policy 4.6.0
   * update (and rename) patch 1001 to support commander v8;
     tighten to (build-)depend versioned on node-commander;
     closes: bug#1003039, thanks to Yadd
   * generate documentation with cmark-gfm (not pandoc);
     build-depend on cmark-gfm (not pandoc)
   * tediously update lintian overrides
Checksums-Sha1:
 f2f9d005e6220de70cf75908a8f58c8bd64e842e 2402 node-terser_4.8.0-2.dsc
 5657c6db5b38e6ebbd5249a1499ba230ac3727d9 11584 
node-terser_4.8.0-2.debian.tar.xz
 47d762a82863db2c837b7ed203c2430c49874d38 15076 
node-terser_4.8.0-2_amd64.buildinfo
Checksums-Sha256:
 43aab64c4de00250cf1d8edf422783c6717889e89dd8c35aa357e69af63d33e7 2402 
node-terser_4.8.0-2.dsc
 ef1fc055515b25efde1be30f52448be65fc28c3b23c9d3dc1be8d10ebbd2e94e 11584 
node-terser_4.8.0-2.debian.tar.xz
 2df0bc09b6458b92201c82ef765c8ac9c68f48626a2c252faf5214b901661eb6 15076 
node-terser_4.8.0-2_amd64.buildinfo
Files:
 80d462d841f6040666cc3384a8977b54 2402 javascript optional 
node-terser_4.8.0-2.dsc
 07cbaa584322f179262933397aaa73b4 11584 javascript optional 
node-terser_4.8.0-2.debian.tar.xz
 e638937070af7c003b8c51d2db11ad00 15076 javascript optional 
node-terser_4.8.0-2_amd64.buildinfo

-----BEGIN PGP SIGNATURE-----

iQIzBAEBCgAdFiEEn+Ppw2aRpp/1PMaELHwxRsGgASEFAmIADAMACgkQLHwxRsGg
ASHOVBAArWIziZbRBoJsL/dzO8L5FlAAQzTkg9UJlcTuESygI+PH+L/d7OSUtFNZ
Fh6UXkC23/eCeUBor8Xq+H5zLujZqdAd9VyThRjr6bCJExUKEa9vBScMuvOj6qjQ
NR6WRjT/busNuq6JTAVInn1wA80MJ2cgCl3DSjOxAIg70WQvjThxNALLvYz6ARVi
56pV7kYXdfmjdk90vVKXcCA3Eq0Vhs4gYjCkOC0Hsl6rUlYb6ZTDDz4fMRU6l+KH
R6KXPVfiSWCfD6aGkNFb+tdUG8CozTrPl0ctGcnFv/r/0T3gQzta2odR5O0QzVsQ
DUocSOnbUg3dsxTKFc9saSL2aJ1M3F8f3mAIXeSSEGzcp+IM6cJbuUkpvsR7IkJM
th/T+XGG83+ASsIVwMozFyn7cYcqZvYmeB8B9iephrHAqf4VMoexbYESS+9P5QeK
VtrcotFF7aj0DPWGA/yNY5wPxEq6OOc2YitaQ5H7kelAEgCDCW1Qk9wcL1RPry5V
FEEl7F42LvdgZe3/GbUuZxv7z/Ug/3/WhXdcVLtAzQNfn7L9WvuU1yhvirtULOEk
O4TlfNlYaM8btDu0v5SaOn7CDnDwKux4uKGjJsvLhi6kOOZtS+koOdwVWt/gWD1X
Rfd8QsBBxz0/XFXWHEFh9Z5NOc9H1rHsIFywPaVaIjxREEd7HFk=
=wbLf
-----END PGP SIGNATURE-----

--- End Message ---

Reply via email to