Skip to content

Instantly share code, notes, and snippets.

View ismailsunni's full-sized avatar

Ismail Sunni ismailsunni

View GitHub Profile
@ismailsunni
ismailsunni / gist:3825536
Created October 3, 2012 07:13
Impact function documentation return value
rating: 0
permissible_haz_input: A raster layer where each cell represents flood dept, or a vector polygon layer where each polygon represents an inundated area. Optionally the user may nominate an attribute in the polygon layer that represents inundation depth.
permissible_exp_input: vector polygon layer extracted from OSM where each polygon represents the footprint of a building.
unique_identifier: Flood Building Impact Function
actions: Provide details about where critical response areas are
detailed_desc: This is an area for free form text where a detailed description of the methodology used is given.
limitation: Lorem ipsum limitation
title: Be temporarily closed
author: Ole Nielsen, Kristy van Putten
synopsis: To assess the impacts of inundation on building footprints originating from OpenStreetMap (OSM).
@ismailsunni
ismailsunni / gist:3870683
Created October 11, 2012 07:01
Translation failed
sunnii@sunnii:~/Documents/inasafe/inasafe-dev$ git reset --hard 519fee43a076a470514d3f2efceb1e07e8b6e1c7
HEAD is now at 519fee4 In progress unit testing updates and extension of qgis interface mock class to support layer addition notifications
sunnii@sunnii:~/Documents/inasafe/inasafe-dev$ git reset --hard 4dec06bef0002daf641efb5af05bf1cecf5824a5
HEAD is now at 4dec06b Merge branch 'master' of github.com:AIFDR/inasafe
@ismailsunni
ismailsunni / Last good vs first bad
Created October 11, 2012 08:14
Last good vs first bad
Last good:
sunnii@sunnii:~/Documents/inasafe/inasafe-dev$ git reset --hard 4dec06bef0002daf641efb5af05bf1cecf5824a5
HEAD is now at 4dec06b Merge branch 'master' of github.com:AIFDR/inasafe
First bad:
sunnii@sunnii:~/Documents/inasafe/inasafe-dev$ git reset --hard e007586d23899dd241e53a2f78e9cdcf9461aa00
HEAD is now at e007586 In progress added logging to qgis_safe and tests and layer(s)Added handlers for canvas. Fixed bug that causes layer duplication in canvas.
@ismailsunni
ismailsunni / gist:4201831
Created December 4, 2012 08:26
Error on windows
Tidak bisa memuat plugin inasafe-dev karena kesalahan ketika memanggil metode initGui()
Traceback (most recent call last):
File "C:/PROGRA~2/Quantum GIS Lisboa/apps/qgis/./python\qgis\utils.py", line 173, in startPlugin
plugins[packageName].initGui()
File "C:/Users/user/.qgis//python/plugins\inasafe-dev\safe_qgis\plugin.py", line 250, in initGui
self.dockWidget = Dock(self.iface)
File "C:\Users\user\.qgis\python\plugins\inasafe-dev\safe_qgis\dock.py", line 122, in __init__
myLongVersion = get_version()
File "C:\Users\user\.qgis\python\plugins\inasafe-dev\safe\common\version.py", line 44, in get_version
@ismailsunni
ismailsunni / gist:4201841
Created December 4, 2012 08:27
Error on windows
Tidak bisa memuat plugin inasafe-dev karena kesalahan ketika memanggil metode initGui()
Traceback (most recent call last):
File "C:/PROGRA~2/Quantum GIS Lisboa/apps/qgis/./python\qgis\utils.py", line 173, in startPlugin
plugins[packageName].initGui()
File "C:/Users/user/.qgis//python/plugins\inasafe-dev\safe_qgis\plugin.py", line 250, in initGui
self.dockWidget = Dock(self.iface)
File "C:\Users\user\.qgis\python\plugins\inasafe-dev\safe_qgis\dock.py", line 122, in __init__
myLongVersion = get_version()
File "C:\Users\user\.qgis\python\plugins\inasafe-dev\safe\common\version.py", line 44, in get_version
Terjadi kesalahan ketika menjalankan kode Python:
Traceback (most recent call last):
File "C:\Users\user\.qgis\python\plugins\inasafe-dev\safe_qgis\dock.py", line 1003, in accept
'AGGR_ATTR_KEY']: myAttrName})
File "C:\Users\user\.qgis\python\plugins\inasafe-dev\safe_qgis\keyword_io.py", line 144, in appendKeywords
myKeywords = self.readKeywords(theLayer)
File "C:\Users\user\.qgis\python\plugins\inasafe-dev\safe_qgis\keyword_io.py", line 99, in readKeywords
myKeywords = self.readKeywordFromUri(mySource, theKeyword)
File "C:\Users\user\.qgis\python\plugins\inasafe-dev\safe_qgis\keyword_io.py", line 529, in readKeywordFromUri
def unload_safe_modules():
"""Unload all safe modules that has been loaded.
"""
safe_modules = []
myregex =r'(^|\.)(safe|safe_qgis)(\.|$)'
for mod in sys.modules:
if re.match(myregex, mod):
safe_modules.append(mod)
for mod in safe_modules:
"C:\Program Files (x86)\Quantum GIS Lisboa\bin\python.exe" "C:\Program Files (x86)\JetBrains\PyCharm 2.6.2\helpers\pycharm\utrunner.py" C:/Users/user/.qgis/python/plugins/inasafe-dev/safe_qgis/test_dock.py::DockTest::test_runVolcanoCirclePopulation true
Testing started at 12:54 ...
No handlers could be found for logger "InaSAFE"
d:\src\qgis-1.8.0\src\core\qgsproviderregistry.cpp(86) : (QgsProviderRegistry::QgsProviderRegistry) Checking C:/Program Files (x86)/Quantum GIS Lisboa/apps/qgis/plugins for provider plugins
d:\src\qgis-1.8.0\src\core\qgsproviderregistry.cpp(219) : (QgsProviderRegistry::QgsProviderRegistry) Checking C:/Program Files (x86)/Quantum GIS Lisboa/apps/qgis/plugins/coordinatecaptureplugin.dll : ..invalid (no type)
d:\src\qgis-1.8.0\src\core\qgsproviderregistry.cpp(219) : (QgsProviderRegistry::QgsProviderRegistry) Checking C:/Program Files (x86)/Quantum GIS Lisboa/apps/qgis/plugins/delimitedtextplugin.dll : ..invalid (no type)
d:\src\qgis-1.8.0\src\core\qgsproviderregistry.cpp(219) : (QgsPro
@ismailsunni
ismailsunni / gist:5418717
Created April 19, 2013 07:33
Error Inasafe 1.2
Couldn't load plugin inasafe due an error when calling its classFactory() method
Traceback (most recent call last):
File "/usr/lib/python2.7/dist-packages/qgis/utils.py", line 164, in startPlugin
plugins[packageName] = package.classFactory(iface)
File "/home/riangga/.qgis//python/plugins/inasafe/__init__.py", line 72, in classFactory
from safe_qgis.plugin import Plugin
File "/usr/lib/python2.7/dist-packages/qgis/utils.py", line 309, in _import
mod = _builtin_import(name, globals, locals, fromlist, level)
File "/home/riangga/.qgis//python/plugins/inasafe/safe_qgis/__init__.py", line 8, in
Couldn't load plugin processing due an error when calling its classFactory() method
Traceback (most recent call last):
File "/usr/lib/python2.7/dist-packages/qgis/utils.py", line 204, in startPlugin
plugins[packageName] = package.classFactory(iface)
File "/usr/share/qgis/python/plugins/processing/__init__.py", line 33, in classFactory
return ProcessingPlugin(iface)
File "/usr/share/qgis/python/plugins/processing/ProcessingPlugin.py", line 53, in __init__
Processing.initialize()
File "/usr/share/qgis/python/plugins/processing/core/Processing.py", line 136, in initialize