Skip to content

stylus-shell.js: TypeError: Object #<Renderer> has no method 'deps' #5

Open
@helllamer

Description

@helllamer

Good day.

I've stumbled over runtime exception in stylus-shell.js.

NOTE: this issue reproduceable only in 5-10% developers workstations, but in 100% cases on this 5-10% workstations.

So, let's look at log:

$ sbt
[proj2] $ assets
[info] Stylus compiling on 1 source(s)
[error] [TypeError: Object #<Renderer> has no method 'deps']
[info] 
[success] Total time: 1 s, completed Jun 27, 2014 3:25:28 PM
[proj2] $ ^D

$ ls -R target/web/stylus
target/web/stylus/main/stylesheets:
main.css

As you can see, sbt-stylus printed error, printed "success" and successfully compiled .styl sources.

Let's look at stylus-shell.js:

  }).then(function(result) {
    return {
      source: input,
      result: {
          filesRead: [input].concat(result.style.deps()),
          filesWritten: [output]
      }
    };

As you can see, dangerous .deps() method is called here, not in stylus.

Problem goes away, if I replace .concat(result.style.deps()), with ,:

  }).then(function(result) {
    return {
      source: input,
      result: {
          filesRead: [input],
          filesWritten: [output]
      }
    };

This is quick and dirty solution, but it works. Hope, there will be better solution...

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions