Closed davidesner closed 5 years ago
kds-team.ex-hubspot
works fine for me
I changed it back manually. When I go into the dev portal and simply copy paste the same value that is already present in the field, it works.
there doesn't seem to be any changes outside the configuration schema
so that would indicate that the schema is invalid (don't see why though) and i would expect the UI throw some error in the browser console
I am not sure what can I do differently here. Did you manage to reproduce? Can I provide anything else to help? I noticed that when I paste the configSchema manually I get this message, however it allows me to save it and then everything is fine. Also when I check https://jsonlint.com/ the json is fine.
@davidesner paste that configuration here or share it as gist. I mean, the exact configuration which is producing error.
or configure the component to the failing state
@ujovlado everything is in the initial post. I rerun it so its broken again. Now when I'm looking at the result maybe there is something wrong with my bash script? It outputs this "configurationSchema": "{\n \"type\": \"object\",\n...
isn't there extra "
before {
? I load value like this
value=`cat component_config/component_long_description.md`
and then use it in the call. (-from-file option doesn't work for me)
When I try to execute
update-app-property
command onconfigurationSchema
property it gets propagated to Developer portal but the configuration disappears from UICommand:
docker run --rm \ -e KBC_DEVELOPERPORTAL_USERNAME \ -e KBC_DEVELOPERPORTAL_PASSWORD \ quay.io/keboola/developer-portal-cli-v2:latest \ update-app-property ${KBC_DEVELOPERPORTAL_VENDOR} ${KBC_DEVELOPERPORTAL_APP} configurationSchema --value="$value"
Configuration Schema ($value):
{ "type": "object", "title": "extractor configuration", "required": [ "#api_token", "period_from" ], "properties": { "#api_token": { "type": "string", "title": "API token", "format": "password", "propertyOrder": 200 }, "period_from": { "type": "string", "title": "Period from date [including]", "description": "Date in YYYY-MM-DD format or dateparser string i.e. 5 days ago, 1 month ago, yesterday, etc.", "propertyOrder": 300 } } }
result:
Updating application kds-team / kds-team.ex-hubspot: { "configurationSchema": "{\n \"type\": \"object\",\n \"title\": \"extractor configuration\",\n \"required\": [\n \"#api_token\",\n \"period_from\"\n ],\n \"properties\": {\n \"#api_token\": {\n \"type\": \"string\",\n \"title\": \"API token\",\n \"format\": \"password\",\n \"propertyOrder\": 200\n },\n \"period_from\": {\n \"type\": \"string\",\n \"title\": \"Period from date [including]\",\n \"description\": \"Date in YYYY-MM-DD format or dateparser string i.e. 5 days ago, 1 month ago, yesterday, etc.\",\n \"propertyOrder\": 300\n }\n }\n}" }
no it's not. The schema itself looks correct and in another component works fine. The component updates in devportal look correct too. So we either need the entire component configuration which is broken (the one obtained from connection/v2 API endpoint) or the broken component
btw, why are you using cat
and not --value-from-file=
option?
Ok, regarding UI, I can confirm that it shows err for configuration from first comment in issue - but only until you click somewhere outside (on blur). We can tune this a bit probably.
@odinuv --value-from-file does not work for me, I tried everything, specifying full path, relative and it always fails with Cannot read file ..
The entire configuration is here https://connection.keboola.com/admin/projects/1124/extractors/kds-team.ex-hubspot/477116052:
{
"id": "477116052",
"name": "test",
"description": "",
"created": "2019-01-13T00:48:46+0100",
"creatorToken": {
"id": 71614,
"description": "david@keboola.com"
},
"version": 7,
"changeDescription": "Update parameters",
"isDeleted": false,
"configuration": {
"parameters": {
"#api_token": "KBC::ProjectSecure::eJwBLwHQ/mE6Mjp7aTowO3M6ODg6It71AgB35XUtwtNMNc2pmOybmkDYq1CI+18cjOhX/UXGDuQCh/RpXva/QwPQ/d9aygu3+i/Qpihdo5tz9Pu/pFXKPpFU84PriJDEvDB8wkeh8ls/cEZdVoQiO2k6MTtzOjE4NDoiAQIDAHhlXs9v5x5d+klIkL9bzyaH5qzvWHJt2fGW9czDhWdtwAEsNfhBHpjeM5kcXbF3fB+yAAAAfjB8BgkqhkiG9w0BBwagbzBtAgEAMGgGCSqGSIb3DQEHATAeBglghkgBZQMEAS4wEQQMLdX4Qftdr8gRIrZBAgEQgDudmFaxOJMJ+8F3EMpolvuvXbZI+b801COj5h/YEsooyVa8XHEw4KmeNVzULlOEazITV8OC6PRjvlfJ5iI7feVWhHk=",
"period_from": "yesterday",
"debug": true
}
},
"rowsSortOrder": [],
"rows": [],
"state": {},
"currentVersion": {
"created": "2019-01-14T04:31:45+0100",
"creatorToken": {
"id": 71614,
"description": "david@keboola.com"
},
"changeDescription": "Update parameters"
}
}
Ok, I have it.
For the value-from-file
you need to map the volume in docker run command, did you do that?
Problem is that configurationSchema is saved as a string and should be saved as an object. So we'll need another options - json-value
and json-file
.
No workaround now, set manually. Sorry about this.
ok thanks a lot guys! Also thanks for the advice with value-from-file I didn't realise I need to map the volume :/
confirmed - it works now
Amazing! It works perfectly. Thanks a lot guys!
When I try to execute
update-app-property
command onconfigurationSchema
property it gets propagated to Developer portal but the configuration disappears from UICommand:
Configuration Schema ($value):
result:
Dev portal:
UI: