ValueError: Invalid control character at: line 1 column 35 (char 34)

Hi
I am installing dashbaord in Ubuntu ,
i am in last steps
bash /opt/tyk-dashboard/install/bootstrap.sh apigateway

but it trows error , i added teh debug
the licence has been installed in “/opt/tyk-dashboard/tyk_analytics.conf”

Any idea why its causing this issues ?

[email protected]:~# bash /opt/tyk-dashboard/install/bootstrap.sh apigateway

  • main apigateway

  • [[ 1 -lt 1 ]]
    ++ which curl

  • ‘[’ -z /usr/bin/curl ‘]’
    ++ which python

  • ‘[’ -z /usr/bin/python ‘]’
    ++ check_host apigateway
    ++ [[ apigateway == : ]]
    ++ echo apigateway

  • LOCALIP=apigateway
    ++ head -c 10
    ++ env LC_CTYPE=C tr -dc a-z0-9

  • RANDOM_USER=qw0hfda4az

  • PASS=t2e0s1T7

  • generate_credentials apigateway qw0hfda4az t2e0s1T7

  • error=0

  • [[ -z apigateway ]]

  • echo ‘’

  • error=0

  • [[ 0 != 0 ]]

  • echo ‘Creating Organisation’
    Creating Organisation
    ++ create_organisation apigateway
    +++ curl --silent --header ‘admin-auth: 12345’ --header Content-Type:application/json --data ‘{“owner_name”: “Default Org.”,“owner_slug”: “default”, “cname_enabled”: true, “cname”: “”}’ http://apigateway:3000/admin/organisations
    ++ ORGDATA=’{“Status”:“OK”,“Message”:“Org created”,“Meta”:“5bedba44fb0cde129d4338e4”}’
    ++ if_present_echo ‘{“Status”:“OK”,“Message”:“Org created”,“Meta”:“5bedba44fb0cde129d4338e4”}’ 3
    ++ [[ -z {“Status”:“OK”,“Message”:“Org created”,“Meta”:“5bedba44fb0cde129d4338e4”} ]]
    ++ echo ‘{“Status”:“OK”,“Message”:“Org created”,“Meta”:“5bedba44fb0cde129d4338e4”}’

  • ORGDATA=’{“Status”:“OK”,“Message”:“Org created”,“Meta”:“5bedba44fb0cde129d4338e4”}’

  • error=0

  • [[ 0 != 0 ]]

  • echo ‘ORG DATA: {“Status”:“OK”,“Message”:“Org created”,“Meta”:“5bedba44fb0cde129d4338e4”}’
    ORG DATA: {“Status”:“OK”,“Message”:“Org created”,“Meta”:“5bedba44fb0cde129d4338e4”}
    ++ org_id ‘{“Status”:“OK”,“Message”:“Org created”,“Meta”:“5bedba44fb0cde129d4338e4”}’
    +++ python -c ‘import json,sys;obj=json.load(sys.stdin);print obj[“Meta”]’
    +++ echo ‘{“Status”:“OK”,“Message”:"Org’ ‘created",“Meta”:“5bedba44fb0cde129d4338e4”}’
    ++ ORGID=5bedba44fb0cde129d4338e4
    ++ if_present_echo 5bedba44fb0cde129d4338e4 4
    ++ [[ -z 5bedba44fb0cde129d4338e4 ]]
    ++ echo 5bedba44fb0cde129d4338e4

  • ORGID=5bedba44fb0cde129d4338e4

  • error=0

  • [[ 0 != 0 ]]

  • echo ‘ORG ID: 5bedba44fb0cde129d4338e4’
    ORG ID: 5bedba44fb0cde129d4338e4

  • echo ‘’

  • echo ‘Adding new user’
    Adding new user
    ++ create_user apigateway qw0hfda4az t2e0s1T7 5bedba44fb0cde129d4338e4
    +++ user_data apigateway qw0hfda4az t2e0s1T7 5bedba44fb0cde129d4338e4
    ++++ curl --silent --header ‘admin-auth: 12345’ --header Content-Type:application/json --data ‘{“first_name”: “Joan”,“last_name”: “Smith”,“email_address”: "[email protected]",“password”:“t2e0s1T7”, “active”: true,“org_id”: “5bedba44fb0cde129d4338e4”}’ http://apigateway:3000/admin/users
    +++ user_curl=’{“Status”:“Error”,“Message”:“Could not create API session for new user”,“Meta”:null}’
    +++ if_present_echo ‘{“Status”:“Error”,“Message”:"Could’ not create API session for new ‘user",“Meta”:null}’ 3
    +++ [[ -z {“Status”:“Error”,“Message”:"Could ]]
    +++ echo ‘{“Status”:“Error”,“Message”:"Could’
    ++ USER_DATA=’{“Status”:“Error”,“Message”:"Could’
    +++ python -c ‘import json,sys;obj=json.load(sys.stdin);print obj[“Message”]’
    +++ echo ‘{“Status”:“Error”,“Message”:"Could’
    Traceback (most recent call last):
    File “”, line 1, in
    File “/usr/lib/python2.7/json/init.py”, line 291, in load
    **kw)
    File “/usr/lib/python2.7/json/init.py”, line 339, in loads
    return _default_decoder.decode(s)
    File “/usr/lib/python2.7/json/decoder.py”, line 364, in decode
    obj, end = self.raw_decode(s, idx=_w(s, 0).end())
    File “/usr/lib/python2.7/json/decoder.py”, line 380, in raw_decode
    obj, end = self.scan_once(s, idx)
    ValueError: Invalid control character at: line 1 column 35 (char 34)
    ++ AUTH_CODE=
    ++ if_present_echo ‘’ 4
    ++ [[ -z ‘’ ]]
    ++ return 4

  • USER_AUTH_CODE=

  • error=4

  • [[ 4 != 0 ]]

  • return 4

  • exit_reason 4

  • case “$1” in

  • echo ‘ERROR: Unable to parse JSON’
    ERROR: Unable to parse JSON

  • exit 4

Hi
Can any one please help me with this.

this script needs to be more descriptive i think instead of giving ugly error.

same install guide, it works some times some time it does not work

Can one please let me know what should be troubleshooting steps for this ?

it always same place

Would really appreciate

this time i try it worked.