Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Exercise 9: TypeError: Cannot read property 'pipe' of undefined #134

Open
inomdzhon opened this issue Oct 29, 2017 · 5 comments
Open

Exercise 9: TypeError: Cannot read property 'pipe' of undefined #134

inomdzhon opened this issue Oct 29, 2017 · 5 comments

Comments

@inomdzhon
Copy link

When I run my programm promise-it-wont-hurt run 9-throw-an-error.js I get next error:

/Users/i.mirdzhamolov/.nvm/versions/node/v6.11.4/lib/node_modules/promise-it-wont-hurt/exercises/throw_an_error/exercise.js:31
  tuple(this.submissionStdout.pipe(split()), this.solutionStdout.pipe(split()))
                                                                ^

TypeError: Cannot read property 'pipe' of undefined
    at Exercise.<anonymous> (/Users/i.mirdzhamolov/.nvm/versions/node/v6.11.4/lib/node_modules/promise-it-wont-hurt/exercises/throw_an_error/exercise.js:31:65)
    at next (/Users/i.mirdzhamolov/.nvm/versions/node/v6.11.4/lib/node_modules/promise-it-wont-hurt/node_modules/workshopper-exercise/exercise.js:188:19)
    at /Users/i.mirdzhamolov/.nvm/versions/node/v6.11.4/lib/node_modules/promise-it-wont-hurt/node_modules/workshopper-exercise/exercise.js:195:7
    at /Users/i.mirdzhamolov/.nvm/versions/node/v6.11.4/lib/node_modules/promise-it-wont-hurt/node_modules/workshopper-exercise/execute.js:110:7
    at _combinedTickCallback (internal/process/next_tick.js:73:7)
    at process._tickCallback (internal/process/next_tick.js:104:9)

But promise-it-wont-hurt verify 9-throw-an-error.js is passed.

My code:

require('es6-promise');

function parsePromised(data) {
  return new Promise(function (fulfill, reject) {
    try {
      fulfill(JSON.parse(data));
    } catch (e) {
      reject(e);
    }
  });
}

parsePromised(process.argv[2])
  .catch(function (error) {
    console.log(error.message);
  });
@Aseelaldallal
Copy link

Same here.

Even if my JS file is just
console.log("HI!!!!")

@Aseelaldallal
Copy link

i just used verify instead of run and it worked fine.

@MalutkiSiwy
Copy link

I just deleted this "pipe" and work fine for me didnt crash or something

@luucamay
Copy link

@MalutkiSiwy where did you deleted the 'pipe'? I am running with the same issue.

@dovhanrg
Copy link

Does anyone figured out what pipe to delete?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants