Code Monkey home page Code Monkey logo

Comments (6)

korczis avatar korczis commented on May 18, 2024

I am experiencing this too. It has some problems coloring large list because of that recursion.

from chalk.

korczis avatar korczis commented on May 18, 2024

Btw in my case it crashes after 457 files.

from chalk.

sindresorhus avatar sindresorhus commented on May 18, 2024

Would any of you mind posting a complete test case demonstrating the problem?

from chalk.

jahvi avatar jahvi commented on May 18, 2024

The simpler test case I can think of is:

  1. Run yo generator (let's say the generator is called "test")
  2. Replace all prototype functions in app/index.js with:
TestGenerator.prototype.getWp = function getWp() {
  var done = this.async();

    this.log.writeln('Getting WordPress v3.6');

    this.remote('wordpress', 'wordpress', '3.6', function (err, remote) {
        if (err) {
            done(err);
        }
        remote.directory('.', '.');
        done();
    });
};
  1. Run yo test

I get the error after ~486 files

PD: I'm running Win7 64bits if that helps

from chalk.

sindresorhus avatar sindresorhus commented on May 18, 2024

Tried your test case. I'm pretty sure the problem is not in Chalk, as I also got call stack error in mkdirp. Looks like there is some endless recursion in the generator system. Probably with action.copy().

/Users/sindresorhus/dev/generator-generator/node_modules/yeoman-generator/node_modules/mkdirp/index.js:74
                    throw err0;
                          ^
RangeError: Maximum call stack size exceeded

Mind opening up a ticket over at https://github.com/yeoman/generator/ ?

from chalk.

korczis avatar korczis commented on May 18, 2024

Sorry for bothering you. I did opened yeoman/generator ticket: yeoman/generator#350

from chalk.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.