This repository was archived by the owner on Sep 9, 2020. It is now read-only.
This repository was archived by the owner on Sep 9, 2020. It is now read-only.
ks diff local:prod local:dev: RUNTIME ERROR: max stack frames exceeded #445 DescriptionIs this a BUG REPORT or FEATURE REQUEST?: BUG REPORT
/kind bug
What happened:ks diff
panics when I have an annotation set which uses a param.
Depending if the following line is present in my component.jsonnet, ks diff will panic:
"service.beta.kubernetes.io/aws-load-balancer-ssl-cert": params.sslCert,
See below:
$ ks diff local:prod local:dev
ERROR unable to read /Users/jsuen/ws/ksonnet-examples/ks-stackframe-bug/environments/prod/main.jsonnet: RUNTIME ERROR: max stack frames exceeded.
<builtin> builtin function <operator+>
<std>:1153:24-25 thunk from <function <anonymous>>
<builtin> builtin function <objectFieldsEx>
/Users/jsuen/ws/ksonnet-examples/ks-stackframe-bug/environments/prod/params.libsonnet:12:54-92 object <anonymous>
<builtin> builtin function <flatMap>
<builtin> builtin function <$objectFlatMerge>
<builtin> builtin function <operator+>
<std>:1153:24-25 thunk from <function <anonymous>>
<builtin> builtin function <objectFieldsEx>
/Users/jsuen/ws/ksonnet-examples/ks-stackframe-bug/environments/prod/params.libsonnet:12:54-92 object <anonymous>
...
<builtin> builtin function <$objectFlatMerge>
<builtin> builtin function <operator+>
<std>:1153:24-25 thunk from <function <anonymous>>
<builtin> builtin function <objectFieldsEx>
/Users/jsuen/ws/ksonnet-examples/ks-stackframe-bug/environments/prod/params.libsonnet:12:54-92 object <anonymous>
<builtin> builtin function <flatMap>
<builtin> builtin function <$objectFlatMerge>
/Users/jsuen/ws/ksonnet-examples/ks-stackframe-bug/components/my-service.jsonnet:1:16-57 thunk <params> from <$>
/Users/jsuen/ws/ksonnet-examples/ks-stackframe-bug/components/my-service.jsonnet:10:64-70 object <anonymous>
During manifestation
$ cat components/my-service.jsonnet
local params = std.extVar("__ksonnet/params").components["my-service"];
{
"kind": "Service",
"apiVersion": "v1",
"metadata": {
"name": "my-service",
"annotations": {
"service.beta.kubernetes.io/aws-load-balancer-ssl-ports": "443",
"service.beta.kubernetes.io/aws-load-balancer-backend-protocol": "https",
"service.beta.kubernetes.io/aws-load-balancer-ssl-cert": params.sslCert,
}
},
"spec": {
"selector": {
"app": "my-service"
},
"ports": [
{
"name": "https",
"port": 443,
"protocol": "TCP"
}
],
"type": "LoadBalancer",
}
$ cat components/params.libsonnet
{
global: {
// User-defined global parameters; accessible to all component and environments, Ex:
// replicas: 4,
},
components: {
// NOTE: the values here are the default values, used only in the e2e/qa environments.
// The prod environment overrides these values in environments/prod/params.libsonnet
"my-service": {
sslCert: "arn:aws:acm:us-west-2:111111111111:certificate/11111111-11111-1111-1111-1111111111",
},
},
}
What you expected to happen:
I should be able to diff two local environments
How to reproduce it (as minimally and precisely as possible):
I created a repo with a ksonnet app which can reproduce this here:
https://github.com/jessesuen/ksonnet-examples/tree/master/ks-stackframe-bug
Environment:
ks version
):$ ks version
ksonnet version: 0.10.0-alpha.1
jsonnet version: v0.10.0
client-go version: 1.8
kubectl version
):RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4