-
Notifications
You must be signed in to change notification settings - Fork 529
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
file like objects can be used to read and write tspair and slist #3372
Conversation
Can now also read and write to file-like objects the same way as the mseed module.
Added myself.
Didn't look at details yet but 👍 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
some PEP8 issues (see reviewdog comments inline) and needs to save/restore file position
The code now passes all tests but one on my PC: AssertionError: '185.[15 chars]00043\t185.0299988\t189.0399933\t194.0500031\t205.0599976' != '185.[15 chars]000430000001\t185.02999879999999\t189.03999329[28 chars]9976' - 185.0099945 181.0200043 185.0299988 189.0399933 194.0500031 205.0599976 ? ^ ^ + 185.0099945 181.02000430000001 185.02999879999999 189.03999329999999 194.0500031 205.0599976 ? +++++++ ^^^^^^^^ ^^^^^^^^ This might be a shortcoming of the test.
The code now passes the unit test on my PC except for probable rounding issues
Not sure whether this is an issue with the code or just a shortcoming in the test. |
Can you please fix the code formatting before we look at details of test fails, so we can see clearer? Thanks! PEP8 fails are in the bot comments on the code tab or just run flake8 on command line.
|
Now adherent to pep8
I believe this is done now with #3240 merged. Again sorry for overlooking this one for some time. |
Can now also read and write to file-like objects the same way as the mseed module. Using io.BytesIO comes in handy for example when you use obspy in a web server context. This way, it doesn't need to generate intermediate files on disk.
What does this PR do?
Please fill in
Why was it initiated? Any relevant Issues?
Please fill in (link relevant issues with "see #123456", mark issues that get resolved with "fixes #12345")
PR Checklist
master
for new features,maintenance_...
for bug fixesno_ci
label can be added to skip CI buildsJust add the
build_docs
tag to this PR.Docs will be served at docs.obspy.org/pr/{branch_name} (do not use master branch).
Please post a link to the relevant piece of documentation.
clients.fdsn
) should be tested for the PR,just add the
test_network
tag to this PR.CHANGELOG.txt
.CONTRIBUTORS.txt
.from all the CI builds look correct. Add the "upload_plots" tag so that plotting
outputs are attached as artifacts.
CODEOWNERS
with your github handleready for review
label when you are ready for the PR to be reviewed.