Data already exists (SOLVED)

To test things I have added an Entity TEST with the Device name TEST
After the test I have deleted this Entity.
Now I want to do another test and try to add a new Entity TEST, but when I want to fill in the Device name TEST, I get the error message: Data already exists.
Why is this data not removed during the deletion of the Entity?
How can I remove old and not anymore in use data?

SOLVED:
I have deleted the TEST IR Codes with the API way on remote/doc/core-rest/.

Are you referring to IR remote entities? If you delete an IR entity the web configurator doesn’t delete the actual code set that is linked to that entity. You either have to use a different name or the API to delete the code set. This is explained in this issue: [bug] User-created IR-Sets do not appear in the dropdown when creating a new remote, but block creating a new ir-set with the same name · Issue #4 · unfoldedcircle/feature-and-bug-tracker · GitHub

Selecting an old data set in the Web Configurator is possible, so you can alter it, but still you cannot delete it in the Web Configurator.

I have tried als the curl command, but I get the error: Couldn’t connect to server.
I have tried as $IP ‘remote3-XXXXXa.local’ or ‘192.168.1.XX’, the IP address of Remote3-XXXXXa, both with the right PIN-number.

What I am doing wrong?

I copied these instructions from somewhere a while ago:

“As far as I understand there is a difference between the name of the IR entity and the name for the associated IR code set. When you delete an IR entity the associated IR code set is not deleted with it for some reason. I.e. you can create an IR entity with the same name as a previously deleted one but the associated IR code set must be named differently, otherwise you will see the error message you mentioned.

There is a way to delete IR code sets via the API:

1. Go to IP of your remote/doc/core-rest/

2. Click on authorize in the lower right hand corner

3. Log in with web-configurator as username and the PIN of your remote

4. Scroll down to the infrared section

5. Click on GET /ir/codes/custom, then Try it out and Execute

6. Copy the device ID of the IR code set you want to delete from the response body

7. Scroll further down to DELETE /ir/codes/custom/{codeSetId}

8. Click on Try it out, paste the deviceID into the CodeSetID field and execute

9. To check if the code set has been deleted repeat steps 1 to 5

Similarly you can update an existing IR code set file:

1. Go to POST /ir/codes/custom/{codeSetId}

2. Click on Try it out, enter the deviceID you want to update in the CodeSetID field

3. Select the updated file and click on execute

4. In the response body you should see how many commands were added/updated/deleted etc.”

1 Like

Thank you, I have deleted the TEST IR Codes via the API way!

1 Like

this method works too