Closed kencho51 closed 2 months ago
To ensure the relevant information stay together, here are the gitter chat converstion adding precision to this ticket:
The ticket of concern is #2022, not #1944. The #1944's purpose is now only about fixing the CSP issue which I believed Ken is finalising a PR for.
When you deploy GigaDB to AWS, the RDS PostgreSQL there get loaded with a backup of live data
You can make the following SQL query (from #2022 which also show the result) using pgAdmin/DBeaver/PHPStorm to get data that feeds into mapbrowse.php
:
SELECT attribute_id, value, count(*) FROM sample_attribute WHERE attribute_id = 269 GROUP BY attribute_id, value order by count desc;
269 is the ID for geographic location (latitude and longitude)
in the attribute table.
Clearly most, if not all of the results are invalid coordinates.
There is another query you can make:
SELECT attribute_id, value, count(*) FROM sample_attribute WHERE attribute_id = 270 GROUP BY attribute_id, value order by count desc;
Where 270 is the ID for geographic location (country and/or sea,region)
So there are cases in the results where the author seemed to have used the wrong attribute and put info in 269 instead 270. There are also cases of incorrect annotation to describe geolocation (that includes with weird characters too) Finally there are the cases where the author cannot input the geolocation data and instead fills in the reason.
The curation guidelines in https://gigadb.org/site/guide (look for the aforementioned attributes labels in the "Required metadata" section) Is very clear about what the annotation should be
Resolving #2022 seems to be about:
geographic location (latitude and longitude)
contains reasons should probably be removedgeographic location (latitude and longitude)
with invalid contentHi @alli83,
After talking to @only1chunts, I can confirm the button on the page that calls the sample map should be seen by everyone, not just logged-in user.
Hi, Not been following this as closely as I should have been, but please do NOT use attribute 269, that is an old obsolete attributes that are no longer being actively used and eventually the curation team will convert those to the individual attributes for latitude (391) and longitude (392). The individual lat and lon terms are the ones that should be mapped as per the request in ticket #831.
Hi @alli83,
It seems that we were looking at the wrong attributes IDs. Making the work described in this ticket redundant.
The work to be done to get mapbrowse working again is to update the script to read latitude and longitude from different attribute values. That work is already described in #831 which is the one to work on, so I'm closing this one
Relate to #1944
When I executed the query in the
actionMapbrowse
in my staging database,the returned
value
are something like,not recorded
,00°15' N 98°08' E
,off Heligoland, North Sea
or31.48
.I then further looked into the sample_attribute table using:
And then got this returns:
So clearly, besides the CSP problem, the
value
itself in thesample_attribute
table is not standardized and not formatted well, it causes thegeojson_features
array is empty, which leads to nodots
can be seen in the map in the/site/mapbrowse
page.The sanity check in the
mapbrowse.php
is not enough to check all thevalue
cases in thesample_attribute
table in the current production database.To do: