diff --git a/scipost_django/production/models.py b/scipost_django/production/models.py index 0ed51561c93f1b42cde62d2978c5e61e99a383a0..c8170f3a157eb55a9b390019b5a3400a475037e8 100644 --- a/scipost_django/production/models.py +++ b/scipost_django/production/models.py @@ -560,7 +560,7 @@ class ProofsRepository(models.Model): # Attempt to fetch the publication file try: - publication_filename = [file["name"] for file in project.repository_tree() if re.findall("\d+(_\d+)*.tex", file["name"])][0] + publication_filename = [file["name"] for file in project.repository_tree() if re.findall("SciPost\w+(?:_\d+)+.tex", file["name"])][0] publication_file = project.files.get( file_path=publication_filename, ref="main" )