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

ldp.resource.patch ne marche pas bien quand on a de multiple blank nodes #893

Open
srosset81 opened this issue Dec 6, 2021 · 3 comments
Assignees
Labels
bug Something isn't working high priority

Comments

@srosset81
Copy link
Contributor

Si je fais deux fois appels à ldp.resource.patch comme ça:

await ctx.call('ldp.resource.patch', {
  resource: {
    '@context': 'https://www.w3.org/ns/activitystreams',
    '@id': webId,
    endpoints: {
      proxyUrl: urlJoin(webId, 'proxy')
    }
  },
  contentType: MIME_TYPES.JSON,
});

await ctx.call('ldp.resource.patch', {
  resource: {
    '@context': 'https://www.w3.org/ns/activitystreams',
    '@id': webId,
    endpoints: {
      'void:sparqlEndpoint': urlJoin(webId, 'sparql')
    }
  },
  contentType: MIME_TYPES.JSON,
});

Cela apparait comme ça dans le triplestore:

<http://localhost:3000/test>
        a       <http://xmlns.com/foaf/0.1/Person> , <https://www.w3.org/ns/activitystreams#Person> ;
        <https://www.w3.org/ns/activitystreams#endpoints>
                [ <https://www.w3.org/ns/activitystreams#proxyUrl>
                          <http://localhost:3000/test12/proxy> ] ;
        <https://www.w3.org/ns/activitystreams#endpoints>
                [ <http://rdfs.org/ns/void#sparqlEndpoint>
                          <http://localhost:3000/test12/sparql> ] ;

Alors que les deux blank nodes devraient se trouver lié au même predicate.

De plus cela a pour effet de dédoubler les blank nodes existants (publicKey dans cet exemple):

<http://localhost:3000/test>
        a       <http://xmlns.com/foaf/0.1/Person> , <https://www.w3.org/ns/activitystreams#Person> ;
        <https://w3id.org/security#publicKey>
                [ <https://w3id.org/security#owner>
                          <http://localhost:3000/test12> ;
                  <https://w3id.org/security#publicKeyPem>
                          "-----BEGIN PUBLIC KEY-----\nMIICIjANBgkqhkiG9w0BAQEFAAOCAg8AMIICCgKCAgEAwGrJmqvr3o6avLx1AhnG\n8ZOXaB7O5jm2HfyuqQ80SpKVk8OaVaTZe0XhZQA24+pbZ6tjIsMG2PIySDwKeait\njtKTjycCL2FHVmvaQdVbnqwLTiYRGiVxzeUI6QioQ1zgdsnGzG38LlUwBu9/0YZ5\neEQ0SraRl1K3mKR6aCkzj8Lvi4sdB2Yt9+Mb9ksNqlSizzPFtoIQgAvKMCIifmBj\nkatFk1E8l9FkJ3YhToudqpBWVHaa2Tcq4PrXVN583eGzIUVntisCsGzsaea+Bqf3\njBbbSpzjdvG/cOuBqnqFpZMIEs8Z6xHEvREgN9JJ+fTZ0kqhgRoszMoQev6cmB49\noOGeh0mBPOH47xj80JFpEbzAyCiULQNoR3Nrs6eMcfWS7g485nwsxpQLzOfpm9rr\n+JxIHCYjZLxijoU99g1WXQwrPnuRmk3WodM/tnxsp4JYhqlFpCX/IsgrcoY8Odsq\nBYjQqreZXSvU9cXbsAgZxCB9b6qMqgaRJBqh8tgL2xUeEEauqeXhzHYQ4T9baAmS\ngoqX0DdGbHXufMhd4Z5w5JX4i+YHPLMhTwtg+iCc2Dit8c15vEy02HHTWh6bGZjl\nIFQwUsIRauJKJUVHrEVsSkgqvEHV34iCNPwrCoqPEwbHs1vfmKzVIweOA+doinGV\nS98F7lyruEY5bLGEdiz4TcECAwEAAQ==\n-----END PUBLIC KEY-----\n"
                ] ;
        <https://w3id.org/security#publicKey>
                [ <https://w3id.org/security#owner>
                          <http://localhost:3000/test12> ;
                  <https://w3id.org/security#publicKeyPem>
                          "-----BEGIN PUBLIC KEY-----\nMIICIjANBgkqhkiG9w0BAQEFAAOCAg8AMIICCgKCAgEAwGrJmqvr3o6avLx1AhnG\n8ZOXaB7O5jm2HfyuqQ80SpKVk8OaVaTZe0XhZQA24+pbZ6tjIsMG2PIySDwKeait\njtKTjycCL2FHVmvaQdVbnqwLTiYRGiVxzeUI6QioQ1zgdsnGzG38LlUwBu9/0YZ5\neEQ0SraRl1K3mKR6aCkzj8Lvi4sdB2Yt9+Mb9ksNqlSizzPFtoIQgAvKMCIifmBj\nkatFk1E8l9FkJ3YhToudqpBWVHaa2Tcq4PrXVN583eGzIUVntisCsGzsaea+Bqf3\njBbbSpzjdvG/cOuBqnqFpZMIEs8Z6xHEvREgN9JJ+fTZ0kqhgRoszMoQev6cmB49\noOGeh0mBPOH47xj80JFpEbzAyCiULQNoR3Nrs6eMcfWS7g485nwsxpQLzOfpm9rr\n+JxIHCYjZLxijoU99g1WXQwrPnuRmk3WodM/tnxsp4JYhqlFpCX/IsgrcoY8Odsq\nBYjQqreZXSvU9cXbsAgZxCB9b6qMqgaRJBqh8tgL2xUeEEauqeXhzHYQ4T9baAmS\ngoqX0DdGbHXufMhd4Z5w5JX4i+YHPLMhTwtg+iCc2Dit8c15vEy02HHTWh6bGZjl\nIFQwUsIRauJKJUVHrEVsSkgqvEHV34iCNPwrCoqPEwbHs1vfmKzVIweOA+doinGV\nS98F7lyruEY5bLGEdiz4TcECAwEAAQ==\n-----END PUBLIC KEY-----\n"
                ] ;
        <https://www.w3.org/ns/activitystreams#endpoints>
                [ <https://www.w3.org/ns/activitystreams#proxyUrl>
                          <http://localhost:3000/test12/proxy> ] ;
        <https://www.w3.org/ns/activitystreams#endpoints>
                [ <http://rdfs.org/ns/void#sparqlEndpoint>
                          <http://localhost:3000/test12/sparql> ] ;
@fluidlog
Copy link
Contributor

@BastienSig, vu que tu es assigné à cette issue flaguée en "high priority", peux-tu nous mettre un petit point de situation ici ? Merci

@simonLouvet simonLouvet self-assigned this Mar 31, 2022
@simonLouvet
Copy link
Contributor

simonLouvet commented Jun 3, 2022

voir détails de résolution dans #985

@simonLouvet
Copy link
Contributor

décision commune : supprimer l'API PATCH

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working high priority
Projects
None yet
Development

No branches or pull requests

4 participants