View Issue Details

IDProjectCategoryView StatusLast Update
0017047CentOS-8dnfpublic2020-04-05 21:39
Reportersffc 
PriorityhighSeverityminorReproducibilityalways
Status newResolutionopen 
PlatformOSCentosOS Version8.0
Product Version8.0.1905 
Target VersionFixed in Version 
Summary0017047: Node.js from AppStream common channel should not be built with "--debug-nghttp2"
DescriptionNode.js appears to be configured to print noisy debug output from http2 to stderr, and there is no way to suppress these messages. I originally filed this bug as https://github.com/googleapis/nodejs-logging/issues/668, which got thrown around a couple of times before eventually figuring out the root cause of the problem.

As found by mscdex in https://github.com/nodejs/node/issues/31763#issuecomment-585613734, the rpm file for nodejs has the following flags:

#%if ! 0%%{?bootstrap}
%if %{with bootstrap}
./configure --prefix=%{_prefix}
--shared-openssl
--shared-zlib
--without-dtrace
--with-intl=small-icu
--debug-nghttp2
--openssl-use-def-ca-store
%else
./configure --prefix=%{_prefix}
--shared-openssl
--shared-zlib
--shared-libuv
--shared-http-parser
--shared-nghttp2
--with-dtrace
--with-intl=%{icu_flag}
--debug-nghttp2
--openssl-use-def-ca-store
%endif

The flag "--debug-nghttp2" appears to be what is causing these noisy messages to be printed. This would be acceptable in the development channel, but in the common channel, I expect Node.js to not print these messages.
Steps To ReproduceRun "sudo yum install nodejs", then run "node demo.js" with the following script:


const http2 = require('http2');
const client = http2.connect('https://www.google.com');
client.on('error', (err) => console.error(err));

const req = client.request({ ':path': '/' });

req.on('response', (headers, flags) => {
  for (const name in headers) {
    console.log(`${name}: ${headers[name]}`);
  }
});

req.setEncoding('utf8');
let data = '';
req.on('data', (chunk) => { data += chunk; });
req.on('end', () => {
  console.log(`\nReceived ${data.length} bytes of data.`);
  client.close();
});
req.end();
Tagsnodejs

Activities

sffc

sffc

2020-04-05 21:39

reporter   ~0036651

Any updates?

Issue History

Date Modified Username Field Change
2020-02-13 09:21 sffc New Issue
2020-02-13 09:21 sffc Tag Attached: nodejs
2020-04-05 21:39 sffc Note Added: 0036651