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

use mongo downloader in utilix #190

Merged
merged 2 commits into from
Oct 12, 2024
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
11 changes: 3 additions & 8 deletions appletree/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -187,15 +187,10 @@ def get_file_path(fname):
# 5. From MongoDB
if not SKIP_MONGO_DB:
try:
import straxen
import utilix

# https://straxen.readthedocs.io/en/latest/config_storage.html
# downloading-xenonnt-files-from-the-database # noqa

# we need to add the straxen.MongoDownloader() in this
# try: except NameError: logic because the NameError
# gets raised if we don't have access to utilix.
downloader = straxen.MongoDownloader()
# Mongo downloader is implemented in utilix
downloader = utilix.mongo_storage.MongoDownloader()
# FileNotFoundError, ValueErrors can be raised if we
# cannot load the requested config
fpath = downloader.download_single(fname)
Expand Down
1 change: 0 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@ pandas = "*"
scikit-learn = "*"
scipy = "*"
strax = "*"
straxen = "*"
graphviz = "*"
Copy link
Collaborator

Choose a reason for hiding this comment

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

Please add utilix = ">=0.10.1" here.

commonmark = { version = "0.9.1", optional = true }
m2r = { version = "0.2.1", optional = true }
Expand Down
Loading