PlatformIO Community

Malfunction of the selecting menu of examples in library explorer

Hello,

I have just published my first library on the PlatformIO registry, and I have a problem when I try to display the different examples:

  1. the example selection menu behaves strangely: it keeps scrolling when I try to browse it with the mouse.

  2. the examples appear twice in the menu.

  3. the list of examples does not appear sorted correctly.

Did I configure something wrong somewhere?

Here are the contents of my library.json file:

{
    "name": "ESPboy",
    "version": "1.2.0",
    "description": "This library provides a driver for the ESPboy (Wemos D1 mini - ESP8266) multi gadget handheld created by Roman Sokolov. Experiment with retro game programming, IoT, and STEAM education while having fun. See more on https://www.espboy.com/.",
    "keywords": "espboy, esp8266, retrogaming, handheld, iot, stem-education",
    "license": "GPL-3.0",
    "frameworks": "arduino",
    "platforms": "espressif8266",
    "headers": "ESPboy.h",
    "authors": {
        "name": "m1cr0lab",
        "url": "https://github.com/m1cr0lab",
        "maintainer": true
    },
    "repository":
    {
      "type": "git",
      "url": "https://github.com/m1cr0lab-espboy/ESPboy"
    },
    "dependencies": [
        {
            "owner": "adafruit",
            "name": "Adafruit MCP4725",
            "version": "^2.0.0"
        },
        {
            "owner": "adafruit",
            "name": "Adafruit MCP23017 Arduino Library",
            "version": "^2.1.0"
        },
        {
            "owner": "lovyan03",
            "name": "LovyanGFX",
            "version": "^0.4.4"
        }
    ],
    "export": {
        "include": [
            "Readme.md",
            "LICENSE",
            "examples/*",
            "src/*",
            "library.json",
            "library.properties",
            "keywords.txt"
        ]
    }
}

And the tree of my example files is as follows:

examples
β”œβ”€β”€ 1-bootstrap
β”‚   └── 1-bootstrap.ino
β”œβ”€β”€ 2-splash-screen
β”‚   └── 2-splash-screen.ino
β”œβ”€β”€ 3-buttons
β”‚   └── 3-buttons.ino
β”œβ”€β”€ 4-neopixel
β”‚   └── 4-neopixel.ino
β”œβ”€β”€ 5-game-of-life
β”‚   └── 5-game-of-life.ino
β”œβ”€β”€ 6-fireworks
β”‚   └── 6-fireworks.ino
β”œβ”€β”€ 7-snake
β”‚   └── 7-snake.ino
β”œβ”€β”€ 8-spaceship
β”‚   └── 8-spaceship.ino
└── 9-2048
    └── 9-2048.ino

Is there a way to have the examples sorted correctly (alphabetically?) or (if possible) by defining the order in which you want them to appear in the selection menu?

Thanks in advance for your help.

Steph

1 Like

This is 100% reproducable for me too. Just opening PIO Home β†’ Libraries β†’ ESPBoy β†’ Examples β†’ dropdown menu and moving the mouse cursor down, the thing goes wild.

CC @ivankravets for possible UI bug in https://github.com/platformio/platformio-home/

2 Likes

Indeed, I have encountered the same problem with other libraries.
Thanks for your feedback.

1 Like

Please report to Issues Β· platformio/platformio-home Β· GitHub

It looks like a bug. Thanks.

1 Like

Done.
Thanks @ivankravets.

1 Like

I am pleased to discover that the menu bug seems fixed.

platformio-library-examples-menu

Thank you for that!

Nevertheless, the examples do not sort correctly. Do you plan to fix this? Is there any way to control the order in which they appear?

Well, the bug is back… :confused:
PIO Core: 6.1.4
PIO Home: 3.4.3

Can confirm it is still there !

PIO Core 6.1.5a3
PIO Home 3.4.3

:frowning: