Skip to content

Commit

Permalink
a poetic update
Browse files Browse the repository at this point in the history
  • Loading branch information
Nschanche committed Apr 2, 2024
1 parent 8060f02 commit 398a0b4
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 6 deletions.
7 changes: 7 additions & 0 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

15 changes: 15 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
[tool.poetry]
name = "newlk-search"
version = "0.1.0"
description = "Helpful package to search for TESS/Kepler/K2 data"
authors = ["Your Name <[email protected]>"]
license = "MIT"
readme = "README.md"

[tool.poetry.dependencies]
python = "^3.9"


[build-system]
requires = ["poetry-core"]
build-backend = "poetry.core.masonry.api"
10 changes: 4 additions & 6 deletions src/newlk_search/search.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
# from .config import conf, config
from . import PACKAGEDIR, PREFER_CLOUD, DOWNLOAD_CLOUD, conf, config

default_download_dir = config.get_cache_dir()

from memoization import cached

Expand Down Expand Up @@ -787,7 +788,7 @@ def download(
cloud: bool = True,
cache: bool = True,
cloud_only: bool = False,
download_dir: str = "~/.",
download_dir: str = default_download_dir,
):
# TODO magic caching
"""
Expand All @@ -811,10 +812,7 @@ def download(
]
return manifest

def _default_download_dir(self):
# TODO: again, I can't inport config so hard code it for now
# return config.get_cache_dir()
return "~/."



class TESSSearch(MASTSearch):
Expand Down Expand Up @@ -1077,7 +1075,7 @@ def search_individual_ffi(self,

return new_table

def download(self, cloud: PREFER_CLOUD = True, cache: PREFER_CLOUD = True, cloud_only: PREFER_CLOUD = False, download_dir: PACKAGEDIR = "~/.",
def download(self, cloud: PREFER_CLOUD = True, cache: PREFER_CLOUD = True, cloud_only: PREFER_CLOUD = False, download_dir: PACKAGEDIR = default_download_dir,
TESScut_product="SPOC",
TESScut_size = 10):
mf1 = []
Expand Down

0 comments on commit 398a0b4

Please sign in to comment.