Re: [Arches] Failed Initial Migration for Models

2016-08-22 Thread Sajan Maharjan
Hello Alexei

First of all thanks for pointing out my mistake but i couldnt find any of 
this information in any of the documentation.

That certainly solved the problem for the models migration. And i no longer 
see a need for migrations,

But I am back to the same error I had earlier, for which I felt I needed to 
migrate.

In the page: http://localhost:8000/search
relation "dates" does not exist
LINE 1: ...AS "val__max", MIN("dates"."val") AS "val__min" FROM "dates"

In the page: http://localhost:8000/map
TypeError at /resources/markers/all
'NoneType' object has no attribute '__getitem__'

Clearly It states that the database hasnt been loaded with data. I have 
looked into other posts here in this group.
I looked into this post in the group, which tries to solve the issue.
https://groups.google.com/forum/#!topic/archesproject/7I0U9zYZX-U

But running the suggested command 'python manage.py packages -o install' 
gives the following error

(ENV)sajan@ubuntu:~/arches-stable$ python manage.py packages -o install
operation: install
Traceback (most recent call last):
  File "manage.py", line 27, in 
execute_from_command_line(sys.argv)
  File 
"/home/sajan/arches-stable/ENV/local/lib/python2.7/site-packages/django/core/management/__init__.py",
 
line 399, in execute_from_command_line
utility.execute()
  File 
"/home/sajan/arches-stable/ENV/local/lib/python2.7/site-packages/django/core/management/__init__.py",
 
line 392, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
  File 
"/home/sajan/arches-stable/ENV/local/lib/python2.7/site-packages/django/core/management/base.py",
 
line 242, in run_from_argv
self.execute(*args, **options.__dict__)
  File 
"/home/sajan/arches-stable/ENV/local/lib/python2.7/site-packages/django/core/management/base.py",
 
line 285, in execute
output = self.handle(*args, **options)
  File "/home/sajan/arches-stable/arches/management/commands/packages.py", 
line 66, in handle
package_name = settings.PACKAGE_NAME
  File 
"/home/sajan/arches-stable/ENV/local/lib/python2.7/site-packages/django/conf/__init__.py",
 
line 55, in __getattr__
return getattr(self._wrapped, name)
AttributeError: 'Settings' object has no attribute 'PACKAGE_NAME'

Any advice on how to resolve the issue?

-- 
-- To post, send email to archesproject@googlegroups.com. To unsubscribe, send 
email to archesproject+unsubscr...@googlegroups.com. For more information, 
visit https://groups.google.com/d/forum/archesproject?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Arches Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to archesproject+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[Arches] Failed Initial Migration for Models

2016-08-20 Thread Sajan Maharjan
Here is the initial log for migration for models.

The migration contains a field type 'jsonb' which is only supported by 
PostgreSQL 9.4, but ours runs on 9.3. Is there any solution for this? The 
system is running fine for now but we are missing the models migrations.

(ENV)sajan@ubuntu:~/arches-master$ python manage.py migrate models
Operations to perform:
  Apply all migrations: models
Running migrations:
  Rendering model states... DONE
  Applying models.0001_initial...Traceback (most recent call last):
  File "manage.py", line 27, in 
execute_from_command_line(sys.argv)
  File 
"/home/sajan/arches-master/ENV/local/lib/python2.7/site-packages/django/core/management/__init__.py",
 
line 367, in execute_from_command_line
utility.execute()
  File 
"/home/sajan/arches-master/ENV/local/lib/python2.7/site-packages/django/core/management/__init__.py",
 
line 359, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
  File 
"/home/sajan/arches-master/ENV/local/lib/python2.7/site-packages/django/core/management/base.py",
 
line 305, in run_from_argv
self.execute(*args, **cmd_options)
  File 
"/home/sajan/arches-master/ENV/local/lib/python2.7/site-packages/django/core/management/base.py",
 
line 356, in execute
output = self.handle(*args, **options)
  File 
"/home/sajan/arches-master/ENV/local/lib/python2.7/site-packages/django/core/management/commands/migrate.py",
 
line 202, in handle
targets, plan, fake=fake, fake_initial=fake_initial
  File 
"/home/sajan/arches-master/ENV/local/lib/python2.7/site-packages/django/db/migrations/executor.py",
 
line 97, in migrate
state = self._migrate_all_forwards(plan, full_plan, fake=fake, 
fake_initial=fake_initial)
  File 
"/home/sajan/arches-master/ENV/local/lib/python2.7/site-packages/django/db/migrations/executor.py",
 
line 132, in _migrate_all_forwards
state = self.apply_migration(state, migration, fake=fake, 
fake_initial=fake_initial)
  File 
"/home/sajan/arches-master/ENV/local/lib/python2.7/site-packages/django/db/migrations/executor.py",
 
line 237, in apply_migration
state = migration.apply(state, schema_editor)
  File 
"/home/sajan/arches-master/ENV/local/lib/python2.7/site-packages/django/db/migrations/migration.py",
 
line 129, in apply
operation.database_forwards(self.app_label, schema_editor, old_state, 
project_state)
  File 
"/home/sajan/arches-master/ENV/local/lib/python2.7/site-packages/django/db/migrations/operations/models.py",
 
line 96, in database_forwards
schema_editor.create_model(model)
  File 
"/home/sajan/arches-master/ENV/local/lib/python2.7/site-packages/django/contrib/gis/db/backends/postgis/schema.py",
 
line 56, in create_model
super(PostGISSchemaEditor, self).create_model(model)
  File 
"/home/sajan/arches-master/ENV/local/lib/python2.7/site-packages/django/db/backends/base/schema.py",
 
line 295, in create_model
self.execute(sql, params or None)
  File 
"/home/sajan/arches-master/ENV/local/lib/python2.7/site-packages/django/db/backends/base/schema.py",
 
line 112, in execute
cursor.execute(sql, params)
  File 
"/home/sajan/arches-master/ENV/local/lib/python2.7/site-packages/django/db/backends/utils.py",
 
line 79, in execute
return super(CursorDebugWrapper, self).execute(sql, params)
  File 
"/home/sajan/arches-master/ENV/local/lib/python2.7/site-packages/django/db/backends/utils.py",
 
line 64, in execute
return self.cursor.execute(sql, params)
  File 
"/home/sajan/arches-master/ENV/local/lib/python2.7/site-packages/django/db/utils.py",
 
line 94, in __exit__
six.reraise(dj_exc_type, dj_exc_value, traceback)
  File 
"/home/sajan/arches-master/ENV/local/lib/python2.7/site-packages/django/db/backends/utils.py",
 
line 62, in execute
return self.cursor.execute(sql)
django.db.utils.ProgrammingError: type "jsonb" does not exist
LINE 1: ...OT NULL, "id" uuid NOT NULL PRIMARY KEY, "config" jsonb NULL...
 ^

(ENV)sajan@ubuntu:~/arches-master$ 


-- 
-- To post, send email to archesproject@googlegroups.com. To unsubscribe, send 
email to archesproject+unsubscr...@googlegroups.com. For more information, 
visit https://groups.google.com/d/forum/archesproject?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Arches Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to archesproject+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[Arches] Re: undefined symbol: GEOSDelaunayTriangulation_r

2016-08-17 Thread Sajan Maharjan

>
> Refer to this site and reinstall GEOS
>
https://docs.djangoproject.com/en/1.10/ref/contrib/gis/install/geolibs/#geos 

and in the end do

$ sudo make install
$ sudo ldconfig

 
>

-- 
-- To post, send email to archesproject@googlegroups.com. To unsubscribe, send 
email to archesproject+unsubscr...@googlegroups.com. For more information, 
visit https://groups.google.com/d/forum/archesproject?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Arches Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to archesproject+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[Arches] Cannot Start Arch

2016-08-17 Thread Sajan Maharjan
I have tried many things, but still havent managed to start Arches. Any 
help would be great

Using Ubuntu 14 x64

sajan@ubuntu:~$ cd Projects/
sajan@ubuntu:~/Projects$ source ENV/bin/activate
(ENV)sajan@ubuntu:~/Projects$ python manage.py runserver
Unhandled exception in thread started by 
Traceback (most recent call last):
  File 
"/home/sajan/Projects/ENV/local/lib/python2.7/site-packages/django/utils/autoreload.py",
 
line 226, in wrapper
fn(*args, **kwargs)
  File 
"/home/sajan/Projects/ENV/local/lib/python2.7/site-packages/django/core/management/commands/runserver.py",
 
line 113, in inner_run
autoreload.raise_last_exception()
  File 
"/home/sajan/Projects/ENV/local/lib/python2.7/site-packages/django/utils/autoreload.py",
 
line 249, in raise_last_exception
six.reraise(*_exception)
  File 
"/home/sajan/Projects/ENV/local/lib/python2.7/site-packages/django/utils/autoreload.py",
 
line 226, in wrapper
fn(*args, **kwargs)
  File 
"/home/sajan/Projects/ENV/local/lib/python2.7/site-packages/django/__init__.py",
 
line 27, in setup
apps.populate(settings.INSTALLED_APPS)
  File 
"/home/sajan/Projects/ENV/local/lib/python2.7/site-packages/django/apps/registry.py",
 
line 108, in populate
app_config.import_models(all_models)
  File 
"/home/sajan/Projects/ENV/local/lib/python2.7/site-packages/django/apps/config.py",
 
line 199, in import_models
self.models_module = import_module(models_module_name)
  File "/usr/lib/python2.7/importlib/__init__.py", line 37, in import_module
__import__(name)
  File 
"/home/sajan/Projects/ENV/local/lib/python2.7/site-packages/django/contrib/auth/models.py",
 
line 4, in 
from django.contrib.auth.base_user import AbstractBaseUser, 
BaseUserManager
  File 
"/home/sajan/Projects/ENV/local/lib/python2.7/site-packages/django/contrib/auth/base_user.py",
 
line 52, in 
class AbstractBaseUser(models.Model):
  File 
"/home/sajan/Projects/ENV/local/lib/python2.7/site-packages/django/db/models/base.py",
 
line 119, in __new__
new_class.add_to_class('_meta', Options(meta, app_label))
  File 
"/home/sajan/Projects/ENV/local/lib/python2.7/site-packages/django/db/models/base.py",
 
line 316, in add_to_class
value.contribute_to_class(cls, name)
  File 
"/home/sajan/Projects/ENV/local/lib/python2.7/site-packages/django/db/models/options.py",
 
line 214, in contribute_to_class
self.db_table = truncate_name(self.db_table, 
connection.ops.max_name_length())
  File 
"/home/sajan/Projects/ENV/local/lib/python2.7/site-packages/django/db/__init__.py",
 
line 36, in __getattr__
return getattr(connections[DEFAULT_DB_ALIAS], item)
  File 
"/home/sajan/Projects/ENV/local/lib/python2.7/site-packages/django/db/utils.py",
 
line 211, in __getitem__
backend = load_backend(db['ENGINE'])
  File 
"/home/sajan/Projects/ENV/local/lib/python2.7/site-packages/django/db/utils.py",
 
line 115, in load_backend
return import_module('%s.base' % backend_name)
  File "/usr/lib/python2.7/importlib/__init__.py", line 37, in import_module
__import__(name)
  File 
"/home/sajan/Projects/ENV/local/lib/python2.7/site-packages/django/contrib/gis/db/backends/postgis/base.py",
 
line 5, in 
from .features import DatabaseFeatures
  File 
"/home/sajan/Projects/ENV/local/lib/python2.7/site-packages/django/contrib/gis/db/backends/postgis/features.py",
 
line 1, in 
from django.contrib.gis.db.backends.base.features import 
BaseSpatialFeatures
  File 
"/home/sajan/Projects/ENV/local/lib/python2.7/site-packages/django/contrib/gis/db/backends/base/features.py",
 
line 4, in 
from django.contrib.gis.db.models import aggregates
  File 
"/home/sajan/Projects/ENV/local/lib/python2.7/site-packages/django/contrib/gis/db/models/__init__.py",
 
line 2, in 
from django.contrib.gis.db.models.aggregates import *  # NOQA
  File 
"/home/sajan/Projects/ENV/local/lib/python2.7/site-packages/django/contrib/gis/db/models/aggregates.py",
 
line 1, in 
from django.contrib.gis.db.models.fields import ExtentField
  File 
"/home/sajan/Projects/ENV/local/lib/python2.7/site-packages/django/contrib/gis/db/models/fields.py",
 
line 1, in 
from django.contrib.gis import forms
  File 
"/home/sajan/Projects/ENV/local/lib/python2.7/site-packages/django/contrib/gis/forms/__init__.py",
 
line 3, in 
from .fields import (  # NOQA
  File 
"/home/sajan/Projects/ENV/local/lib/python2.7/site-packages/django/contrib/gis/forms/fields.py",
 
line 4, in 
from django.contrib.gis.geos import GEOSException, GEOSGeometry
  File 
"/home/sajan/Projects/ENV/local/lib/python2.7/site-packages/django/contrib/gis/geos/__init__.py",
 
line 5, in 
from .collections import (  # NOQA
  File 
"/home/sajan/Projects/ENV/local/lib/python2.7/site-packages/django/contrib/gis/geos/collections.py",
 
line 11, in 
from django.contrib.gis.geos.geometry import GEOSGeometry, 
LinearGeometryMixin
  File 
"/home/sajan/Projects/ENV/local/lib/python2.7/site-packages/django/contrib/gis/geos/geometry.py",