tidalcycles / pulsar-tidalcycles

Pulsar plugin for TidalCycles
https://web.pulsar-edit.dev/packages/tidalcycles
GNU General Public License v3.0
50 stars 28 forks source link

Uncaught Error: EISDIR: illegal operation on a directory #177

Closed falanges closed 2 years ago

falanges commented 2 years ago

Hi! I'm facing the following error in my MacBook Pro M1 -arm64-. SO Monterrey.

[Enter steps to reproduce:]

1. ...
2. ...

**Atom**: 1.58.0 x64
**Electron**: 9.4.4
**OS**: macOS 12.0.1
**Thrown From**: [tidalcycles](ssh://git@github.com/tidalcycles/atom-tidalcycles) package 3.16.17

### Stack Trace

Uncaught Error: EISDIR: illegal operation on a directory, read

At internal/fs/utils.js:220

Error: EISDIR: illegal operation on a directory, read at Object.readSync (fs.js:506:3) at tryReadSync (fs.js:331:20) at Object.readFileSync (fs.js:368:19) at Object.fs.readFileSync (electron/js2c/asar.js:542:40) at BootTidal.blocks (/packages/tidalcycles/lib/boot-tidal.js:57:15) at REPL.initTidal (/packages/tidalcycles/lib/repl.js:40:22) at REPL.start (/packages/tidalcycles/lib/repl.js:29:10) at REPL._eval (/packages/tidalcycles/lib/repl.js:84:26) at HTMLElement.tidalcyclesEvalMultiLine (/packages/tidalcycles/lib/tidalcycles.js:72:56) at CommandRegistry.handleCommandEvent (/Applications/Atom.app/Contents/Resources/app/static/:11:352326) at KeymapManager.dispatchCommandEvent (/Applications/Atom.app/Contents/Resources/app/static/:11:1227728) at KeymapManager.handleKeyboardEvent (/Applications/Atom.app/Contents/Resources/app/static/:11:1223862) at WindowEventHandler.handleDocumentKeyEvent (/Applications/Atom.app/Contents/Resources/app/static/:11:286651)


### Commands
 -0:04.2.0 tidalcycles:eval-multi-line (input.hidden-input)

### Non-Core Packages

OSCSourceCodeSenderView 0.0.1 tidalcycles 3.16.17

So, i have to use another interpeter (vim tidal) and it works fine. Feel free to contact me for any doubts about the bug. Cheers

ndr-brt commented 2 years ago

Hi, can you report the output from the tidalcycles console?

falanges commented 2 years ago

I guess you are asking for this (sorry if it's not)

Choose ghc base path
 * custom path configured
Ghci command: /opt/homebrew/bin/ghci
Ghc-pkg command: /opt/homebrew/bin/ghc-pkg
Choose BootTidal.hs path
 * custom path configured
 * load BootTidal.hs from /Users/myUser/Library/Application Support/SuperCollider/
t> 
Loaded package environment from /Users/myUser/.ghc/aarch64-darwin-8.10.7/environments/default
t> 
ndr-brt commented 2 years ago

What have you configured as "BootTidal path"? Because from the console log seems like you configured /Users/myUser/Library/Application Support/SuperCollider/, that's wrong for sure because that config should point to a valid BootTidal.hs file, and not to a folder.

falanges commented 2 years ago

Yes of course, the BootTidal.hs is into that path. In fact, the output confirm tha t BootTidal.hs are loaded from path. That file contains the following content (i didn't modify nothing):

:set -XOverloadedStrings
:set prompt ""

import Sound.Tidal.Context
import System.IO (hSetEncoding, stdout, utf8)
hSetEncoding stdout utf8

-- total latency = oLatency + cFrameTimespan
tidal <- startTidal (superdirtTarget {oLatency = 0.1, oAddress = "127.0.0.1", oPort = 57120}) (defaultConfig {cFrameTimespan = 1/20})

:{
let p = streamReplace tidal
    hush = streamHush tidal
    list = streamList tidal
    mute = streamMute tidal
    unmute = streamUnmute tidal
    solo = streamSolo tidal
    unsolo = streamUnsolo tidal
    once = streamOnce tidal
    first = streamFirst tidal
    asap = once
    nudgeAll = streamNudgeAll tidal
    all = streamAll tidal
    resetCycles = streamResetCycles tidal
    setcps = asap . cps
    xfade i = transition tidal True (Sound.Tidal.Transition.xfadeIn 4) i
    xfadeIn i t = transition tidal True (Sound.Tidal.Transition.xfadeIn t) i
    histpan i t = transition tidal True (Sound.Tidal.Transition.histpan t) i
    wait i t = transition tidal True (Sound.Tidal.Transition.wait t) i
    waitT i f t = transition tidal True (Sound.Tidal.Transition.waitT f t) i
    jump i = transition tidal True (Sound.Tidal.Transition.jump) i
    jumpIn i t = transition tidal True (Sound.Tidal.Transition.jumpIn t) i
    jumpIn' i t = transition tidal True (Sound.Tidal.Transition.jumpIn' t) i
    jumpMod i t = transition tidal True (Sound.Tidal.Transition.jumpMod t) i
    mortal i lifespan release = transition tidal True (Sound.Tidal.Transition.mortal lifespan release) i
    interpolate i = transition tidal True (Sound.Tidal.Transition.interpolate) i
    interpolateIn i t = transition tidal True (Sound.Tidal.Transition.interpolateIn t) i
    clutch i = transition tidal True (Sound.Tidal.Transition.clutch) i
    clutchIn i t = transition tidal True (Sound.Tidal.Transition.clutchIn t) i
    anticipate i = transition tidal True (Sound.Tidal.Transition.anticipate) i
    anticipateIn i t = transition tidal True (Sound.Tidal.Transition.anticipateIn t) i
    forId i t = transition tidal False (Sound.Tidal.Transition.mortalOverlay t) i
    d1 = p 1 . (|< orbit 0)
    d2 = p 2 . (|< orbit 1)
    d3 = p 3 . (|< orbit 2)
    d4 = p 4 . (|< orbit 3)
    d5 = p 5 . (|< orbit 4)
    d6 = p 6 . (|< orbit 5)
    d7 = p 7 . (|< orbit 6)
    d8 = p 8 . (|< orbit 7)
    d9 = p 9 . (|< orbit 8)
    d10 = p 10 . (|< orbit 9)
    d11 = p 11 . (|< orbit 10)
    d12 = p 12 . (|< orbit 11)
    d13 = p 13
    d14 = p 14
    d15 = p 15
    d16 = p 16
:}

:{
let setI = streamSetI tidal
    setF = streamSetF tidal
    setS = streamSetS tidal
    setR = streamSetR tidal
    setB = streamSetB tidal
:}

:set prompt "tidal> "
:set prompt-cont ""
ndr-brt commented 2 years ago

I mean, you have to specify the path with the filename, not just the folder:

/Users/myUser/Library/Application Support/SuperCollider/BootTidal.hs

Try to set that and let me know

falanges commented 2 years ago

Solved! thanks, its all my own mistake.