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

Delete all orphaned entities not working #827

Open
Jezza34000 opened this issue Aug 26, 2024 · 7 comments
Open

Delete all orphaned entities not working #827

Jezza34000 opened this issue Aug 26, 2024 · 7 comments

Comments

@Jezza34000
Copy link

Jezza34000 commented Aug 26, 2024

What version of Spook are you using?

v3.1.0

What version of Home Assistant are you using?

2024.8.3

The problem

Hi,
Action > "Home Assistant Core Integration: List all orphaned database entities 👻"
Give me 185 entites :

`
count: 185
entities:

  • button.withee_reinitialiser_le_filtre
  • sensor.withee_surface_du_nettoyage_courant
  • sensor.tasmota_last_restart_time
  • time.withee_fin_npd
  • switch.withee_child_lock
  • sensor.omg_esp32_ble_sys_ip
  • sensor.withee_temps_de_sechage_de_la_serpilliere_restant
  • cover.esprts_test_cover
  • binary_sensor.withee_penurie_d_eau
  • switch.withee_ne_pas_deranger

`

When i use :
"Home Assistant Core Integration: Delete all orphaned entities 👻" action is OK
I restart many time, but entities are still here

Anything in the logs? Paste it here!

No response

@Jezza34000 Jezza34000 changed the title Delete all orphaned entities not wroking Delete all orphaned entities not working Aug 26, 2024
@joshrp5
Copy link

joshrp5 commented Aug 27, 2024

I am experiencing the same thing. I just installed spooky for the first time for this reason specifically. Sad to see it isn't working.

@travisp
Copy link

travisp commented Sep 14, 2024

Agreed, it has no effect here.

@freakyjoe8
Copy link

yes, same for me. Trying to delete 770 orphaned entities but nothing happens.

@CaptInsano
Copy link

I came here with the same issue:
The action homeassistant.delete_all_orphaned_entities does not delete the entities listed from action homeassistant.list_orphaned_database_entities.

However the script example here: https://spook.boo/entities (find it under: "Script to remove entities from database") works perfectly for me.

@travisp
Copy link

travisp commented Oct 8, 2024

I came here with the same issue:

The action homeassistant.delete_all_orphaned_entities does not delete the entities listed from action homeassistant.list_orphaned_database_entities.

However the script example here: https://spook.boo/entities (find it under: "Script to remove entities from database") works perfectly for me.

I tried the script. I first had to reduce the number of entities it was trying to use because the template size was too large. At 1000 entities at a time I received no error but nothing happened. At 100 entities it worked... until I'd gone through about 700 entities and then it too stopped working.

That makes me think that whatever is making it fail silently (maybe a problem removing a particular entity) is also causing the delete orphaned entities action to fail silently.

Edit: I take that back as I was eventually able to remove all the orphaned entities. But it took many multiple passes over the same entities.

@dalto12593
Copy link

I'm having the same exact issues as above; tried running the script but it doesn't seem to be doing anything.

Home Assistant Versions

  • Core
  • 2024.11.1
  • Supervisor
  • 2024.11.2
  • Operating System
  • 13.2
  • Frontend
  • 20241106.2

@nicknol
Copy link

nicknol commented Dec 6, 2024

the script contains
action: recorder.purge_entities
which is a very time consuming action. Allow it to run for several minutes, in big data bases even hours.

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

8 participants
@travisp @CaptInsano @nicknol @freakyjoe8 @Jezza34000 @joshrp5 @dalto12593 and others