maggma
maggma copied to clipboard
Ensure indices seems to fail silently with read_only credentials
Another bare try/except!
So there is a true/false return with the intention that if it can't ensure the index it will just return false.
Is there another situation that might not fit in this paradigm?
well, yes, I wasn't checking the return types :) I just ran the function and it executed and moved onto the next line, I didn't realize it hadn't worked
Ok. Sounds like it's not an issue then.
passive-aggressively reopens issue it's definitely an issue, it should raise an exception if it can't ensure the index!
Specifically, these lines: https://github.com/materialsproject/maggma/blob/1f875fc66567cfa8dc08d30f606d5062c5827bef/maggma/stores.py#L257-L261
create_index
already raises the appropriate exceptions, but we're silently catching them and just returning False instead, I don't think that's a great idea?
Ok, re-opened. My reason for that behavior is that usually not having an index will not halt the operation, but merely slow it down.
I leave this issue open for debate.