aboutsummaryrefslogtreecommitdiffstats
path: root/list-observations
diff options
context:
space:
mode:
Diffstat (limited to 'list-observations')
-rwxr-xr-xlist-observations10
1 files changed, 6 insertions, 4 deletions
diff --git a/list-observations b/list-observations
index 869e307..5064478 100755
--- a/list-observations
+++ b/list-observations
@@ -224,7 +224,8 @@ def printObservation(feature):
vernacularName = properties.get('VernacularName')
if vernacularName is None:
- raise Exception('Missing name')
+ pass
+ #raise Exception('Missing name')
if args.taxon is not None:
name = vernacularName.lower()
if not any([sub in name for sub in args.taxon]):
@@ -293,7 +294,8 @@ def printObservation(feature):
if sum_count > 0:
print('')
- print(f'Artnamn: {vernacularName.title()}')
+ if vernacularName is not None:
+ print(f'Artnamn: {vernacularName.title()}')
name = vernacularName
if taxonIsRedlisted is not None and taxonIsRedlisted and redlistCategory is not None:
@@ -327,11 +329,11 @@ def printObservation(feature):
if v is not None:
print(f'Metod: {v}')
- if ',' in reportedBy:
+ if reportedBy is not None and ',' in reportedBy:
print(f'Rapportörer: {reportedBy}')
else:
print(f'Rapportör: {reportedBy}')
- if ',' in recordedBy:
+ if recordedBy is not None and ',' in recordedBy:
print(f'Observatörer: {recordedBy}')
else:
print(f'Observatör: {recordedBy}')