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

'Error occurred when fetching containers' message in Fedora 32 and podman 2.0.3 #13

Closed
rmarting opened this issue Jul 29, 2020 · 5 comments

Comments

@rmarting
Copy link

In my previous laptop with Fedora 31 this extension worked successfully and it was very productive for me. However I installed on my new laptop with a fresh installation of Fedora 32 but it seems that something is not working on.

I created some containers using podman 2.0.3 but the extension always show me the same message 'Error occured when fetching containers'

I don't know how to see the logs from the gnome extension, I only did:

❯ sudo journalctl /usr/bin/gnome-shell | grep -i container Jul 24 11:34:12 localhost.localdomain gnome-shell[2530]: clutter_container_add_actor: assertion 'CLUTTER_IS_CONTAINER (container)' failed Jul 24 11:34:12 localhost.localdomain gnome-shell[2530]: clutter_container_add_actor: assertion 'CLUTTER_IS_CONTAINER (container)' failed Jul 24 11:34:12 localhost.localdomain gnome-shell[2530]: clutter_container_add_actor: assertion 'CLUTTER_IS_CONTAINER (container)' failed
but without relevant information.

Is it Fedora 32 supported for this extension? Do I need to do something else?

@rmarting
Copy link
Author

I dig into this issue, but I am not at JavaScript expert, but it seems that some cases are not covered from the containers json format document.

podman ps -a --format json output in my case is:

❯ podman ps -a --format json | jq
[
  {
    "Command": null,
    "Created": 1596034307,
    "CreatedAt": "19 hours ago",
    "Exited": true,
    "ExitedAt": 1596036446,
    "ExitCode": 0,
    "Id": "0c866319f7938b54e0e7fbcd6761d1950f5d2971dfaa5fa669be4322e7f26a51",
    "Image": "docker.io/ibmcom/db2:latest",
    "ImageID": "d6b3abc02d5767c50efa1727ae50b7fafaf1047369d28895787801d773a1dd6e",
    "IsInfra": false,
    "Labels": {
      "org.label-schema.build-date": "20200504",
      "org.label-schema.license": "GPLv2",
      "org.label-schema.name": "CentOS Base Image",
      "org.label-schema.schema-version": "1.0",
      "org.label-schema.vendor": "CentOS",
      "org.opencontainers.image.created": "2020-05-04 00:00:00+01:00",
      "org.opencontainers.image.licenses": "GPL-2.0-only",
      "org.opencontainers.image.title": "CentOS Base Image",
      "org.opencontainers.image.vendor": "CentOS"
    },
    "Mounts": [
      "/database",
      "/hadr"
    ],
    "Names": [
      "mydb2"
    ],
    "Namespaces": {},
    "Pid": 0,
    "Pod": "",
    "PodName": "",
    "Ports": [
      {
        "hostPort": 50000,
        "containerPort": 50000,
        "protocol": "tcp",
        "hostIP": ""
      }
    ],
    "Size": null,
    "StartedAt": 1596034736,
    "State": "exited"
  },
  {
    "Command": null,
    "Created": 1596032658,
    "CreatedAt": "19 hours ago",
    "Exited": true,
    "ExitedAt": 1596032952,
    "ExitCode": 0,
    "Id": "86f20602c3e75580f84b60e3e8c25de83aaf1f729a0708805fdf2145ed6e824e",
    "Image": "docker.io/ibmcom/mq:latest",
    "ImageID": "3545f67ca05751f10e26e92294dc99d71ff02e928b9dc1a13dd2372e3e062327",
    "IsInfra": false,
    "Labels": {
      "architecture": "amd64",
      "authoritative-source-url": "https://www.ibm.com/software/passportadvantage/",
      "base-image": "registry.redhat.io/ubi8/ubi-minimal",
      "base-image-release": "8.2-301.1593113563",
      "build-date": "2020-07-16T13:58:54+0000",
      "com.redhat.build-host": "cpt-1002.osbs.prod.upshift.rdu2.redhat.com",
      "com.redhat.component": "ubi8-minimal-container",
      "com.redhat.license_terms": "https://www.redhat.com/en/about/red-hat-end-user-license-agreements#UBI",
      "description": "Simplify, accelerate and facilitate the reliable exchange of data with a security-rich messaging solution — trusted by the world’s most successful enterprises",
      "distribution-scope": "private",
      "io.k8s.description": "Simplify, accelerate and facilitate the reliable exchange of data with a security-rich messaging solution — trusted by the world’s most successful enterprises",
      "io.k8s.display-name": "IBM MQ Advanced for Developers Server",
      "io.openshift.expose-services": "",
      "io.openshift.tags": "mq messaging",
      "maintainer": "IBM",
      "name": "ibm-mqadvanced-server-dev",
      "release": "r1",
      "run": "docker run -d -e LICENSE=accept ibm-mqadvanced-server-dev:9.2.0.0-r1-amd64",
      "summary": "IBM MQ Advanced for Developers Server",
      "url": "https://www.ibm.com/products/mq/advanced",
      "vcs-ref": "126c5dee6b31ceba47eac0e1a5f8d982b23d6d51",
      "vcs-type": "git",
      "vcs-url": "[email protected]:mq-cloudpak/mq-container",
      "vendor": "IBM",
      "version": "9.2.0.0"
    },
    "Mounts": [],
    "Names": [
      "ibmmq"
    ],
    "Namespaces": {},
    "Pid": 0,
    "Pod": "",
    "PodName": "",
    "Ports": [
      {
        "hostPort": 1414,
        "containerPort": 1414,
        "protocol": "tcp",
        "hostIP": ""
      },
      {
        "hostPort": 9443,
        "containerPort": 9443,
        "protocol": "tcp",
        "hostIP": ""
      }
    ],
    "Size": null,
    "StartedAt": 1596032894,
    "State": "exited"
  }
]

The PopupSubMenuMenuItem class at line 255 tries to manage some attributes missed in the output showed above:

  • Status
  • ID

I am guessing that some error is throwed there and then the menu is not updated successfully. I tried to test locally but it seems that I don't know how to do it successfully.

My environment is:

  • GNOME version: 3.36.4
  • podman: 2.0.3

HTH

@rgolangh
Copy link
Owner

Thanks for reporting.
The latest plugin version was working well but something in gnome changed. I'll upgrade my gnome-shell and let you know.

@rmarting
Copy link
Author

I did some changes and now it is working on my local. I will create a PR with my changes. Basically the json schema is different.

I am testing right now.

@rmarting
Copy link
Author

@rgolangh This is the PR created with my minimal changes.

I am not an JavaScript expert, so maybe some changes could be improved.

HTH

@rgolangh
Copy link
Owner

Solved and merged by #15 and also uploaded and merged to https://extensions.gnome.org/extension/1500/containers/

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

No branches or pull requests

2 participants