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

repo.readonly_session has parameter snapshot, not snapshot_id #676

Open
DahnJ opened this issue Feb 4, 2025 · 0 comments
Open

repo.readonly_session has parameter snapshot, not snapshot_id #676

DahnJ opened this issue Feb 4, 2025 · 0 comments

Comments

@DahnJ
Copy link

DahnJ commented Feb 4, 2025

The docs imply that repo.readonly_session has a parameter snapshot_id, when in fact the parameter is named snapshot.

In Version Control:

session = repo.readonly_session(snapshot_id="BSHY7B1AGAPWQC14Q18G")

In Quickstart, there's a related syntax error:

earlier_session = repo.readonly_session(snapshot=snapshot_id=hist[1].id)

While this is a docs issue, I would also consider whether the parameter name should be unified in the API:

  • snapshot is used for readonly_session, ancestry and async_ancestry methods
  • snapshot_id is used elsewhere

If it's helpful, I am happy to make a PR with whichever change you think is best.

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

No branches or pull requests

1 participant