Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Primitive '_FileLength' failed #1

Open
ndr-brt opened this issue Feb 25, 2021 · 1 comment
Open

Primitive '_FileLength' failed #1

ndr-brt opened this issue Feb 25, 2021 · 1 comment

Comments

@ndr-brt
Copy link

ndr-brt commented Feb 25, 2021

Tried to start threnoscope but I get an error I couldn't manage.

OS: Ubuntu 20.10
Supercollider 3.11.1

That's the code I evaluated (line by line)

Quarks.install('<threnoscope path>');

s.boot;

ThrenoScope.new(2);

but a white window appears and a stacktrace on the console:

[ appPath, nil ]
_______________
[ pathtoscalafiles, /home/andrea/.local/share/SuperCollider/threnoscope/scl/ ]
[ pathtouserscalafiles, /home/andrea/.local/share/SuperCollider/threnoscope/scl_user/ ]
[ HUBAPPPATH, nil ]
ERROR: Primitive '_FileLength' failed.
Failed.
RECEIVER:
Instance of File {    (0x55be6b967b38, gc=8C, fmt=00, flg=00, set=02)
  instance variables [1]
    fileptr : nil
}
CALL STACK:
	MethodError:reportError
		arg this = <instance of PrimitiveFailedError>
	Nil:handleError
		arg this = nil
		arg error = <instance of PrimitiveFailedError>
	Thread:handleError
		arg this = <instance of Thread>
		arg error = <instance of PrimitiveFailedError>
	Object:throw
		arg this = <instance of PrimitiveFailedError>
	Object:primitiveFailed
		arg this = <instance of File>
	File:readAllString
		arg this = <instance of File>
		var string = nil
	DroneSynths:initSampleDict
		arg this = <instance of DroneSynths>
		var file = <instance of File>
		var string = nil
	DroneSynths:initDroneSynths
		arg this = <instance of DroneSynths>
		arg loadsamples = false
		arg arghub = <instance of DroneHub>
	ThrenoScope:initThrenoScope
		arg this = <instance of ThrenoScope>
		arg channels = 2
		arg mode = 'perform'
		arg key = "A"
		arg appPath = nil
		var fundamental = 55.0
		var speakers = nil
		var interpreter = nil
		var machines = nil
		var states = nil
		var tuning = 'et12'
		var scale = 'minor'
		var threnoscopeColor = <instance of Color>
		var border = false
		var fullScreen = true
		var bgcolor = <instance of Color>
	Interpreter:interpretPrintCmdLine
		arg this = <instance of Interpreter>
		var res = nil
		var func = <instance of Function>
		var code = "ThrenoScope.new(2);"
		var doc = nil
		var ideClass = <instance of Meta_ScIDE>
	Process:interpretPrintCmdLine
		arg this = <instance of Main>
^^ The preceding error dump is for ERROR: Primitive '_FileLength' failed.
Failed.
RECEIVER: a File

tried also to set the appPath parameter on the constructor, passing the threnoscope path, but the error is the same.

@ndr-brt
Copy link
Author

ndr-brt commented Mar 1, 2021

Ok, did a little debug, the problem is here:

string = file.readAllString;

Is this "sampleDict" mandatory? I created an empty _samples.scd file where it's expected to be and everything started correctly.

PS: great work!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant