🔥 Lifetime deal! Get Control Surface Studio for Just £67 👉 Click Here To Get It
Time left... mailtimers.com
⚠️ Lifetime licenses are ending soon, get yours before they're gone ⚠️
Your shopping cart is empty.

Json file reimported has error

Submitted by Image_Engine on Thu, 08/20/2020 - 06:02
Image_Engine
Control Surface Studio User

I exported a simple example surface script and wanted to import it as an exercise to check on integrity. When I try to reimport the file, it has an error coming up saying 'Not a json file'.
I checked and it doesn't seem to have any errors that I can see but before moving on, could someone check and see if it simply will import without error?

If I create a simple script and hook it up, there are not publish errors.
If I export eg Akaimix, I don't get the errors back on import?

Cheers

Topic Category: 

17 Responses

Comments

Image_Engine
Control Surface Studio User
#1

EDIT: If I modify the example Akaimix, export and reimport, it does also in fact bring up an error.

JohnC
Forum Admin
#2

It imports fine for me, you're trying to import it as a controller template and not a script right?

Image_Engine
Control Surface Studio User
#3

Absolutely;
1. I export akaimidimix as eg "akai_midimix_3.json": No errors
2. Import the same file in the control surface section and see attached pic

Image_Engine
Control Surface Studio User
#4

Also: I can import the templates directly from remotify but If I download one to my local computer first and then import, I also get the error

JohnC
Forum Admin
#5

Hmmm, akai_midimix_3 imports fine for me too.
Which operating system are you using?

Image_Engine
Control Surface Studio User
#6

W10 64
I notice to when viewing the json that the line feeds dont format the file so it views correctly...when i look at other examples, they follow the normal indentations etc. The css json just feeds across the page.

Image_Engine
Control Surface Studio User
#7

Actually are you on a mac by any chance?

Image_Engine
Control Surface Studio User
#8

and here are some example files

1. (json_cssexport) Direct export viewed in notepad++ editor (which has parser/formatter) but runs without CRLF
2. (json_example) Imported directly from web example; runs correctly
3. (export-CSS) is a file I exported, converted to csv and then exported again to json;

hope that helps

Image_Engine
Control Surface Studio User
#9

I apologise for the long list of replies...if I can find out how to summarise and delete...Ill do it immediately.
OK
Installed on 2 machines
1.- w10 64 B 17134.164 - (Graphics & Web Workstation)
2 - w10 64 B190141.450 (Live Music - Touchscreen Asus Laptop)
and reimport does not work

Installed on another
3 - W10 64 B18362..836 (DAW, minimal services and dependencies ie stripped out)
and it works fine???

Surely there must be some other issue. I downloaded direct into downloads, ran directly from there after allowing execution.
Cheers

PS Ignore the format in Notepad++; my error, json has to be manually actioned to display vs most other scripts which auto format.

JohnC
Forum Admin
#10

The error "not json files" displays when the file type being imported is not equal to "application/json".
I will check your files on a windows machine and let you know if I discover any issues.

JohnC
Forum Admin
#11

Yes I can confirm that the Windows version of CSS is unable to import json files.
I will send you a link to a fixed test version we have just uploaded now.
Please can you try it, if this is fixed we can roll it into an update.

Thanks

John

Image_Engine
Control Surface Studio User
#12

Great...seems to be working fine. Thanks.
Strange that it worked on my DAW...last thing I thought would as its so minimal. On the other machines...json was linked to Max MSP

JohnC
Forum Admin
#13

Awesome, thanks for the quick response.

Image_Engine
Control Surface Studio User
#14

The import does work fine, but now when I publish eg this very simple script, I ge the error in the pic

upload files: 
Image_Engine
Control Surface Studio User
#15

Forgot the source files

Image_Engine
Control Surface Studio User
#16

I rebooted my machine, renamed the file and seems to work ok now...hopefully.

JohnC
Forum Admin
#17

"Publish", Do you mean when you install the script?