0

I'm configuring Django Pipeline, which I have done before on Linux without issues. On OSX I get the following issue when using Less:

CompilerError: env: node: No such file or directory

The message comes from the stderr of the command pipeline is trying to execute:

/usr/local/bin/lessc  /foo/bootstrap.less /bar/bootstrap.css

Which I can run from the terminal without any issues with the Python virtualenv active (or not). I have tried installing lessc with and without the -g flag.

It seems node and lessc are setup fine on the system and PIPELINE_LESS_BINARY is set correctly but no joy.

Node and Less were installed with brew on OSX 10.10 (yosemite)

Any ideas?

Aiden Bell
  • 28,212
  • 4
  • 75
  • 119

1 Answers1

2

I presume the env your django commands operates on does not have the PATH setted correctly for node, a hacky solution could be to locate the node binary with which node and then link it to /usr/bin:

sudo ln -s node_binary_path /usr/bin/node
DRC
  • 4,898
  • 2
  • 21
  • 35
  • 1
    Yes this worked. `node` was in `/usr/local/bin/` and `env` was in `/usr/bin/env`, so even though it worked from the shell either Python's path is wrong or `env` does something odd. – Aiden Bell Dec 02 '14 at 22:27