Skip to content

py3: remove unused storage_items()#2335

Merged
ultrabug merged 1 commit into
ultrabug:masterfrom
lasers:storage_items
Jul 16, 2026
Merged

py3: remove unused storage_items()#2335
ultrabug merged 1 commit into
ultrabug:masterfrom
lasers:storage_items

Conversation

@lasers

@lasers lasers commented Jul 12, 2026

Copy link
Copy Markdown
Contributor

Codex found inconsistency bug. We should use append, not add with items = [].

This should raise an exception, but it didn't.... Why? It's because this code is not being used anywhere... so just remove it. Also, Idk why modules would want access to other module storage. I mean, I could see some benefits in doing that, but if it's not needed, go ahead and remove it instead of fixing it.

Consistency fix for dead code.

diff --git a/py3status/py3.py b/py3status/py3.py
--- a/py3status/py3.py
+++ b/py3status/py3.py
@@ -1130,13 +1130,13 @@ class Py3:
         - '_mtime': storage last modification timestamp
         """
         if not self._module:
-            return {}.items()
+            return []
         self._storage_init()
         items = []
         module_name = self._module.module_full_name
         for key in self._storage.storage_keys(module_name):
             value = self._storage.storage_get(module_name, key)
-            items.add((key, value))
+            items.append((key, value))
         return items
 
     def play_sound(self, sound_file):
     ```

@ultrabug

Copy link
Copy Markdown
Owner

will need a rebase plz

@ultrabug
ultrabug merged commit 3ff858b into ultrabug:master Jul 16, 2026
7 checks passed
@lasers
lasers deleted the storage_items branch July 16, 2026 21:40
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

Successfully merging this pull request may close these issues.

2 participants