Comments (11)
I'll have this fixed soon. Working on it now.
from ph5.
Okay thanks. I think shotline and shotid should also accept wildcards.
Just FYI, I can expand most of the wildcards in the web handler, but cannot handle shot-ids and shotlines since the ph5toexml.py program can currently only return all event info for one network. Eventually I think we will want to change the ph5toexml.py program to accept additional query arguments. Then I could expand all wildcards in a list of requests in the handler code and remove overlapping/duplicate requests, in order to add support for HTTP POST for the by Shot request type. This is what I do currently for the FDSN request type.
from ph5.
shotid will be easy to accept wildcards, shotline I'll have to work on a bit since you can only have a maximum of one shotline per request and wildcards could match multiple shotlines.
from ph5.
In that case maybe we only support wildcards for shotid and not shotline. Do you think supporting wildcards for shotlines would be a useful feature?
from ph5.
What I'm going to do now is push code that fixes the array, station, and channel wildcards sicne that is done.
I think we should definitely support wildcards for shotlines and shotids as well as requesting multiple shotlines. I can fix this but it will take substantially more coding and probably more time than I have today to fix those wildcards and add the the ability for multiple shotlines. I will work on this and try to get that pushed by the end of the weekend.
from ph5.
Okay that sounds good. Don't worry about working on it over the holiday weekend unless you want to. The FDSN request type still works fine since I expand wildcards in the web handler as I described above. I would say that proper error handling is equally, if not more, important as supporting wildcards for shotid and shotline.
from ph5.
Can you add wildcard support for component-id easily to ph5tomsAPI.py?
from ph5.
Yeah I can add that no problem.
from ph5.
As long as we are updating ph5tomsAPI could we also change the eventnumbers parameter in the constructor to take a List instead of a comma separated String so that it matches the other input parameters?
i.e. eventnumbers=""
would be changed to eventnumbers=[]
here:
https://github.com/PIC-IRIS/PH5/blob/master/webservices/ph5tomsAPI.py#L99
Update:
@derick-hess
Additionally, it looks like component, station, channel, doy_keep, and station_id are currently defaulting to empty Lists in the constructor, but are still treated like comma separated Strings in the code. For example, if you pass a List of stations (e.g. ['1001','1002']
) to the station parameter, it will break on line 352 when it tries to split the List like a comma separated string.
e.g.
File "ph5tomsAPI.py", line 352, in create_cut_list
sta_patterns = self.station.split(',')
AttributeError: 'list' object has no attribute 'split'
from ph5.
i'll work on fixing all of those.
from ph5.
Thanks for pushing your fixes @derick-hess. All of the changes you made seem to be good, so I'm closing this issue.
from ph5.
Related Issues (20)
- [FEATURE] Optimize geo_kef_gen or modify to allow user to specify shot lines HOT 1
- [BUG] ph5_validate fix incorrect errors/warnings HOT 1
- [FEATURE]Improve validation for noven
- [BUG] SmartSolo array table coordinate precision decreased HOT 2
- [BUG] ph5toevt & ph5torec not handling overlapping data correctly HOT 3
- [BUG] ph5availability output for SmartSolo does not cover all expected times HOT 2
- [BUG] ph5toms: Data extraction inconsistent when number of input files is too large HOT 3
- [BUG] pforma is sorting SmartSolo data by file name, not das serial number HOT 6
- [BUG] ph5availability performance HOT 1
- [BUG] segytoph5 throwing exceptions an not running HOT 2
- ph5_validate: ph5.utilities.ph5validate - ERROR: list index out of range HOT 1
- [BUG] ph5availabilty potential duplicating availabilty information HOT 2
- [BUG] Unable to download station response or waveforms
- [FEATURE] Look for ways to have SmartSolo pickup behave like Fairfield pickup
- [BUG] ph5tostationxml fails to produce a response-level stationxml when using NRLv2 responses
- [BUG] Fairfield Experiments Archived Before February 2020 May have incorrect Response information.
- [BUG] ph5toevt: Event table entries with a numeric description_s cause ph5toevt crash with '-x U' HOT 3
- [BUG] ph5tostationxml generates xml with incorrect response information for ph5 with multiple instrument gains HOT 1
- [BUG] ph5toevt crashes with option '-u X' when value in 'sensor/serial_number_s' is >+/- 32767
- [FEATURE] Disable pforma for RT130 and Geode/Stratavisor data
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ph5.