Skip to content

rv plan doesn't consult new repos if repos change but deps don't...maybe? or other? #112

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

Closed
dpastoor opened this issue Feb 23, 2025 · 0 comments · Fixed by #196
Closed

Comments

@dpastoor
Copy link
Member

dpastoor commented Feb 23, 2025

The situation that induced the bug was as follows.

Doing a preliminary build with rproject.toml that points to a given set of repositorie(s).

after a full install, then rv/library is purged, and a second rproject-4.4.toml is used

a snippet of the original repo looks like

[project]
name = 'prism-build'
r_version = '4.4'
repositories = [
{ url = 'https://a2-ai.github.io/prism-test-snapshot-2025-02-08/2025-02-08', alias = 'PRISM' }, 
{ url = 'https://cran.r-project.org', alias = 'CRAN' }
]
dependencies = [
{name = "archive", force_source = true, repository = "CRAN"},
{name = "babelmixr2", force_source = true, repository = "CRAN"},
{name = "cards", force_source = true, repository = "CRAN"},

When pointing to the the new rproject.toml that looks like:

[project]
name = 'prism-build-binaries'
r_version = '4.4'
repositories = [{ url = 'http://localhost:6001/2025-02-22', alias = 'PRISM' }]
dependencies = [
'archive',
'babelmixr2',
'cards',
'cli',
❯ rv plan --config-file=rproject-4.4.toml 
+ abind (1.4-8, binary from https://a2-ai.github.io/prism-test-snapshot-2025-02-08/2025-02-08)
+ archive (1.1.11, source from https://cran.r-project.org)
+ AsioHeaders (1.22.1-2, binary from https://a2-ai.github.io/prism-test-snapshot-2025-02-08/2025-02-08)
+ askpass (1.2.1, binary from https://a2-ai.github.io/prism-test-snapshot-2025-02-08/2025-02-08)
+ assertthat (0.2.1, binary from https://a2-ai.github.io/prism-test-snapshot-2025-02-08/2025-02-08)

This came off as very confusing to have the plan point to binary/src files not even present int he repository options for the new config file. after poking around more it turns out thats because the plan was consulting purely the rv.lock contents.

this was super confusing - one reason I want that summary to be the default in plan to note where things are being consulted (eg if it had shown "" or some type of thing would have helped connect dots.

after deleting the rv.lock file get the expected behavior

❯ rv plan --config-file=rproject-4.4.toml 
+ abind (1.4-8, binary from http://localhost:6001/2025-02-22)
+ archive (1.1.11, source from http://localhost:6001/2025-02-22)
+ AsioHeaders (1.22.1-2, binary from http://localhost:6001/2025-02-22)
+ askpass (1.2.1, binary from http://localhost:6001/2025-02-22)
+ assertthat (0.2.1, binary from http://localhost:6001/2025-02-22)
+ babelmixr2 (0.1.6, source from http://localhost:6001/2025-02-22)

Now, onto the output itself - to break down this report a bit -

should pointing to a different config file that uses different repository/dependency configs invalidate the lockfile if it wants information not present in the lockfile? This is further complicated by whether or not packages are actually present in the rv library, where we might have the lockfile in sync (or not) with what is installed, vs what is expressed in the lockfile.

Probably worth a sync brainstorming session...

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 a pull request may close this issue.

1 participant