unfortunately i’m getting a different kind of error

but just confirming to properly troubleshoot, should druid be able to open with crow connected?

No, the REPL won’t open but it’ll currently output this when Crow isn’t connected:

$ druid
can't find crow device

So you can use this to check if druid itself works.

It sounds like the path that pip used to install the druid executable to is not on your $PATH, as @csboling mentioned pip should’ve shown a message to indicate that this is the case.

P.S. I haven’t used mac OS in ages and I don’t know how you installed Python but in general I’d suggest to install stuff on mac OS using homebrew. AFAIK homebrew also takes care of adding the installed Python’s bin location to $PATH.

3 Likes

thanks for offering some assistance

all common sense or googleable solutions seem to be failing while trying to blindly follow the documented instructions

before i proceed with attempts i need some tips

  • does python run within terminal or should i be opening a standalone app?

  • should druid be downloaded from gh before installation?

  • druid program or druid executable…which file is this? should i be looking for druid.py druid.exe…something else?

i have more questions but lets try these for starters

Python runs within Terminal, but you do not need to use Python directly to run druid. It’s just that druid is written in Python and needs the right Python stuffs to be on your machine.

You should not need to get druid from github unless you want to modify druid’s code. It’s recommended to install the monome-druid package using pip.

On a Mac, the file should just be called druid. I’m not sure where exactly this file winds up on OSX. Could someone on a Mac who’s gotten druid to work help out by sharing the output of the command:

which druid

The which program shows the exact file location where druid is installed, and if we can guess where that’s supposed to be you should be able to edit your PATH to tell Terminal how to find it. Once you’ve done that, it should be possible to close and reopen Terminal, then type just druid to run druid, no matter where the actual program file is or which folder you’re looking at in Terminal.


Terminal is the program used on Mac to access the default “shell” for interacting with your operating system, letting you move around to different directories (cd some-dir/), list files (ls) read text files (cat file.txt), and run programs (including: cd, ls, cat, brew, python3, pip3, druid, …). This is an example of a read-evaluate-print loop (REPL):

  • it reads your input,
  • evaluates it to see if it is a valid command and execute it if it knows how
  • then prints whatever the output was. A lot of programs (like cd for example) might print nothing at all unless something is wrong (directory not found, etc.)
  • then loops back to the top, waiting for new input.

Some programs you run are themselves REPLs. Python is one such example, but you should not need to use Python to use druid, you just need to use it to install some stuff. But if you were to run just python3 by itself, the default behavior is to show you a Python REPL, that looks something like this:

$ python3
Python 3.7.4 (tags/v3.7.4:e09359112e, Jul  8 2019, 19:29:22)
Type "help", "copyright", "credits" or "license" for more information.
>>> quit()

$

It’s common for the default operating system REPL (the “shell”) to show you an $ prompt, whereas >>> is the prompt Python uses. Often there will be something like a username and/or directory name before the $ in the default shell. But we don’t need to do anything inside Python in order to set up or use druid, so we use quit() to exit back to the shell.

pip is another program written in Python for installing Python packages. druid is published as a Python package, so to get it, you need pip. But to get pip working, you need to first get Python set up. Then you need to update pip, but pip sorta can’t update itself (or something??) so you have to use python3 to run the pip package, which you’re instructing to install pip, but to upgrade pip instead if it’s already installed, and the whole thing gets to be sort of a mouthful:

python3       -m               pip    install --upgrade pip
^^^^^^^       ^^               ^^^    ^^^^^^^^^^^^^^^^^^^^^
hey python,   run the module   "pip"  and pass this stuff to the "pip" module

Adding to the confusion, Mac and Linux systems were already relying heavily on Python 2 and calling its tools python (the Python interpreter) and pip when the backwards-incompatible Python 3 came out, so on most systems these are called python3 and pip3 to avoid breaking stuff that is/was still depending on Python 2. This means that to use pip on its own you actually want to run pip3 so that you’re not trying to install Python 3 packages into a Python 2 environment. But the actual package for pip is called pip, not pip3, so inside of Python it’s just called pip, hence python3 -m pip.

So that’s a whole ordeal! But now we’re ready to install actual Python packages. Currently, setuptools is also needed to run the installation process for druid, so we install that first.

pip3 install --upgrade setuptools
pip3 install monome-druid

The good news is that after going through all this trouble, the only thing you should need to run to update druid in the future is pip3 install --upgrade monome-druid.

At this point, what’s supposed to happen is that pip should put the druid program in some place where your shell (Terminal) can find it. If that doesn’t work, pip is supposed to print out a message telling you where the program is and that it’s not accessible to your terminal until you add it to your PATH variable.

Interestingly, to sort of come full circle: even if the druid program is not on your PATH, druid is just a Python program, and once it’s installed its code is accessible to Python. This means that you can actually run the druid REPL inside a Python REPL inside your Terminal REPL:

$ python3
Python 3.7.4 (tags/v3.7.4:e09359112e, Jul  8 2019, 19:29:22)
Type "help", "copyright", "credits" or "license" for more information.
>>> from druid.cli import repl
>>> repl()
//// druid. q to quit. h for help

> q
bye.
>>> quit()

$
5 Likes

/Library/Frameworks/Python.framework/Versions/3.7/bin/druid

1 Like

Do you know how you installed Python?

Me? I followed the instructions for druid. However, I do remember there was some weirdness and it didn’t work perfect at first but I can’t remember what was (or I did) wrong. I think it had something to do with the distinction between pip and pip3.

2 Likes

Just to be sure, you downloaded it using your browser from the Python website and then?

@csboling

Sam, you’re overwhelmingly awesome!

Thanks so much, I just got schooled…

1 Like

I recall something like this as well but it didn’t take much to fix it…

Hi friends. Was wondering if someone could hold my hand through uploading scripts from Bowery to Crow. I’ve gotten as far as cd to where the boids.lua file is located, running druid in the terminal from that dir, and then in druid typing u boids.lua. Then it seems to freeze. Druid seems to be working well b/c when i manually type in votage changes I can see them taking effect (have the outputs connected to a scope)…any tips?

edit: tried the 'ol IT Crowd turning it off and on again a few times, and was then able to load up some scripts. I still occasionally get certain scripts which cause Druid to freeze, but it seems random.

Am I correct in my understanding that there is no mechanism for scheduling a single event in the future? That is, not a repeated event like with metro, but just scheduling something arbitrarily in the future along the lines of:

futureevent.go(timefromnow = 2.0, event = future_event)

or maybe:

futureevent.go(atclocktime = 976800, event = future_event)

If figured out how to kludge this functionality using a metro with a count of one, but I wanted to confirm that there wasn’t a better way to do it.

I know I read this somewhere but was not able to find it through search but if I upload a different script to run from bowery into crow how can I get back to the first script?

Is it as simple as?

crow.reset()

All commands supported by crow are documented here https://monome.org/docs/crow/technical/#environment-commands
In this case you’re looking for the one called “first”.

Can I ask why you couldn’t find this? I’m wondering if this info is possibly in the wrong place.

1 Like

When I search crow and first it brings up too many results. Not specific enough of a search.

Edit: didn’t realize it was in the docs. I was searching the forum

I ran into this error and I’m not sure what it means. I was trying to upload scripts via druid and they wouldnt work so I decided to update my crows and I needed to install home-brew (new MacBook so I never did any of the homebrew stuff on here before) and this popped up. I never had an issue installing homebrew on my last computer. not sure if there were different batches of crow or if that even matters but mine were from the first shipment. any and all help is welcome and appreciated. thank ya!

1 Like

try running the sudo chown -R ... etc line that homebrew outputted in your screenshot and re-run brew update, iirc that’s an error that happens with permissions etc.

1 Like

that absolutely got the job done! thank you very much!

1 Like

ive installed the latest Python and it still tells me I’m using the version 2. when I type “pip --version” im told that the command is not found. im getting super frustrated and am feeling defeated by all of this. I feel as though im following instructions to a T and am getting nowhere. my goal is to update the crows and get uploading scripts via druid. I assume I MUST update bc every upload attempt just says uploading and never finishes. not sure what to do anymore. I guess I don’t even know what im asking at this point

You may need to use python3 and pip3 depending on how its setup on your system.