Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

flogo build fails #49

Closed
mellistibco opened this issue May 2, 2017 · 2 comments
Closed

flogo build fails #49

mellistibco opened this issue May 2, 2017 · 2 comments
Assignees
Labels
Milestone

Comments

@mellistibco
Copy link
Collaborator

mellistibco commented May 2, 2017

System: macOS. go version go1.8.1 darwin/amd64

When running flogo build without -sp the following error occurs. The build succeeds when running with -sp.

Matts-MacBook-Pro:deviceinfo mellis$ flogo build
panic: invalid argument

goroutine 1 [running]:
github.com/TIBCOSoftware/flogo-cli/util.RenderTemplate(0x1498400, 0x0, 0x13538f1, 0x4d, 0x12ccfa0, 0xc420179c20)
/Users/mellis/go/src/github.com/TIBCOSoftware/flogo-cli/util/text.go:36 +0x22d
github.com/TIBCOSoftware/flogo-cli/app.createImportsGoFile(0xc420012ec0, 0x37, 0xc4201790a0, 0x4, 0x4)
/Users/mellis/go/src/github.com/TIBCOSoftware/flogo-cli/app/files.go:133 +0x123
github.com/TIBCOSoftware/flogo-cli/app.PrepareApp(0x149ebe0, 0xc420018300, 0xc4200c65e0, 0x0, 0x0)
/Users/mellis/go/src/github.com/TIBCOSoftware/flogo-cli/app/api.go:141 +0x306
github.com/TIBCOSoftware/flogo-cli/app.BuildApp(0x149ebe0, 0xc420018300, 0xc42004de10, 0xc420018300, 0x2)
/Users/mellis/go/src/github.com/TIBCOSoftware/flogo-cli/app/api.go:166 +0x21d
github.com/TIBCOSoftware/flogo-cli/app.(*cmdBuild).Exec(0xc420011110, 0xc42000c220, 0x0, 0x0, 0x0, 0x0)
/Users/mellis/go/src/github.com/TIBCOSoftware/flogo-cli/app/build.go:58 +0xf2
github.com/TIBCOSoftware/flogo-cli/cli.ExecCommand(0xc4200182a0, 0x149be40, 0xc420011110, 0xc42000c220, 0x0, 0x0, 0x0, 0x13444e8)
/Users/mellis/go/src/github.com/TIBCOSoftware/flogo-cli/cli/command.go:114 +0xa9
main.main()
/Users/mellis/go/src/github.com/TIBCOSoftware/flogo-cli/cmd/flogo/main.go:42 +0x122

@wnichols
Copy link

wnichols commented Jun 2, 2017

I would like to comment that almost all my builds fail with this error. I pulled the latest docker image (flogo designer) and created a hello world app and exported it. The exported json pasted below. If I attempt to build it I get a panic; invalid argument. However apps built by hand or with the cli do build. If you would like me to track down the specific difference between these json files is, just ask. I will have some time on the weekend.
I would also like the error in this panic to be a little more informative if possible (though I think the argument in question is nil hence the problem)

The app:

{
"name": "HelloWorld",
"type": "flogo:app",
"version": "0.0.1",
"description": "",
"triggers": [
{
"name": "Timer",
"ref": "github.com/TIBCOSoftware/flogo-contrib/trigger/timer",
"description": "Simple Timer trigger",
"settings": {},
"id": "timer",
"handlers": [
{
"settings": {
"repeating": "true",
"notImmediate": "false",
"startDate": null,
"hours": null,
"minutes": null,
"seconds": "5"
},
"actionId": "hello"
}
]
}
],
"actions": [
{
"name": "Hello",
"data": {
"flow": {
"type": 1,
"attributes": [],
"rootTask": {
"id": 1,
"type": 1,
"tasks": [
{
"id": 2,
"name": "Log Message",
"description": "Simple Log Activity",
"type": 1,
"activityType": "github-com-tibco-software-flogo-contrib-activity-log",
"activityRef": "github.com/TIBCOSoftware/flogo-contrib/activity/log",
"attributes": [
{
"name": "message",
"value": "mary had a little lamb",
"required": false,
"type": "string"
},
{
"name": "flowInfo",
"value": "false",
"required": false,
"type": "boolean"
},
{
"name": "addToFlow",
"value": "false",
"required": false,
"type": "boolean"
}
]
}
],
"links": [],
"attributes": []
},
"errorHandlerTask": {
"id": 3,
"type": 1,
"tasks": [
{
"id": 4,
"name": "Log Message (2)",
"description": "Simple Log Activity",
"type": 1,
"activityType": "tibco-log",
"activityRef": "github.com/TIBCOSoftware/flogo-contrib/activity/log",
"attributes": [
{
"name": "message",
"value": "",
"required": false,
"type": "string"
},
{
"name": "flowInfo",
"value": "false",
"required": false,
"type": "boolean"
},
{
"name": "addToFlow",
"value": "false",
"required": false,
"type": "boolean"
}
],
"inputMappings": [
{
"type": 1,
"value": "{A2.message}",
"mapTo": "message"
}
]
}
],
"links": [],
"attributes": []
}
}
},
"id": "hello",
"ref": "github.com/TIBCOSoftware/flogo-contrib/action/flow"
}
]
}

@smanu
Copy link

smanu commented Aug 3, 2017

Cannot reproduce.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants