Open bhilbert4 opened 2 years ago
One suggestion made in our meeting today was to show the Instrument Scientist for the proposal. We see the PC, but not the Instrument scientist reviewing the proposal.
Do you know where this information can be found?
I added the instrument scientist request as a new issue (I hadnt seen this yet)
@mengesser do you know where we can programmatically grab that information?
I assume the same place we grab the PC? Where does that come from?
That's from the public page for each proposal: https://www.stsci.edu/cgi-bin/get-proposal-info?id=1022&submit=Go&observatory=JWST
Very basic info there. I'm not sure where the SI reviewer would be stored. Nor the APT executive summary. It'll take some searching to figure out where to cobble everything together from.
It seems like def text_scrape(prop_id):
already gets the "contact scientist" in data_containers.py, it just isnt used anywhere. Should be trivial to add a line to the html if that is truly the case
This is where it would go in thumbnails_per_obs.html:
<h4 id='proposal_meta'> Proposal Information for {{ prop }}</h4>
<div class="d-flex flex-row">
<div class="column">
<p><b>Title:</b> {{ prop_meta['title'] }}</p>
<p><b>Program Status:</b> {{ prop_meta['ps']|safe }}</p>
<p><b>Principal Investigator:</b> {{ prop_meta['pi'] }}</p>
</div>
<div class="column" style="display: inline-block; text-align: right; width: 100%">
<p><b>Program Coordinator:</b> {{ prop_meta['pc']|safe }}</p>
<p><b>Proposal Type:</b> {{ prop_meta['prop_type'] }}</p>
<p><b>Phase Two:</b> {{ prop_meta['phase_two']|safe }}</p>
</div>
</div>
Ah I see. The 1022 example I used above had no contact scientist. Other programs list multiple contact scientists. We'll have to update text_scrape to accommodate that.
I see - 1022 is a CAR, so that makes sense. Seems like what happens in text_scrape
when it tries to get a contact scientist now is if 'Contact Scientist' is not in the html, it doesnt try to get it. If it is, it returns a Soup
object, which is different than what it does for the PI
if 'Contact Scientist' in line:
start = line.find('</b>') + 4
mid = line.find('<', start)
end = line.find('>', mid) + 1
cs = line[mid:end] + line[start:mid] + '</a>'
program_meta['cs'] = BeautifulSoup(cs, 'html.parser')
As opposed to the PI section:
if 'Program Coordinator' in line:
start = line.find('</b>') + 4
mid = line.find('<', start)
end = line.find('>', mid) + 1
pc = line[mid:end] + line[start:mid] + '</a>'
program_meta['pc'] = pc
When selecting a given proposal, it would be useful to see more information about it, in particular the executive summary would be helpful to understand what the observer is looking for.
Perhaps we should have a new paged linked off of the proposal/observation level page that contains more information. Depending on what other information we decide to show, this could take up a large amount of space, in which case we probably wouldn't want to show it by default on all pages?