Can't Open Sonic Pi 3.1.0... Error


#21

To me it looks like the edited line has not the desired effect of disableing input.
Did I make a mistake? Is there anywhere else I can change the code to disalbe it? I tried to understand the code but it seems I’m not enough of a coder…


#22

changing the line specifying the number of inputs to “0” as I described here does disable inputs to scsynth, and I have verified that this does happen.
PLAN B
However, if you still get an error it may be that the error is being generated by the “checking” sections of the boot procedure BEFORE scsynth is launched.
In this case you can make more drastic changes by changing the whole of the function boot_server_osx in the scsynthexternal.rb file to what is shown below.

I would give the following caveat:
DO take a copy of the original scsynthexternal.rb file so that you can revert to it if you wish.
I have tested this on a virtual install of mojave. However I do not have access to a mac-mini that obviously has the relevant hardware missing, and so is probably the cause of the error that you are getting: so it may be that there is still something elsewhere that prevents the program booting.
Obviously, this mod will prevent ANY input device (including usb connected ones) from being able to provide an input source to Sonic Pi.

It is similar to the state of affairs on Sonic Pi 3.0.1 for the Raspberry Pi which also has sound input switched off (again by setting the -i parameter to 0).
This is superceded on that machine by using an external sound card and selecting that, which then uses a different boot procedure.

    def boot_server_osx
      log_boot_msg
      puts "Boot - Booting on OS X"

      #num_inputs = 0
     #edit error in above line replaced below
      num_inputs = "0"
      boot_and_wait(scsynth_path,
                    "-u", @port.to_s,
                    "-a", num_audio_busses_for_current_os.to_s,
                    "-m", "131072",
                    "-D", "0",
                    "-R", "0",
                    "-l", "1",
                    "-i", num_inputs,
                    "-o", "16",
                    "-U", "#{native_path}/supercollider/plugins/",
                    "-b", num_buffers_for_current_os.to_s,
                    "-B", "127.0.0.1")
    end

#23

I am using the free app Sublime Text to edit the file.

I have replaced the original code section def boot_server_osx (starting on line 270 and originally ending at 337)
with your code.

I get the following error:

Sonic Pi Boot Error Report

==================

System Information


  • Sonic Pi version: 3.1.0

  • OS: macOS 10.14

GUI Log


/Users/oszt/.sonic-pi/log/gui.log


[GUI] - Detecting port numbers...

[GUI] - GUI OSC listen port 4558

[GUI] - port: 4558 [OK]

[GUI] - Server OSC listen port 4557

[GUI] - port: 4557 [OK]

[GUI] - Server incoming OSC cues port 4559

[GUI] - port: 4559 [OK]

[GUI] - Scsynth port 4556

[GUI] - port: 4556 [OK]

[GUI] - Server OSC out port 4558

[GUI] - GUI OSC out port 4557

[GUI] - Scsynth send port 4556

[GUI] - Erlang router port 4560

[GUI] - port: 4560 [OK]

[GUI] - OSC MIDI out port 4561

[GUI] - port: 4561 [OK]

[GUI] - OSC MIDI in port 4562

[GUI] - port: 4562 [OK]

[GUI] - Init script completed

[GUI] - using default editor colours

[GUI] - launching Sonic Pi Server:

[GUI] - starting UDP OSC Server on port 4558...

[GUI] - UDP OSC Server ready and listening

[GUI] - Ruby server pid registered: 506

[GUI] - waiting for Sonic Pi Server to boot...

.

[GUI] - Sonic Pi Server failed to start with this error message:

> Server Exception:

no implicit conversion of Integer into String

["/Applications/Sonic Pi.app/app/server/ruby/lib/sonicpi/scsynthexternal.rb:206:in `popen'", "/Applications/Sonic Pi.app/app/server/ruby/lib/sonicpi/scsynthexternal.rb:206:in `boot_and_wait'", "/Applications/Sonic Pi.app/app/server/ruby/lib/sonicpi/scsynthexternal.rb:275:in `boot_server_osx'", "/Applications/Sonic Pi.app/app/server/ruby/lib/sonicpi/scsynthexternal.rb:153:in `boot'", "/Applications/Sonic Pi.app/app/server/ruby/lib/sonicpi/scsynthexternal.rb:37:in `initialize'", "/Applications/Sonic Pi.app/app/server/ruby/lib/sonicpi/server.rb:78:in `new'", "/Applications/Sonic Pi.app/app/server/ruby/lib/sonicpi/server.rb:78:in `initialize'", "/Applications/Sonic Pi.app/app/server/ruby/lib/sonicpi/studio.rb:183:in `new'", "/Applications/Sonic Pi.app/app/server/ruby/lib/sonicpi/studio.rb:183:in `init_scsynth'", "/Applications/Sonic Pi.app/app/server/ruby/lib/sonicpi/studio.rb:56:in `initialize'", "/Applications/Sonic Pi.app/app/server/ruby/lib/sonicpi/lang/sound.rb:125:in `new'", "/Applications/Sonic Pi.app/app/server/ruby/lib/sonicpi/lang/sound.rb:125:in `block (2 levels) in included'", "/Applications/Sonic Pi.app/Contents/MacOS/../../app/server/ruby/bin/sonic-pi-server.rb:177:in `new'", "/Applications/Sonic Pi.app/Contents/MacOS/../../app/server/ruby/bin/sonic-pi-server.rb:177:in `<main>'"]

[GUI] - UDP OSC Server no longer listening

...........................................................

[GUI] - Critical error! Could not boot Sonic Pi Server.

[GUI] - stopping UDP OSC Server...

Server Errors


/Users/oszt/.sonic-pi/log/server-errors.log


Server Output


/Users/oszt/.sonic-pi/log/server-output.log


Sonic Pi server booting...

Using protocol: udp

Detecting port numbers...

Send port: 4558

Listen port: 4557

- OK

Scsynth port: 4556

- OK

Scsynth send port: 4556

- OK

OSC cues port: 4559

- OK

Erlang port: 4560

- OK

OSC MIDI out port: 4561

- OK

OSC MIDI in port: 4562

- OK

Booting server...

Booting Sonic Pi

----------------

Boot - Booting on OS X

Boot - Starting the SuperCollider server...

Boot - /Applications/Sonic Pi.app/app/server/native/scsynth -u 4556 -a 1024 -m 131072 -D 0 -R 0 -l 1 -i 0 -o 16 -U /Applications/Sonic Pi.app/app/server/native/supercollider/plugins/ -b 4096 -B 127.0.0.1

Failed to start server: no implicit conversion of Integer into String

/Applications/Sonic Pi.app/app/server/ruby/lib/sonicpi/scsynthexternal.rb:206:in `popen'

/Applications/Sonic Pi.app/app/server/ruby/lib/sonicpi/scsynthexternal.rb:206:in `boot_and_wait'

/Applications/Sonic Pi.app/app/server/ruby/lib/sonicpi/scsynthexternal.rb:275:in `boot_server_osx'

/Applications/Sonic Pi.app/app/server/ruby/lib/sonicpi/scsynthexternal.rb:153:in `boot'

/Applications/Sonic Pi.app/app/server/ruby/lib/sonicpi/scsynthexternal.rb:37:in `initialize'

/Applications/Sonic Pi.app/app/server/ruby/lib/sonicpi/server.rb:78:in `new'

/Applications/Sonic Pi.app/app/server/ruby/lib/sonicpi/server.rb:78:in `initialize'

/Applications/Sonic Pi.app/app/server/ruby/lib/sonicpi/studio.rb:183:in `new'

/Applications/Sonic Pi.app/app/server/ruby/lib/sonicpi/studio.rb:183:in `init_scsynth'

/Applications/Sonic Pi.app/app/server/ruby/lib/sonicpi/studio.rb:56:in `initialize'

/Applications/Sonic Pi.app/app/server/ruby/lib/sonicpi/lang/sound.rb:125:in `new'

/Applications/Sonic Pi.app/app/server/ruby/lib/sonicpi/lang/sound.rb:125:in `block (2 levels) in included'

/Applications/Sonic Pi.app/Contents/MacOS/../../app/server/ruby/bin/sonic-pi-server.rb:177:in `new'

/Applications/Sonic Pi.app/Contents/MacOS/../../app/server/ruby/bin/sonic-pi-server.rb:177:in `<main>'

Server is exiting.

Shutting down GUI...

Goodbye :-)

Scsynth Output


/Users/oszt/.sonic-pi/log/scsynth.log


# Starting SuperCollider 2018-12-17 16:17:36

Process Log


/Users/oszt/.sonic-pi/log/processes.log


Clearing pids: ["476"]

Clearing [476]

-- command /Applications/Sonic Pi.app/Contents/MacOS/../../app/server/native/ruby/bin/ruby --enable-frozen-string-literal -E utf-8 /Applications/Sonic Pi.app/Contents/MacOS/../../app/server/ruby/bin/sonic-pi-server.rb -u 4557 4558 4556 4556 4559 4560 4561 4562

-- removing /var/folders/m7/s006plh55p9dzvl0w6lqtd0h0000gn/T/sonic-pi-pids/476

-- unable to get ProcTable info for: 476

-- process: 476 not running

Finished clearing pids

Started [506] [-] /Applications/Sonic Pi.app/Contents/MacOS/../../app/server/native/ruby/bin/ruby --enable-frozen-string-literal -E utf-8 /Applications/Sonic Pi.app/Contents/MacOS/../../app/server/ruby/bin/sonic-pi-server.rb -u 4557 4558 4556 4556 4559 4560 4561 4562 [-] /var/folders/m7/s006plh55p9dzvl0w6lqtd0h0000gn/T/sonic-pi-pids/506


#24

Oops my mistake.
I originally had
“-i”, “0”,

then changed that to
num_inputs=0

“i”,num_inputs

which gave an integer rather than a string there.

change to this and try again.

    def boot_server_osx
      log_boot_msg
      puts "Boot - Booting on OS X"

      num_inputs = "0"
      boot_and_wait(scsynth_path,
                    "-u", @port.to_s,
                    "-a", num_audio_busses_for_current_os.to_s,
                    "-m", "131072",
                    "-D", "0",
                    "-R", "0",
                    "-l", "1",
                    "-i", num_inputs,
                    "-o", "16",
                    "-U", "#{native_path}/supercollider/plugins/",
                    "-b", num_buffers_for_current_os.to_s,
                    "-B", "127.0.0.1")
    end

(I’ve edited the first version in case others try to use it too)


#25

Thanks again for helping! I replaced the original boot_server_osx section with the one here. Unfortunately, I still get an error:

Sonic Pi Boot Error Report

==================

System Information


  • Sonic Pi version: 3.1.0

  • OS: macOS 10.14

GUI Log


/Users/oszt/.sonic-pi/log/gui.log


[GUI] - Detecting port numbers...

[GUI] - GUI OSC listen port 4558

[GUI] - port: 4558 [OK]

[GUI] - Server OSC listen port 4557

[GUI] - port: 4557 [OK]

[GUI] - Server incoming OSC cues port 4559

[GUI] - port: 4559 [OK]

[GUI] - Scsynth port 4556

[GUI] - port: 4556 [OK]

[GUI] - Server OSC out port 4558

[GUI] - GUI OSC out port 4557

[GUI] - Scsynth send port 4556

[GUI] - Erlang router port 4560

[GUI] - port: 4560 [OK]

[GUI] - OSC MIDI out port 4561

[GUI] - port: 4561 [OK]

[GUI] - OSC MIDI in port 4562

[GUI] - port: 4562 [OK]

[GUI] - Init script completed

[GUI] - using default editor colours

[GUI] - launching Sonic Pi Server:

[GUI] - starting UDP OSC Server on port 4558...

[GUI] - UDP OSC Server ready and listening

[GUI] - Ruby server pid registered: 410

[GUI] - waiting for Sonic Pi Server to boot...

............................................................

[GUI] - Critical error! Could not boot Sonic Pi Server.

[GUI] - stopping UDP OSC Server...

Server Errors


/Users/oszt/.sonic-pi/log/server-errors.log


libc++abi.dylib: terminating

/Applications/Sonic Pi.app/app/server/ruby/vendor/sys-proctable-1.1.3/lib/darwin/sys/proctable.rb:163: warning: constant ::Fixnum is deprecated

Server Output


/Users/oszt/.sonic-pi/log/server-output.log


Sonic Pi server booting...

Using protocol: udp

Detecting port numbers...

Send port: 4558

Listen port: 4557

- OK

Scsynth port: 4556

- OK

Scsynth send port: 4556

- OK

OSC cues port: 4559

- OK

Erlang port: 4560

- OK

OSC MIDI out port: 4561

- OK

OSC MIDI in port: 4562

- OK

Booting server...

Booting Sonic Pi

----------------

Boot - Booting on OS X

Boot - Starting the SuperCollider server...

Boot - /Applications/Sonic Pi.app/app/server/native/scsynth -u 4556 -a 1024 -m 131072 -D 0 -R 0 -l 1 -i 0 -o 16 -U /Applications/Sonic Pi.app/app/server/native/supercollider/plugins/ -b 4096 -B 127.0.0.1

Scsynth Output


/Users/oszt/.sonic-pi/log/scsynth.log


# Starting SuperCollider 2018-12-18 08:38:10

Found 0 LADSPA plugins

Number of Devices: 1

0 : "Mac mini Lautsprecher"

get kAudioDevicePropertyStreamFormat error on input ?ohw

could not initialize audio.

Process Log


/Users/oszt/.sonic-pi/log/processes.log


No pids store found here: /var/folders/m7/s006plh55p9dzvl0w6lqtd0h0000gn/T/sonic-pi-pids

Exiting

Creating pids store: /var/folders/m7/s006plh55p9dzvl0w6lqtd0h0000gn/T/sonic-pi-pids

Started [410] [-] /Applications/Sonic Pi.app/Contents/MacOS/../../app/server/native/ruby/bin/ruby --enable-frozen-string-literal -E utf-8 /Applications/Sonic Pi.app/Contents/MacOS/../../app/server/ruby/bin/sonic-pi-server.rb -u 4557 4558 4556 4556 4559 4560 4561 4562 [-] /var/folders/m7/s006plh55p9dzvl0w6lqtd0h0000gn/T/sonic-pi-pids/410


#26

hmm

Try something at a more basic level, on one of your Mac Mini
Start a terminal screen

 cd "/Applications/Sonic Pi.app/app/server/native/supercollider"

./scsynth -u 4556 -i 0 -o 16

and see if you can start the supercollider scsynth server. (This assumes that your SP is in Applications)
If you get a similar error, then I think that we need to explore the problem with SuperCollider at a more basic level.
(the parameters are -u 4556 ->the udp connection port to use

-i 0 -> zero input channel connection
-o 16 -> up to 16 output channel connections - not necessarily all used.


#27

First, I deleted an installed SonicPi again because of my messing around with the code.
I added pwd to check if I am in the correct folder.
Here’s what I do in the terminal and the error I get:

Last login: Tue Dec 18 16:35:24 on ttys000

Oberstufenzentrums-Mac-mini:~ oszt$ cd "/Applications/Sonic Pi.app/app/server/native/supercollider"

Oberstufenzentrums-Mac-mini:supercollider oszt$ pwd

/Applications/Sonic Pi.app/app/server/native/supercollider

Oberstufenzentrums-Mac-mini:supercollider oszt$ ./scsynth -u 4556 -i 0 -o 16

Found 0 LADSPA plugins

*** ERROR: open directory failed '/Users/oszt/Library/Application Support/SuperCollider/synthdefs'

Number of Devices: 1

0 : "Mac mini Lautsprecher"

get kAudioDevicePropertyStreamFormat error on input ?ohw

could not initialize audio.

libc++abi.dylib: terminating

Abort trap: 6

Oberstufenzentrums-Mac-mini:supercollider oszt$

#28

OK this error would indicate that it looks like an scsynth problem when trying to launch on a mac Mini which does not have hardware support for an input microphone.
I think this problem should probably be posted on Supercollider github…issues
Something alongs the lines of
When using Sonic Pi on a mac mini scsynth fails to launch with error messages

# Starting SuperCollider 2018-12-18 08:38:10

Found 0 LADSPA plugins

Number of Devices: 1

0 : "Mac mini Lautsprecher"

get kAudioDevicePropertyStreamFormat error on input ?ohw

could not initialize audio.

The same error ocrus when trying to launch scsynth directly with

./scsynth -u 4556 -i 0 -o 16

EDIT (when running on mojave)


#29

Thanks a lot Robin
I give it a chance here on Apple discussions
My “plan B” would be to buy a couple of inexpensive USB microphones to plug in the Mac minis when starting Sonic Pi…


#30

@swissmorgy - I think Robin is also right in that it would be useful to let the SuperCollider folks know. Creating a dummy device on the Mac seems like a bit of a workaround, which may well work, but it’d be great to have the issue fixed in the software that is actually exhibiting the problem…


#31

Ok, thanks Ethan. I did so here. Hope it helps…


#32

Let’s see how that goes!
Hopefully there’s a solution for you that isn’t too delayed, or too expensive :slight_smile:


#33

hay, i am running on a raspberry pi and the original one works but the new one don`t can you help me?


#34

do you have any error message?


#35

no but it is becoming a "simbyodic ixtenson "as i remrember but it ben a wile


#36

correction “symbiotic extension”