teamdigitale / dati-semantic-backend

Backend for the NDC semantic repository
GNU Affero General Public License v3.0
4 stars 4 forks source link

Duplication of repository upon Create #102

Closed FrankMaverick closed 5 months ago

FrankMaverick commented 5 months ago

Expected Behavior

When creating a deleted repository, it should be reactivated instead of duplicated. As seen from the call to /api/config/repository in the DEV environment, there are two instances of the INAIL repository when there should only be one.

Current Behavior

Instead of reactivating the repository, it gets duplicated. The call to /api/config/repository shows two instances of the INAIL repository.

{
    "id": "...",
    "url": "https://github.com/InailUfficio5/inail-ndc",
    "name": "Inail-ndc",
    "owner": "CONFIG",
    "active": true,
    "createdAt": "2023-12-21T13:00:35Z",
    "createdBy": "CONFIG",
    "updatedAt": "2024-04-04T13:15:40Z",
    "updatedBy": "harv-user",
    "..."
},
{
    "id": "...",
    "url": "https://github.com/InailUfficio5/inail-ndc",
    "name": "Inail-ndc",
    "owner": "harv-user",
    "active": true,
    "createdAt": "2024-04-04T13:14:23Z",
    "createdBy": "harv-user",
    "updatedAt": "2024-04-04T13:26:42Z",
    "updatedBy": "harv-user",
    "..."
}

This leads to errors when running the harvester.

@Clou-dia @AgostinoPurificato