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

Try to understand why .lamindb_current_sources.yaml is sometimes deleted. #165

Open
Zethson opened this issue Nov 19, 2024 · 1 comment
Open
Labels
bug Something isn't working

Comments

@Zethson
Copy link
Member

Zethson commented Nov 19, 2024

https://laminlabs.slack.com/archives/C07DB677JF6/p1732034802840439

@Zethson Zethson added the bug Something isn't working label Nov 19, 2024
@Zethson
Copy link
Member Author

Zethson commented Jan 9, 2025

This is mindboggling and weird.

So I ran

!lamin init --storage ./run-tests --name run-tests --schema bionty

import lamindb as ln
import bionty as bt
import pandas as pd

mondo_diseases = [
    "Alzheimer's disease", "Parkinson's disease", "Breast cancer", "Colorectal cancer", "Asthma", 
    "Diabetes mellitus type 2", "Hypertension", "Multiple sclerosis", "Osteoporosis", "Cystic fibrosis", 
    "Huntington's disease", "Leukemia", "Lung cancer", "Prostate cancer", "Rheumatoid arthritis", 
    "Sickle cell anemia", "Thalassemia", "Schizophrenia", "Bipolar disorder", "Liver cirrhosis",
    "Chronic obstructive pulmonary disease", "Pancreatic cancer", "Psoriasis", "Amyotrophic lateral sclerosis", "Epilepsy"
]

fake_diseases = [f"FakeDisease_{i}" for i in range(1, 26)]

df = pd.DataFrame({
    "Disease": mondo_diseases + fake_diseases,
})

curator = ln.Curator.from_df(df, categoricals={"Disease": bt.Disease.name})
curator.validate()

then I ran the same cell again without restarting the kernel and then it just got deleted. If I now keep running it, the issue persists. However, if I restart the kernel and then execute it, it's fine. So it must have something to do with that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant