Git Product home page Git Product logo

Comments (8)

constellates avatar constellates commented on August 18, 2024

I recreated a minimal dataset with the naming scheme you listed above and did not encounter this issue. The spec requires these properties to be defined in capital case instead of the more JSON-idiomatic camel-case (for example RepetitionTime is valid and repetitionTime isn't). Can you double check if your task-DMNTRACKINGTEST_bold.json follows the capital case convention? And if it does and you're still experiencing this issue are you willing/able to share the contents of task-DMNTRACKINGTEST_bold.json?

from bids-validator.

jpellman avatar jpellman commented on August 18, 2024

The task-DMNTRACKINGTEST_bold.json file does indeed follow capital case. If you want to take a look at it, it's located at http://s3.amazonaws.com/fcp-indi/data/Projects/RocklandSample/RawDataBIDS/Release6/task-DMNTRACKINGTEST_bold.json . In the meantime, I'll try re-running the validator to see if I can replicate the issue.

from bids-validator.

constellates avatar constellates commented on August 18, 2024

Thanks, I'm taking a look now.

from bids-validator.

constellates avatar constellates commented on August 18, 2024

Looks like the issue is caused by using single quotes for strings (the values for "FlipAngle" and "MagneticFieldStrength") in the JSON file. A lot of systems will coerce single quoted strings to double quoted but only doubles are listed in the JSON spec http://www.json.org/ so I'm questioning whether we should allow them or not.

You should have seen this error above the Repetition time and other warnings.

2: Not a valid JSON file. (code: 27)
    /task-DMNTRACKINGTEST_bold.json

Was this JSON file generated automatically by another program or written manually? If it's created by a popular system it might be a case for allowing single quotes.

@chrisfilo do you see any reason for allowing single quoted strings in JSON files?

from bids-validator.

jpellman avatar jpellman commented on August 18, 2024

Thanks @constellates. The JSON was created using Python's json module-
I'll try using double quotes to see if that solves the issue.

2016-01-04 13:02 GMT-05:00 constellates [email protected]:

Looks like the issue is caused by using single quotes for strings (the
values for "FlipAngle" and "MagneticFieldStrength") in the JSON file. A lot
of systems will coerce single quoted strings to double quoted but only
doubles are listed in the JSON spec http://www.json.org/ so I'm
questioning whether we should allow them or not.

You should have seen this error above the Repetition time and other
warnings.

2: Not a valid JSON file. (code: 27)
/task-DMNTRACKINGTEST_bold.json

Was this JSON file generated automatically by another program or written
manually? If it's created by a popular system it might be a case for
allowing single quotes.

@chrisfilo https://github.com/chrisfilo do you see any reason for
allowing single quoted strings in JSON files?


Reply to this email directly or view it on GitHub
https://github.com/INCF/bids-validator/issues/62#issuecomment-168753276.

from bids-validator.

chrisgorgo avatar chrisgorgo commented on August 18, 2024

@constellates let's stick to JSON spec and keep only double quotes.

from bids-validator.

jpellman avatar jpellman commented on August 18, 2024

Double quotes works! Thanks.

2016-01-04 13:38 GMT-05:00 Chris Filo Gorgolewski [email protected]
:

@constellates https://github.com/constellates let's stick to JSON spec
and keep only double quotes.


Reply to this email directly or view it on GitHub
https://github.com/INCF/bids-validator/issues/62#issuecomment-168762945.

from bids-validator.

constellates avatar constellates commented on August 18, 2024

No problem.

from bids-validator.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.