Skip to content

Conversation

rgaiacs
Copy link
Contributor

@rgaiacs rgaiacs commented Aug 22, 2025

Closes #1455

@rgaiacs
Copy link
Contributor Author

rgaiacs commented Sep 8, 2025

What's the situation that leads us here? Can we distinguish between runtime.txt being absent vs having the version and missing the date?

If runtime.txt is absent, the values will be None because of

except FileNotFoundError:
return self._runtime

From

if len(parts) in (4, 5):
date = "-".join(parts[-3:])
if not re.match(r"\d\d\d\d-\d\d-\d\d", date):
raise ValueError(f"Invalid runtime.txt date: {date}")
date = datetime.datetime.fromisoformat(date).date()
my understanding is that the data is mandatory but the date might be invalid and raise an exception.

@rgaiacs
Copy link
Contributor Author

rgaiacs commented Sep 8, 2025

This requires to incorporate #1428.

#1428 was incorporated in 53e8ce1

@rgaiacs rgaiacs requested a review from minrk September 8, 2025 14:43
@manics
Copy link
Member

manics commented Sep 8, 2025

The date is optional

Supported formats:
name-version
name-version-yyyy-mm-dd
name-yyyy-mm-dd

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

Successfully merging this pull request may close these issues.

Fail to install R 4.4 with repo2docker 2024.07.0
3 participants