Skip to content

Some URL's causes library to "hang" #42

Description

@florisvink

Parsing the URL "https://www.zalando.nl/nike-performance-trainingsbroek-blackcool-grey-n1241e0em-q11.html" causes the library to hang. It does not crash, but rather hangs for a very long time at 100% cpu-core consumption. Memory does not increase significantly.

Code to reproduce the problem:

const fetch = require('node-fetch');
const mf = require('microformat-node');

const fetchUrl = url => fetch(url)
    .then(res  => res.text())
    .then(html => mf.getAsync({html}));

fetchUrl('https://www.zalando.nl/nike-performance-trainingsbroek-blackcool-grey-n1241e0em-q11.html')

microformat-node version: 2.0.1
node version: v8.9.4 (also tested with v6.11.5 with same problem)

Could you please give me some pointers where to start looking in the code for a possible cause of this problem. Thanks!

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions