grafana / plugin-tools

Create Grafana plugins with ease.
https://grafana.com/developers/plugin-tools/
Apache License 2.0
58 stars 32 forks source link

Bug: Check plugin.json fails #1328

Closed 6nv closed 1 week ago

6nv commented 1 week ago

Which package(s) does this bug affect?

Package versions

5.9.2

What happened?

Source: (in ci.yml)

      - name: Check plugin.json
        run: |
          docker run --pull=always \
            -v $PWD/$:/archive.zip \
            grafana/plugin-validator-cli -analyzer=metadatavalid /archive.zip

Result:

Run docker run --pull=always \
latest: Pulling from grafana/plugin-validator-cli
94c7366c1c30: Already exists
c[8](https://github.com/nicfv/Psychart/actions/runs/11847049186/job/33015947974#step:17:9)3866a0fb45: Pulling fs layer
ad2522a15a74: Pulling fs layer
7d1d6e201bb5: Pulling fs layer
ca3115fec8a3: Pulling fs layer
eb1[9](https://github.com/nicfv/Psychart/actions/runs/11847049186/job/33015947974#step:17:10)b5c1f6d3: Pulling fs layer
fc9068657f66: Pulling fs layer
0b60df86a037: Pulling fs layer
be7c0bac85e9: Pulling fs layer
0b60df86a037: Waiting
fc9068657f66: Waiting
be7c0bac85e9: Waiting
ca3[11](https://github.com/nicfv/Psychart/actions/runs/11847049186/job/33015947974#step:17:12)5fec8a3: Waiting
eb19b5c1f6d3: Waiting
ad2522a15a74: Verifying Checksum
ad2522a15a74: Download complete
ca3115fec8a3: Verifying Checksum
ca3115fec8a3: Download complete
eb19b5c1f6d3: Verifying Checksum
eb19b5c1f6d3: Download complete
fc9068657f66: Verifying Checksum
fc9068657f66: Download complete
0b60df86a037: Verifying Checksum
0b60df86a037: Download complete
be7c0bac85e9: Download complete
c83866a0fb45: Download complete
7d1d6e201bb5: Verifying Checksum
7d1d6e201bb5: Download complete
c83866a0fb45: Pull complete
ad2522a15a74: Pull complete
7d1d6e201bb5: Pull complete
ca3115fec8a3: Pull complete
eb19b5c1f6d3: Pull complete
fc9068657f66: Pull complete
0b60df86a037: Pull complete
be7c0bac85e9: Pull complete
Digest: sha256:efe0fdc2fad2223abc8526f56d49[14](https://github.com/nicfv/Psychart/actions/runs/11847049186/job/33015947974#step:17:15)48f9e70e3493b2d7a20bc0140d0317ebac
Status: Downloaded newer image for grafana/plugin-validator-cli:latest
couldn't fetch plugin archive: read /archive.zip: is a directory
Error: Process completed with exit code 1.

What you expected to happen

Expected to pass...

How to reproduce it (as minimally and precisely as possible)

  1. Create a new plugin
  2. Run npx @grafana/create-plugin@latest
  3. Push to empty Git repository
  4. Observe ci workflow

Environment

System:
    OS: macOS 15.1
    CPU: (8) arm64 Apple M2
    Memory: 562.53 MB / 24.00 GB
    Shell: 3.2.57 - /bin/sh
  Binaries:
    Node: 20.11.1 - ~/.nvm/versions/node/v20.11.1/bin/node
    npm: 10.9.0 - ~/.nvm/versions/node/v20.11.1/bin/npm
  Browsers:
    Brave Browser: 131.1.73.89
    Chrome: 105.0.5195.102
    Safari: 18.1
  npmPackages:
    @grafana/data: ^11.3.0 => 11.3.0 
    @grafana/eslint-config: ^7.0.0 => 7.0.0 
    @grafana/plugin-e2e: ^1.12.0 => 1.12.1 
    @grafana/runtime: ^11.3.0 => 11.3.0 
    @grafana/schema: ^11.3.0 => 11.3.0 
    @grafana/tsconfig: ^2.0.0 => 2.0.0 
    @grafana/ui: ^11.3.0 => 11.3.0

Additional context

No response

oshirohugo commented 1 week ago

Solved by https://github.com/grafana/plugin-tools/pull/1330