Why?Zax wrote: Tue Mar 22, 2022 3:18 pmI started with that, but it soon appears that it was not a good way.
JSONtoArray() without indexes?
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller
-
FourthWorld
- VIP Livecode Opensource Backer

- Posts: 10103
- Joined: Sat Apr 08, 2006 7:05 am
- Contact:
Re: JSONtoArray() without indexes?
Richard Gaskin
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn
Re: JSONtoArray() without indexes?
Well, I think it's better to have all data result in one formatted line instead of an unknown number of lines, and separated from possible error strings returned by the Python script.FourthWorld wrote: Tue Mar 22, 2022 4:15 pmWhy?Zax wrote: Tue Mar 22, 2022 3:18 pmI started with that, but it soon appears that it was not a good way.
-
FourthWorld
- VIP Livecode Opensource Backer

- Posts: 10103
- Joined: Sat Apr 08, 2006 7:05 am
- Contact:
Re: JSONtoArray() without indexes?
It's very rare that data coming over the internet is ensured to be limited to a single line. If that's the only concern I'm curious about what makes the Python delivery script brittle enough for that to be an issue.Zax wrote: Tue Mar 22, 2022 5:02 pmWell, I think it's better to have all data result in one formatted line instead of an unknown number of lines, and separated from possible error strings returned by the Python script.FourthWorld wrote: Tue Mar 22, 2022 4:15 pmWhy?Zax wrote: Tue Mar 22, 2022 3:18 pm
I started with that, but it soon appears that it was not a good way.
Richard Gaskin
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn
Re: JSONtoArray() without indexes?
No doubt my script is not perfect (I'm new to Python). Also, it can return debugging informations with an unknown number of lines, so it seemed to me that the cleanest way to return valid data was in JSON format.
Re: JSONtoArray() without indexes?
Just tried PhotoJSON: it works fine and more flexible than JSONToArraystam wrote: Mon Mar 21, 2022 8:33 am FerrusLogic have shared their own parser PhotonJSON as free/opensource.
-
FourthWorld
- VIP Livecode Opensource Backer

- Posts: 10103
- Joined: Sat Apr 08, 2006 7:05 am
- Contact:
Re: JSONtoArray() without indexes?
Excellent. Good find. Glad you have a solution in hand.Zax wrote: Wed Mar 23, 2022 12:02 pmJust tried PhotoJSON: it works fine and more flexible than JSONToArraystam wrote: Mon Mar 21, 2022 8:33 am FerrusLogic have shared their own parser PhotonJSON as free/opensource.![]()
Richard Gaskin
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn
Re: JSONtoArray() without indexes?
Glad to hear it’s useful - don’t forget to give them a star on GitHub in way of thanks! I’ll definitely check it out when I have need of JSON…Zax wrote: Wed Mar 23, 2022 12:02 pm Just tried PhotoJSON: it works fine and more flexible than JSONToArray![]()