Skip to content
This repository has been archived by the owner on Jun 2, 2021. It is now read-only.

Importing fails if they're spaces in the path #31

Open
dustinWeaver opened this issue Sep 12, 2016 · 0 comments
Open

Importing fails if they're spaces in the path #31

dustinWeaver opened this issue Sep 12, 2016 · 0 comments
Assignees
Labels

Comments

@dustinWeaver
Copy link

If using the importer script from a directory with spaces, the script fails with the following error:

/Users/testuser/.rvm/rubies/ruby-2.3.0/lib/ruby/2.3.0/json/common.rb:156:in `initialize': A JSON text must at least contain two octets! (JSON::ParserError)
    from /Users/testuser/.rvm/rubies/ruby-2.3.0/lib/ruby/2.3.0/json/common.rb:156:in `new'
    from /Users/testuser/.rvm/rubies/ruby-2.3.0/lib/ruby/2.3.0/json/common.rb:156:in `parse'
    from /Users/testuser/.rvm/gems/ruby-2.3.0/gems/contentful-importer-0.2.2/lib/contentful/importer/json_schema_validator.rb:28:in `block in validate_entry'
    from /Users/testuser/.rvm/gems/ruby-2.3.0/gems/contentful-importer-0.2.2/lib/contentful/importer/json_schema_validator.rb:27:in `glob'
    from /Users/testuser/.rvm/gems/ruby-2.3.0/gems/contentful-importer-0.2.2/lib/contentful/importer/json_schema_validator.rb:27:in `validate_entry'
    from /Users/testuser/.rvm/gems/ruby-2.3.0/gems/contentful-importer-0.2.2/lib/contentful/importer/json_schema_validator.rb:23:in `validate_schema'
    from /Users/testuser/.rvm/gems/ruby-2.3.0/gems/contentful-importer-0.2.2/lib/contentful/importer/json_schema_validator.rb:16:in `block in validate_schemas'
    from /Users/testuser/.rvm/gems/ruby-2.3.0/gems/contentful-importer-0.2.2/lib/contentful/importer/json_schema_validator.rb:15:in `glob'
    from /Users/testuser/.rvm/gems/ruby-2.3.0/gems/contentful-importer-0.2.2/lib/contentful/importer/json_schema_validator.rb:15:in `validate_schemas'
    from /Users/testuser/.rvm/gems/ruby-2.3.0/gems/contentful-importer-0.2.2/lib/contentful/importer/command.rb:84:in `run'
    from /Users/testuser/.rvm/gems/ruby-2.3.0/gems/contentful-importer-0.2.2/lib/contentful/importer/test_credentials.rb:12:in `run'
    from /Users/testuser/.rvm/gems/ruby-2.3.0/gems/claide-0.8.2/lib/claide/command.rb:312:in `run'
    from /Users/testuser/.rvm/gems/ruby-2.3.0/gems/contentful-importer-0.2.2/bin/contentful-importer:12:in `<top (required)>'
    from /Users/testuser/.rvm/gems/ruby-2.3.0/bin/contentful-importer:23:in `load'
    from /Users/testuser/.rvm/gems/ruby-2.3.0/bin/contentful-importer:23:in `<main>'
    from /Users/testuser/.rvm/gems/ruby-2.3.0/bin/ruby_executable_hooks:15:in `eval'
    from /Users/testuser/.rvm/gems/ruby-2.3.0/bin/ruby_executable_hooks:15:in `<main>'

This same issue would prevent the script from working on Windows machines.

@dlitvakb dlitvakb added the bug label Sep 12, 2016
@dlitvakb dlitvakb self-assigned this Sep 12, 2016
@dlitvakb dlitvakb added wontfix and removed wontfix labels Nov 4, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Development

No branches or pull requests

2 participants