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

Failed to flush and close #78

Open
zibiwilczynski opened this issue Aug 1, 2024 · 3 comments
Open

Failed to flush and close #78

zibiwilczynski opened this issue Aug 1, 2024 · 3 comments

Comments

@zibiwilczynski
Copy link

Hi,

when running ds.add_waveforms, after the loop is done and the script terminates, I get the message:
/miniconda3/envs/noisepy/lib/python3.10/site-packages/pyasdf/asdf_data_set.py:308: ASDFWarning: Failed to flush and close the file due to: __enter__

However, the waveforms are added correctly to the file so everything works fine.

Same for ds.add_stationxml

Regards
Zibi

@tianzeliu
Copy link

I am experiencing the same issue.

@CCstarry
Copy link

CCstarry commented Oct 9, 2024

I get the same ASDFWarning: Failed to flush and close the file due to: enter, and wish someone can solve the problem.
Here is my code:
import pyasdf
event_id = "./ASDFDataSet/event_01.h5"
ds = pyasdf.ASDFDataSet(event_id)

@CCstarry
Copy link

CCstarry commented Oct 9, 2024

Through several tests, I found that the ASDFWarning has no substantial impact on my program. And the warning can be not displayed by using:
import warnings
warnings.filterwarnings("ignore", category = UserWarning, module = 'pyasdf')

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

No branches or pull requests

3 participants