openedx / openedx/openedx-core

Create/modify API call to make pre-Verawood history data?

Open
#567 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
10
Forks
32
Avg merge
2d 17h
Merged PRs (30d)
12

Description

We updated PublishLogRecord to capture user intent (the direct field). Over time, we'll probably add more things, like distinguishing pure renames. There will be times like this when we can't backfill this information. For instance, there are situations where clicking "publish" at any of three different levels would yield identical looking PublishLogRecords. In this case, we have the code handle both cases.

Right now, code in https://github.com/openedx/openedx-platform/pull/38178 is generating "old" data to test against by manually importing PublishLogRecord and using it to set direct=None. But this breaks abstraction barriers. It would be useful for our APIs to allow the creation of old data. This could be with an optional flag to publish, e.g. set_direct=True, or some test utilities that can strip that data off after the fact.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reviewing PublishLogRecord and the test setup in openedx/openedx-platform pull request 38178, focusing on how direct=None is currently created by importing the model. Define a public API or test utility that can produce equivalent pre-history data without bypassing the abstraction. Done means the existing tests can use that API and still cover records lacking the newer intent data.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
backend-api-design, testing
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.