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

🥅 Clear error on running track in an interactive session #2334

Merged
merged 2 commits into from
Jan 9, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions lamindb/core/_context.py
Original file line number Diff line number Diff line change
Expand Up @@ -378,6 +378,11 @@ def _track_source_code(

frame = inspect.stack()[2]
module = inspect.getmodule(frame[0])
# None for interactive session
if module is None:
raise NotImplementedError(
"Interactive sessions are not yet supported to be tracked."
)
path = Path(module.__file__)
else:
path = Path(path)
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ jupyter = [
"mistune!=3.1.0", # there is a bug in it
]
zarr = [
"zarr>=2.16.0",
"zarr>=2.16.0,<3.0.0a0", # not yet compatible with 3.0.*
Copy link
Member

Choose a reason for hiding this comment

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

We should mention somewhere that people can actually run zarr v3; they just won't be able to use anndata zarr streaming internals.

It's perfectly fine to use zarr v3 artifacts like I'm sure many people will do. But given this is an extra it might not be too confusing.

Copy link
Member

Choose a reason for hiding this comment

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

I'm glad you put in the work long ago to separate this from the core package & dependencies, @Koncopd

Copy link
Member Author

@Koncopd Koncopd Jan 9, 2025

Choose a reason for hiding this comment

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

No, they actually can't use zarr v3, the imports will error. Actually i think i even should add some additional version check to avoid that if zarr v3 is installed already.

Copy link
Member Author

Choose a reason for hiding this comment

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

Lets continue here #2334

]
fcs = [
"readfcs>=1.1.9",
Expand Down
Loading