Skip to content

[Bug] Battery Lua plugin returns empty outputย #45

@insign

Description

@insign

Description

The battery.2s.lua plugin returns empty output when run, while battery.2s.sh works correctly.

Steps to Reproduce

  1. Import battery plugin in Lua variant
  2. Run the plugin
  3. Output is empty/blank

Expected Behavior

Should output battery level with emoji and iconName attribute, e.g.:

๐Ÿ”‹ 100% | iconName=battery-level-100-charged-symbolic color=#8be9fd
---
State: charging
Level: 100%
---
Refresh | refresh=true

Actual Behavior

Empty or blank output.

Code Reference

  • Plugin: plugins/battery/battery.2s.lua
  • Uses crossbarBridge.batterySync() API

Possible Causes

  • crossbarBridge global may not be available in Lua runner
  • batterySync() may return nil instead of table on some systems
  • Error handling may be silently failing

Environment

  • OS: Linux
  • Lua Runner: embedded lua5x

Related Commits

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions