Skip to content

Library pack refresh rewrites parts whose libraries did not change #116

Closed

Description

@alekswebnet

The weekly refresh that opened #111 (pack 1.0.1) changed 35 parts, but only five libraries changed: BranchingScenario 1.11.2, Components 1.0.101, Flashcards 1.7.24, MemoryGame 1.3.53 and QuestionSet 1.21.14. The other 30 parts hold the same entries as before (names, CRC-32s, sizes) in another order:

AdvancedBlanks, BranchingQuestion, CKEditor, ContinuousText, CoursePresentation, Dialogcards, DragNBar, DragNResize, DragQuestion, DragText, ExportableTextArea, FreeTextQuestion, GoToQuestion, IVHotspot, InteractiveVideo, MarkTheWords, MaterialDesignIcons, MultiMediaChoice, OpenEndedQuestion, Questionnaire, Shape, SimpleMultiChoice, SingleChoiceSet, Summary, Table, Text, TrueFalse, TwitterUserFeed, Video and Shepherd.

Why it matters

A part's id is its SHA-256, and the libraries revision covers each archive's entries in order. So browsers download those parts again, and every package the pack serves with one of them gets a new revision and starts its saved state over once. That includes packages that use none of the five updated libraries, such as a Course Presentation or an Interactive Video exported without its libraries. A pack release is meant to change nothing for a package whose libraries it does not touch.

Cause

apps/demo/scripts/build-libraries.mjs takes each library from the first bundle in CONTENT_TYPES that carries its newest version, with its files in that bundle's order. Branching Scenario's bundle is the first to carry Text, Course Presentation, Interactive Video, Video and the parts they hold. The hub rebuilt that bundle for Branching Scenario 1.11.2, with the files in another order.

The workflow's guard did not catch it: it stops only when the files change and no library in libraries.txt does.

Fix

  • Write the pack with a library's entries taken from the committed pack, as they are, when its files are the same, so its part comes out as before.
  • Have the workflow stop when a part changes and its library's line in libraries.txt does not.
  • Then run the workflow again, so that Library pack 1.0.1 #111 holds the five updated libraries alone.

Activity

  1. added a commit that references this issue on Nov 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions