Skip to content

Raise informative error when awscli is missing - #12

Open
siddmittal wants to merge 1 commit into
ViCCo-Group:mainfrom
siddmittal:main
Open

Raise informative error when awscli is missing#12
siddmittal wants to merge 1 commit into
ViCCo-Group:mainfrom
siddmittal:main

Conversation

@siddmittal

Copy link
Copy Markdown

Currently, when awscli is not installed, S3 listing operations return
empty results and users eventually receive misleading errors such as:

No subjects found in s3://laion-fmri/

or

NoMatchingDataError

This PR detects the missing awscli dependency and raises a clear
exception instructing the user to install it via:

pip install awscli

This makes the root cause immediately visible and avoids confusing
downstream errors.

@PeerHerholz

Copy link
Copy Markdown
Collaborator

Thanks @siddmittal! I think in addition we should update the package management respectively. Adding @andropar for reference.

@PeerHerholz

Copy link
Copy Markdown
Collaborator

Hey @siddmittal,

could you please share how you installed/used laion_fmri? awscli is part of the pyproject.toml and thus, it should install when you run pip install.

@siddmittal

Copy link
Copy Markdown
Author

@PeerHerholz In my case, I was working from a forked checkout of the repository and ended up in an environment where awscli was not available. You're right that if users install the package via pip install, awscli should be installed automatically through the declared dependencies.

However, I think the main issue remains independent of how that situation arises. If awscli is unavailable for any reason (e.g., editable/development setups, incomplete environments, dependency issues, manual installations, etc.), the current behavior produces misleading downstream errors such as NoMatchingDataError or "No subjects found". Detecting the missing dependency early and raising a clear, informative exception makes the root cause immediately obvious and improves the debugging experience.

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.

2 participants