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

Refactor generate page set script to (1) support nonconsecutive works and (2) simplify page selection logic #101

Open
2 tasks
laurejt opened this issue Oct 7, 2024 · 1 comment
Assignees

Comments

@laurejt
Copy link
Contributor

laurejt commented Oct 7, 2024

  • Support nonconsecutive PPA works

  • Simplify page selection

@laurejt laurejt assigned laurejt and rlskoeser and unassigned rlskoeser Oct 7, 2024
@rlskoeser
Copy link
Collaborator

To improve handling of PPA excerpt page ranges, I recommend we use intspan. In ppa-django we use the intspan package to parse page ranges, and anything in the data exports is guaranteed parsable by intspan.

Here's where we use it in the ppa-django DigitizedWork model: https://github.com/Princeton-CDH/ppa-django/blob/main/ppa/archive/models.py#L1047-L1053

It returns an object that can be treated as an iterable with all page numbers included in the span.

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

No branches or pull requests

2 participants