Skip to content

Services/loterre annotate/loterre annotate first#444

Open
stephane54 wants to merge 23 commits into
mainfrom
services/loterre-annotate/loterre-annotate-first
Open

Services/loterre annotate/loterre annotate first#444
stephane54 wants to merge 23 commits into
mainfrom
services/loterre-annotate/loterre-annotate-first

Conversation

@stephane54

Copy link
Copy Markdown
Contributor

No description provided.

@parmentf parmentf left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Une petite suggestion (pour une typo) et des remarques diverses...

Comment thread services/loterre-annotate/v1/en/loterre-annotate/annotate.ini Outdated
post.requestBody.content.application/json.schema.$ref = #/components/schemas/JSONStream
post.requestBody.required = true
post.responses.default.content.application/json.schema.$ref = #/components/schemas/JSONStream
post.summary = Produit la liste des termes Loterre identifiés dans le texte ou rend le texte annoté

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

question: Il y a un paramètre pour sélectionner le comportement de la route (produire la liste des termes identifiés / rendre le texte annoté) ?

Ou bien c'est juste une manière différente d'exprimer la même chose ?
L'exemple indique plutôt le premier comportement.‏

post.requestBody.content.application/json.schema.$ref = #/components/schemas/JSONStream
post.requestBody.required = true
post.responses.default.content.application/json.schema.$ref = #/components/schemas/JSONStream
post.summary = Produit la liste des termes Loterre identifiés dans le texte ou rend le texte annoté

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

question: ‏Même question que pour la version en...

Comment thread services/loterre-annotate/.dockerignore
Comment thread services/loterre-annotate/README.md Outdated
}
}
],
"paths": {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🪳 : nitpick (non-blocking): ‏D'habitude on ne crée pas nous-mêmes les champs paths et components du swagger, c'est le serveur ezs qui le fait.
Il est possible que ce fichier surcharge ce que produirait le serveur ezs.
L'important c'est que si tu gardes cette manière de faire, il faut maintenir cette partie aussi (au lieu de la générer via les métadonnées des fichiers .ini).

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Mais tout ça m'a l'air très propre.

Comment thread services/loterre-annotate/Dockerfile Outdated
ENV LOTERRE_REGISTRY=/app/public/configs/registry.yaml

RUN apt-get update && \
apt-get -y --no-install-recommends install git && \

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🪳 : nitpick (non-blocking): ‏La bonne pratique pour l'installation d'un paquet apt dans un Dockerfile est de mettre sa version complète (même si je comprends que pendant le développement, c'est plus pratique de ne pas la préciser).

C'est principalement pour une question de reproductibilité (et malheureusement, ça force à une maintenance plus pénible pour les versions suivantes, mais c'est déjà ce qui est fait en ligne 7 pour la première étape).

@stephane54 stephane54 left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Corrigé

@parmentf parmentf left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK. Tu peux maintenant faire une nouvelle version:

npm -w services/loterre-annotate version major

Ça provoquera la construction de l'image et ça la poussera sur Docker Hub.
Il n'y aura plus qu'à renseigner la machine et le port dans swagger.json avant que je puisse merger la branche, et créer l'URL qui pointera vers le bon container.

Ah, mais je vois que ton swagger.json n'a plus les lignes à modifier:

        {
            "url": "http://vptermsuite.intra.inist.fr:49157/",
            "description": "Latest version for production",
            "x-profil": "Standard"
        }

Il faut y mettre le bon port (et ne pas oublier le champ x-profil, sinon notre script de publication ne fonctionnera pas).

@parmentf parmentf left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ce qui est étonnant, c'est que des tests soient quand même passés.

Comment thread services/loterre-annotate/Dockerfile Outdated
Co-authored-by: François Parmentier <francois.parmentier@gmail.com>
@parmentf

Copy link
Copy Markdown
Contributor

Bon, ben maintenant il faut faire une version patch.

@parmentf parmentf left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Je ne vois pas ce qui coince dans la construction de l'image (a priori c'est la récupération du dictionary, mais pourquoi alors que la version précédente était passée.).


#### URL du service

> https://loterre-annotate.2.0.2/v1/CODE_LANGUE/loterre-annotate/2.0.2?loterreID=CODE_VOC

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🪳 : nitpick (non-blocking): ‏Bad URL

Suggested change
> https://loterre-annotate.2.0.2/v1/CODE_LANGUE/loterre-annotate/2.0.2?loterreID=CODE_VOC
> https://loterre-annotate.services.istex.fr/v1/CODE_LANGUE/loterre-annotate/annotate?loterreID=CODE_VOC

### Requête

```bash
curl -X POST 'https://loterre-annotate.2.0.2/v1/en/loterre-annotate/2.0.2?loterreID=P66' \

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🪳 : nitpick (non-blocking): ‏Bad URL

Suggested change
curl -X POST 'https://loterre-annotate.2.0.2/v1/en/loterre-annotate/2.0.2?loterreID=P66' \
curl -X POST 'https://loterre-annotate.services.istex.fr/v1/en/loterre-annotate?loterreID=P66' \

},
{
"url": "https://loterre-annotate.services.istex.fr",
"description": "Service de production"

@parmentf parmentf Jun 24, 2026

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

☑️ todo: ‏Add x-profil standard

Suggested change
"description": "Service de production"
"description": "Service de production",
"x-profil": "Standard"

Did you use an AI Assistant, it keeps removing that line...

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