Skip to content

Cache issues with lesson ordering #7146

@renatho

Description

@renatho

Steps to Reproduce

  1. Create an atomic site (I tested on Pressable).
  2. Create a course with modules and lessons.
  3. Save it.
  4. Change the lessons order.
  5. Save it, and refresh the editor.

What I Expected

To see the lessons in the saved order.

What Happened Instead

The previous order is displayed.

The same issue happens if we sort the lessons through Sensei LMS > Lessons > Order Lessons, and check the order in the frontend (the order in the frontend will be cached).

PHP / WordPress / Sensei LMS version

PHP 8.1 / WordPress 6.3.1 / Sensei LMS 4.16.1

Browser / OS version

Chrome

Screenshot / Video

Screen.Recording.2023-09-01.at.11.50.12.mov

Context / Source

A while ago, I worked on #4236, fixing a related thing. The cause here is the same cache, but in different parts of the code. Since it's been a while, I don't remember exactly the causes in the core, but maybe going deeper into the issue again, we could find a better solution. If not, a short-term solution could be always avoiding the cache in that situation, but I'm not sure about performance complications.

More context:

  • p1693520624650459/1692982559.274589-slack-C02P7FHLVR9
  • 6700401-zd-a8c (I'm not totally sure if it's the issue for this user)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Customer ReportIssues or PRs that were reported via Happiness. Previously known as "Happiness Request".[Type] Bug

    Type

    No type

    Projects

    Status

    Backlog

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions