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

[TECH] ajoute un script pour créer les knowledge-element-snapshot perdus (pix-17101) #11780

Open
wants to merge 1 commit into
base: dev
Choose a base branch
from

Conversation

lionelB
Copy link
Member

@lionelB lionelB commented Mar 21, 2025

🌸 Problème

Suite à des incidents de prod et un bug dans l'utilisation des transactions, certaines données ont partiellement été écrites au moment du partage de résultat. Le statut de la campagne a été mis à jour mais le snapshot associé n'a pas été créé.

🌳 Proposition

On a corrigé l'utilisation de transaction. Il faut maintenant rattraper les données et créer les snapshot

🐝 Remarques

ras

🤧 Pour tester

  • partager une participation
  • se connecter sur le posgres et supprimer le snapshot associé
  • lancer le script
  • voir le snapshot contient les bon ke

@pix-bot-github
Copy link

Une fois les applications déployées, elles seront accessibles via les liens suivants :

Les variables d'environnement seront accessibles via les liens suivants :

});

describe('#handle', function () {
it("should create ke-snapshot for participation when they don't exists", async function () {
Copy link
Member Author

Choose a reason for hiding this comment

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

il manque un test pour valider qu'on prend bien les ke avant la date de partage de résultats

@alicegoarnisson alicegoarnisson force-pushed the pix-17101/delete-duplicate-snapshot-script branch from 454f1bc to f6e957f Compare March 21, 2025 13:45

const LOG_CONTEXT = 'add-remove-knowledge-element-snapshot';

class AddRemoveKnowledgeElementSnapshots extends Script {
Copy link
Contributor

Choose a reason for hiding this comment

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

addRemove ? removed ?

Copy link
Contributor

Choose a reason for hiding this comment

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

AddMissingKnowledgeElementSnapshots ?

@La-toile-cosmique La-toile-cosmique self-requested a review March 24, 2025 10:35
continue;
}
if (campaign.isExam) {
logger.error(`${LOG_CONTEXT} | Skip campaign participation ${campaignParticipationId}, campaign to exam`);
Copy link
Contributor

Choose a reason for hiding this comment

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

campaign is of type exam

@La-toile-cosmique
Copy link
Contributor

La-toile-cosmique commented Mar 24, 2025

Func ok 👍🏼 j'ai juste pas essaye le type exam
grocha

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants