Skip to content

add fallback mapping for os that are unsupported by rhub#160

Open
ben-schwen wants to merge 1 commit intonanxstats:mainfrom
ben-schwen:main
Open

add fallback mapping for os that are unsupported by rhub#160
ben-schwen wants to merge 1 commit intonanxstats:mainfrom
ben-schwen:main

Conversation

@ben-schwen
Copy link
Copy Markdown

@ben-schwen ben-schwen commented Jan 21, 2026

Closes #159

Apparently the rhub API only supports debian up to debian 12

This PR adds a list of fallback version for these cases. Definitely not the most elegant option but it seemed viable.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds a fallback mechanism to map unsupported Linux distribution versions to their closest supported versions when querying the rhub API. The rhub API currently only supports Debian up to version 12, so this change enables the tool to work with newer Debian versions (like Debian 13) by falling back to Debian 12.

Changes:

  • Added fallback_platform function that maps unsupported OS versions to supported ones
  • Integrated the fallback mapping into the linux_platform function before constructing the platform string

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/r_version.rs
Comment thread src/r_version.rs
@nanxstats
Copy link
Copy Markdown
Owner

Great, this fallback makes sense, but let me take a closer look into the exact behavior of --skip-r-install and see why this even happens because theoretically, it should not even need r-hub...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

failes to resolve requested R version, even with skip-r-install

3 participants