[GeoNode-devel] developer setup
Simone Dalmasso
simone.dalmasso at gmail.com
Fri Jun 17 07:58:44 PDT 2016
syncdb should be deprecated and removed in 1.9 if I'm not wrong. in favour
of migrate
2016-06-17 16:56 GMT+02:00 Paolo Corti <pcorti at gmail.com>:
> Actually it was my fault. I had a local_settings.pyc file still in the
> directory which caused confusion.
> No need to migrate auth (how could be that done if the database is not
> existing?), just running syncdb works well.
>
> Any reason not to run syncdb in paver setup as it was done once?
>
> cheers
> p
>
> On Fri, Jun 17, 2016 at 10:43 AM, Ariel Nunez <ingenieroariel at gmail.com>
> wrote:
> > Paolo, the way to do it is to first do a migrate auth and after that you
> can
> > do a regular syncdb.
> >
> > python manage.py migrate auth
> > python manage.py syncdb
> >
> > Not sure if that can be avoided - it seems a bit weird to me that a
> regular
> > syncdb would not work.
> >
> > -a
> >
> > On Fri, Jun 17, 2016 at 9:40 AM, Paolo Corti <pcorti at gmail.com> wrote:
> >>
> >> It seems that from Django 1.8 it is needed to run migrate with the
> >> --fake-initial settings
> >>
> >> (
> http://stackoverflow.com/questions/29760817/how-can-i-resolve-django-content-type-already-exists
> )
> >>
> >> Though, I am now getting a different error:
> >>
> >> Applying layers.0001_initial...Traceback (most recent call last):
> >> ...
> >> django.db.utils.ProgrammingError: relation "layers_attribute" already
> >> exists
> >>
> >> p
> >>
> >> On Fri, Jun 17, 2016 at 10:34 AM, Paolo Corti <pcorti at gmail.com> wrote:
> >> > Hi developers
> >> >
> >> > I am trying to install geonode from master (I haven't done this since
> >> > 2.4 was released). I am wondering which is the way to setup a
> >> > developer geonode instance.
> >> >
> >> > Once it was possible, following this instructions [1], to generate an
> >> > environment using paver setup, which was taking care of the database
> >> > initial sync.
> >> > Now setup just set geoserver.
> >> >
> >> > If I try to create the database, I get this error:
> >> >
> >> > Applying contenttypes.0001_initial...Traceback (most recent call
> >> > last):
> >> >
> >> > File "./manage.py", line 29, in <module>
> >> >
> >> > execute_from_command_line(sys.argv)
> >> >
> >> > File
> >> >
> "/home/vagrant/geonode/geonode/env/local/lib/python2.7/site-packages/django/core/management/__init__.py",
> >> > line 354, in execute_from_command_line
> >> >
> >> > utility.execute()
> >> >
> >> > File
> >> >
> "/home/vagrant/geonode/geonode/env/local/lib/python2.7/site-packages/django/core/management/__init__.py",
> >> > line 346, in execute
> >> >
> >> > self.fetch_command(subcommand).run_from_argv(self.argv)
> >> >
> >> > File
> >> >
> "/home/vagrant/geonode/geonode/env/local/lib/python2.7/site-packages/django/core/management/base.py",
> >> > line 394, in run_from_argv
> >> >
> >> > self.execute(*args, **cmd_options)
> >> >
> >> > File
> >> >
> "/home/vagrant/geonode/geonode/env/local/lib/python2.7/site-packages/django/core/management/base.py",
> >> > line 445, in execute
> >> >
> >> > output = self.handle(*args, **options)
> >> >
> >> > File
> >> >
> "/home/vagrant/geonode/geonode/env/local/lib/python2.7/site-packages/django/core/management/commands/migrate.py",
> >> > line 222, in handle
> >> >
> >> > executor.migrate(targets, plan, fake=fake,
> >> > fake_initial=fake_initial)
> >> >
> >> > File
> >> >
> "/home/vagrant/geonode/geonode/env/local/lib/python2.7/site-packages/django/db/migrations/executor.py",
> >> > line 110, in migrate
> >> >
> >> > self.apply_migration(states[migration], migration, fake=fake,
> >> > fake_initial=fake_initial)
> >> >
> >> > File
> >> >
> "/home/vagrant/geonode/geonode/env/local/lib/python2.7/site-packages/django/db/migrations/executor.py",
> >> > line 148, in apply_migration
> >> >
> >> > state = migration.apply(state, schema_editor)
> >> >
> >> > File
> >> >
> "/home/vagrant/geonode/geonode/env/local/lib/python2.7/site-packages/django/db/migrations/migration.py",
> >> > line 115, in apply
> >> >
> >> > operation.database_forwards(self.app_label, schema_editor,
> >> > old_state, project_state)
> >> >
> >> > File
> >> >
> "/home/vagrant/geonode/geonode/env/local/lib/python2.7/site-packages/django/db/migrations/operations/models.py",
> >> > line 59, in database_forwards
> >> >
> >> > schema_editor.create_model(model)
> >> >
> >> > File
> >> >
> "/home/vagrant/geonode/geonode/env/local/lib/python2.7/site-packages/django/db/backends/base/schema.py",
> >> > line 286, in create_model
> >> >
> >> > self.execute(sql, params or None)
> >> >
> >> > File
> >> >
> "/home/vagrant/geonode/geonode/env/local/lib/python2.7/site-packages/django/db/backends/base/schema.py",
> >> > line 111, in execute
> >> >
> >> > cursor.execute(sql, params)
> >> >
> >> > File
> >> >
> "/home/vagrant/geonode/geonode/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/vagrant/geonode/geonode/env/local/lib/python2.7/site-packages/django/db/backends/utils.py",
> >> > line 64, in execute
> >> >
> >> > return self.cursor.execute(sql, params)
> >> >
> >> > File
> >> >
> "/home/vagrant/geonode/geonode/env/local/lib/python2.7/site-packages/django/db/utils.py",
> >> > line 98, in __exit__
> >> >
> >> > six.reraise(dj_exc_type, dj_exc_value, traceback)
> >> >
> >> > File
> >> >
> "/home/vagrant/geonode/geonode/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: relation "django_content_type"
> already
> >> > exists
> >> >
> >> >
> >> >
> >> > I believe it is also important to always keep documentation updated.
> >> > thanks
> >> > p
> >> >
> >> > [1] https://github.com/GeoNode/geonode
> >> >
> >> > --
> >> > Paolo Corti
> >> > Geospatial software developer
> >> > web: http://www.paolocorti.net
> >> > twitter: @capooti
> >> > skype: capooti
> >>
> >>
> >>
> >> --
> >> Paolo Corti
> >> Geospatial software developer
> >> web: http://www.paolocorti.net
> >> twitter: @capooti
> >> skype: capooti
> >> _______________________________________________
> >> geonode-devel mailing list
> >> geonode-devel at lists.osgeo.org
> >> http://lists.osgeo.org/mailman/listinfo/geonode-devel
> >
> >
>
>
>
> --
> Paolo Corti
> Geospatial software developer
> web: http://www.paolocorti.net
> twitter: @capooti
> skype: capooti
> _______________________________________________
> geonode-devel mailing list
> geonode-devel at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/geonode-devel
>
--
Simone
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/geonode-devel/attachments/20160617/935330e0/attachment.html>
More information about the geonode-devel
mailing list