Zero-to-jupyterhub-k8s: warning: cannot overwrite table with non table for extraConfig (map[])

Created on 18 Apr 2018  路  4Comments  路  Source: jupyterhub/zero-to-jupyterhub-k8s

Every time I helm upgrade {deployment} {helm_chart} -f config.yml I get this error
warning: cannot overwrite table with non table for extraConfig (map[])

I am not sure what it means.

Contents of config.yaml

# Rhodium-Hub configuration values
# --------------------


# Create and use roles and service accounts on an RBAC enabled cluster.
rbac:
  enabled: true


# Dependency configuration values
# -------------------------------
# To configure dependencies you must create a key with the name of the dependency
# and then configure as per the dependent chart's values.yaml. Don't forget to indent!

jupyterhub:
  singleuser:
    image:
      name: rhodium/notebook
      tag: 2018-04-17
    storage:
      capacity: 10Gi
    dynamic:
      storageClass: jupyterhub-user-ssd
    serviceAccountName: daskkubernetes
    cmd: ['start-singleuser.sh']
    defaultUrl: "/lab"
    storage:
      extraVolumes:
        - name: fuse
          hostPath:
            path: /dev/fuse
      extraVolumeMounts:
        - name: fuse
          mountPath: /dev/fuse
    cloudMetadata:
      enabled: true

  hub:
    extraConfig: |
      from kubernetes import client
      def modify_pod_hook(spawner, pod):
          pod.spec.containers[0].security_context = client.V1SecurityContext(
              privileged=True,
              capabilities=client.V1Capabilities(
                  add=['SYS_ADMIN']
              )
          )
          return pod
      c.KubeSpawner.modify_pod_hook = modify_pod_hook
      c.Authenticator.whitelist = {REDACTED}

    image:
      name: jupyterhub/k8s-hub
      tag: v0.6     

  cull:
    enabled: true
    users: false
    timeout: 12

Most helpful comment

For posterity I took the following steps to identify this:

  1. Googled the error message "cannot overwrite table with non table for extraConfig"
  2. Noticed that all of the results were JHub specific
  3. Thought that probably extraConfig was JHub specific, so removed it and googled again
  4. Found that yes, here is some code in helm that corroborates the error message, we're trying to write a table (dict in python terms) thing onto something that is not a table/dict
  5. Looked at what my installation was doing with the extraConfig variable by looking at my config files, saw that it was a string
  6. Looked at what JHub expected with helm inspect jupyterhub/jupyterhub --version my-version-of-jhub, saw that it was a dict

All 4 comments

We are getting this warning constantly in pangeo jupyterhub deployments, and we are worried it is the source of deeper problems with our config. Any update?

It looks like the extraConfig entry in the helm chart changed recently:

mrocklin@carbon:~/workspace/pangeo/gce$ helm inspect jupyterhub/jupyterhub | grep extraConfig:
  extraConfig: ''
mrocklin@carbon:~/workspace/pangeo/gce$ helm inspect jupyterhub/jupyterhub --version v0.7-9c93c00 | grep extraConfig:
  extraConfig: {}

For posterity I took the following steps to identify this:

  1. Googled the error message "cannot overwrite table with non table for extraConfig"
  2. Noticed that all of the results were JHub specific
  3. Thought that probably extraConfig was JHub specific, so removed it and googled again
  4. Found that yes, here is some code in helm that corroborates the error message, we're trying to write a table (dict in python terms) thing onto something that is not a table/dict
  5. Looked at what my installation was doing with the extraConfig variable by looking at my config files, saw that it was a string
  6. Looked at what JHub expected with helm inspect jupyterhub/jupyterhub --version my-version-of-jhub, saw that it was a dict
Was this page helpful?
0 / 5 - 0 ratings