Skip to content

Instantly share code, notes, and snippets.

View 0xmtn's full-sized avatar
🎯
Focusing

Metin Emenullahi 0xmtn

🎯
Focusing
View GitHub Profile
/eodata/Sentinel-2/MSI/L1C/2020/08/15/S2A_MSIL1C_20200815T085601_N0209_R007_T35SND_20200815T104041.SAFE/GRANULE/L1C_T35SND_A026888_20200815T085756
/eodata/Sentinel-2/MSI/L1C/2020/08/12/S2A_MSIL1C_20200812T084601_N0209_R107_T35SND_20200812T110047.SAFE/GRANULE/L1C_T35SND_A026845_20200812T085219
/eodata/Sentinel-2/MSI/L1C/2020/08/10/S2B_MSIL1C_20200810T085559_N0209_R007_T35SND_20200810T101708.SAFE/GRANULE/L1C_T35SND_A017908_20200810T090242
/eodata/Sentinel-2/MSI/L1C/2020/08/07/S2B_MSIL1C_20200807T084559_N0209_R107_T35SND_20200807T100515.SAFE/GRANULE/L1C_T35SND_A017865_20200807T085234
/eodata/Sentinel-2/MSI/L1C/2020/08/05/S2A_MSIL1C_20200805T085601_N0209_R007_T35SND_20200805T104131.SAFE/GRANULE/L1C_T35SND_A026745_20200805T085807
/eodata/Sentinel-2/MSI/L1C/2020/08/02/S2A_MSIL1C_20200802T084601_N0209_R107_T35SND_20200802T110352.SAFE/GRANULE/L1C_T35SND_A026702_20200802T085244
/eodata/Sentinel-2/MSI/L1C/2020/07/31/S2B_MSIL1C_20200731T085559_N0209_R007_T35SND_20200731T111648.SAFE/GRANULE/L1C_T35SND_A017765_20200731T09
@0xmtn
0xmtn / gist:7da1812db7fef11d2bdd
Created June 2, 2014 12:00
Neo4Django - Cannot create node - StatusException thrown
>>> p = Person.objects.create(name="Metin Emenullahi", user_id="sdg'd;f", registered_at="05/01/2014");
Traceback (most recent call last):
File "<console>", line 1, in <module>
File "/usr/local/lib/python2.7/dist-packages/neo4django-0.1.8-py2.7.egg/neo4django/db/models/manager.py", line 43, in create
return self.get_query_set().create(**kwargs)
File "/usr/local/lib/python2.7/dist-packages/neo4django-0.1.8-py2.7.egg/neo4django/db/models/query.py", line 1307, in create
return super(NodeQuerySet, self).create(**kwargs)
File "/usr/local/lib/python2.7/dist-packages/Django-1.5.8-py2.7.egg/django/db/models/query.py", line 416, in create
obj.save(force_insert=True, using=self.db)
File "/usr/local/lib/python2.7/dist-packages/neo4django-0.1.8-py2.7.egg/neo4django/db/models/base.py", line 325, in save
@0xmtn
0xmtn / djsimplelogger.py
Last active January 1, 2016 08:29
Django simple Logger
import logging
# Setting up the logger
logging.basicConfig(level=logging.DEBUG, filename="/dev/null")
# Getting all the user added apps
apps = [ app for app in INSTALLED_APPS if "django" not in app ]
# Creating file path list with log files appended to app names in apps list
apps_log_files = [ app + "/logs/access.log" for app in apps ]
# Create logging handlers
log_handlers = [ logging.FileHandler(i) for i in apps_log_files ]
# Lambda to set levels of log handlers