[ckan-dev] ckan-dev Digest, Vol 43, Issue 69

CKAN UGIS ckan.ugis at gmail.com
Thu Jun 26 11:33:36 UTC 2014


Thanks Nigel, I totally forgot to enter superuser mode before entering
vitrual environment. I guess I'm new to this virtualenv thingy.

P.S. I hope I replied correctly. Still trying to figure out these mailing
lists..



2014-05-20 7:48 GMT+04:00 <ckan-dev-request at lists.okfn.org>:

> Send ckan-dev mailing list submissions to
>         ckan-dev at lists.okfn.org
>
> To subscribe or unsubscribe via the World Wide Web, visit
>         https://lists.okfn.org/mailman/listinfo/ckan-dev
> or, via email, send a message with subject or body 'help' to
>         ckan-dev-request at lists.okfn.org
>
> You can reach the person managing the list at
>         ckan-dev-owner at lists.okfn.org
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of ckan-dev digest..."
>
>
> Today's Topics:
>
>    1. Server error  with ckanext-usmetadata extension (Pandya, Pradip)
>    2. CKAN 2.0.3 ImportError: No module named fanstatic (CKAN UGIS)
>    3. Re: CKAN 2.0.3 ImportError: No module named fanstatic (Nigel Babu)
>
>
> ----------------------------------------------------------------------
>
> Message: 1
> Date: Mon, 19 May 2014 15:24:15 +0000
> From: "Pandya, Pradip" <Pradip.Pandya at nist.gov>
> To: "ckan-dev at lists.okfn.org" <ckan-dev at lists.okfn.org>
> Subject: [ckan-dev] Server error  with ckanext-usmetadata extension
> Message-ID:
>         <
> 450ab36b24804e4b901951a582ea1987 at BN1PR09MB123.namprd09.prod.outlook.com>
>
> Content-Type: text/plain; charset="us-ascii"
>
> Hi,
> We have installed the usmetadata extension from
> https://github.com/GSA/USMetadata and followed the installation
> instructions on a CKAN 2.2 instance. The new fields in the common core
> metadata from this extension are displayed fine after the Add Datasets is
> selected.  But we are getting an internal server error 500 when trying to
> add a dataset. All other functions appear to be working fine except adding
> the dataset.  The CKAN2.2, apache2 and postgresql running on the same
> server.
> Here is the ckan_default.error.log  displaying the error 'Error - <type
> 'exceptions.AttributeError'>: as below after attempting to add the dataset:
> [Fri May 16 09:31:41 2014] [error] 2014-05-16 09:31:41,301 DEBUG
> [ckanext.usmetadata.plugin] show_package_schema called
> [Fri May 16 09:31:41 2014] [error] 2014-05-16 09:31:41,319 CRITI
> [ckan.logic] Action `user_followee_list` is being called directly all
> action calls should be accessed via logic.get_action
> [Fri May 16 09:31:41 2014] [error] 2014-05-16 09:31:41,325 CRITI
> [ckan.logic] Action `dataset_followee_list` is being called directly all
> action calls should be accessed via logic.get_action
> [Fri May 16 09:31:41 2014] [error] 2014-05-16 09:31:41,332 CRITI
> [ckan.logic] Action `group_followee_list` is being called directly all
> action calls should be accessed via logic.get_action
> [Fri May 16 09:31:41 2014] [error] 2014-05-16 09:31:41,339 CRITI
> [ckan.logic] Action `dashboard_activity_list` is being called directly all
> action calls should be accessed via logic.get_action
> [Fri May 16 09:31:41 2014] [error] 2014-05-16 09:31:41,529 INFO
>  [ckan.lib.base]  /dashboard render time 0.710 seconds
> [Fri May 16 09:31:41 2014] [error] 2014-05-16 09:31:41,657 INFO
>  [ckan.lib.base]  /api/i18n/en render time 0.002 seconds
> [Fri May 16 09:31:44 2014] [error] 2014-05-16 09:31:44,790 INFO
>  [ckan.lib.base]  /dataset render time 0.335 seconds
> [Fri May 16 09:31:44 2014] [error] 2014-05-16 09:31:44,929 INFO
>  [ckan.lib.base]  /api/i18n/en render time 0.002 seconds
> [Fri May 16 09:31:49 2014] [error] 2014-05-16 09:31:49,233 DEBUG
> [ckanext.usmetadata.plugin] Expected key ['extras'] not found, attempting
> to move common core keys to subdictionary
> [Fri May 16 09:31:49 2014] [error] 2014-05-16 09:31:49,233 DEBUG
> [ckanext.usmetadata.plugin] common core metadata: ['title', 'notes',
> 'public_access_level', 'publisher', 'contact_name', 'contact_email',
> 'unique_id', 'data_dictionary', 'endpoint', 'spatial', 'temporal',
> 'bureau_code', 'program_code', 'access_level_comment', 'modified',
> 'release_date', 'accrual_periodicity', 'language', 'data_quality',
> 'category', 'related_documents', 'homepage_url', 'rss_feed',
> 'system_of_records', 'system_of_records_none_related_to_this_dataset',
> 'primary_it_investment_uii']
> [Fri May 16 09:31:49 2014] [error] 2014-05-16 09:31:49,233 DEBUG
> [ckanext.usmetadata.plugin] checking key: labels
> [Fri May 16 09:31:49 2014] [error] 2014-05-16 09:31:49,233 DEBUG
> [ckanext.usmetadata.plugin] checking key: group_id
> [Fri May 16 09:31:49 2014] [error] 2014-05-16 09:31:49,234 DEBUG
> [ckanext.usmetadata.plugin] checking key: common_core
> [Fri May 16 09:31:49 2014] [error] 2014-05-16 09:31:49,436 INFO
>  [ckan.lib.base]  /dataset/new render time 0.370 seconds
> [Fri May 16 09:31:49 2014] [error] 2014-05-16 09:31:49,572 INFO
>  [ckan.lib.base]  /api/i18n/en render time 0.001 seconds
> [Fri May 16 09:32:42 2014] [error] 2014-05-16 09:32:42,282 DEBUG
> [ckanext.usmetadata.plugin] _create_package_schema called
> [Fri May 16 09:32:42 2014] [error] [client 127.0.0.1] Error - <type
> 'exceptions.AttributeError'>: 'Missing' object has no attribute 'strip'
> [Fri May 16 09:32:42 2014] [error] 2014-05-16 09:32:42,488 INFO
>  [ckan.lib.base]  /dataset/new render time 0.060 seconds
> [Fri May 16 09:32:42 2014] [error] 2014-05-16 09:32:42,595 INFO
>  [ckan.lib.base]  /api/i18n/en render time 0.001 seconds
>
> There is no issue in adding a dataset if we revert back to the original
> CKAN metadata schema after removing the 'usmetadata' from the
> "ckan.plugins" in the .ini  file.
> Any suggestions?
> Thanks,
> Pradip
>
>
>
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL: <
> https://lists.okfn.org/pipermail/ckan-dev/attachments/20140519/ffbdffcc/attachment-0001.html
> >
>
> ------------------------------
>
> Message: 2
> Date: Tue, 20 May 2014 00:45:00 +0400
> From: CKAN UGIS <ckan.ugis at gmail.com>
> To: ckan-dev at lists.okfn.org
> Subject: [ckan-dev] CKAN 2.0.3 ImportError: No module named fanstatic
> Message-ID:
>         <CAB8Ors5EqgVhj3x5T0LxpLxRXj-TixBKT5f2Nfa=
> Xegvf+ZBww at mail.gmail.com>
> Content-Type: text/plain; charset="utf-8"
>
> Hello,
>
> I'm now a maintainer of CKAN 2.0.3 instance. I didn't install it, but it
> looks like it's been installed from package.
>
> I'm trying to upgrade to 2.2, but I'm getting an ImportError when I try to
> make a database dump. The weird thing is that pip freeze shows that
> fanstatic is installed.
>
> Here's what I did:
>
> student at CKAN:~$ . /usr/lib/ckan/default/bin/activate
> (default)student at CKAN:~$ cd /usr/lib/ckan/default/src/ckan
> (default)student at CKAN:/usr/lib/ckan/default/src/ckan$ sudo paster db dump
> --config=/etc/ckan/default/production.ini ugis_ckan_database.pg_dump
> sudo: unable to resolve host CKAN
> [sudo] password for student:
> Traceback (most recent call last):
>   File "/usr/bin/paster", line 4, in <module>
>     command.run()
>   File "/usr/lib/python2.7/dist-packages/paste/script/command.py", line
> 103, in run
>     command = commands[command_name].load()
>   File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 1989, in
> load
>     entry = __import__(self.module_name, globals(),globals(), ['__name__'])
>   File "/usr/lib/ckan/default/src/ckan/ckan/lib/cli.py", line 10, in
> <module>
>     import ckan.lib.fanstatic_resources as fanstatic_resources
>   File "/usr/lib/ckan/default/src/ckan/ckan/lib/fanstatic_resources.py",
> line 6, in <module>
>     from fanstatic import Library, Resource, Group, get_library_registry
> ImportError: No module named fanstatic
> (default)student at CKAN:/usr/lib/ckan/default/src/ckan$ pip freeze
> Babel==0.9.6
> Beaker==1.6.4
> FormAlchemy==1.4.2
> FormEncode==1.2.6
> Genshi==0.6
> Jinja2==2.6
> Mako==0.9.0
> MarkupSafe==0.15
> Pairtree==0.7.1-T
> Paste==1.7.5.1
> PasteDeploy==1.5.0
> PasteScript==1.7.5
> Pygments==1.6
> Pylons==0.9.7
> Routes==1.13
> SQLAlchemy==0.7.8
> Tempita==0.5.1
> WebError==0.10.3
> WebHelpers==1.3
> WebOb==1.0.8
> WebTest==1.4.3
> apachemiddleware==0.1.1
> argparse==1.2.1
> -e git+
>
> https://github.com/okfn/ckan@b58fcc9b0474d71d33b840897e417fdbc716c90a#egg=ckan-dev
> decorator==3.4.0
> distribute==0.6.24
> fanstatic==0.12
> nose==1.3.0
> ofs==0.4.1
> psycopg2==2.4.5
> python-dateutil==1.5
> python-openid==2.2.5
> pyutilib.component.core==4.5.3
> repoze.lru==0.6
> repoze.who==1.0.19
> repoze.who-friendlyform==1.0.8
> repoze.who.plugins.openid==0.5.3
> requests==1.1.0
> simplejson==3.3.1
> solrpy==0.9.5
> sqlalchemy-migrate==0.7.2
> vdm==0.11
> wsgiref==0.1.2
> zope.interface==4.0.1
>
> Can you give any hints on how to solve this?
>
> Thanks,
> Dmitry.
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL: <
> https://lists.okfn.org/pipermail/ckan-dev/attachments/20140520/2da711f4/attachment-0001.html
> >
>
> ------------------------------
>
> Message: 3
> Date: Tue, 20 May 2014 09:18:01 +0530
> From: Nigel Babu <nigel.babu at okfn.org>
> To: CKAN Development Discussions <ckan-dev at lists.okfn.org>
> Subject: Re: [ckan-dev] CKAN 2.0.3 ImportError: No module named
>         fanstatic
> Message-ID:
>         <
> CALGFUD4Srov6_42+Z3F+WKuSFzTmDu3JOAgH-ZvJvhY1tG8+HQ at mail.gmail.com>
> Content-Type: text/plain; charset="utf-8"
>
> When you call "sudo paster" from inside a virtualenv, you're actually not
> calling the right paster. What happens when you try
>
> sudo /usr/lib/ckan/default/bin/paster db dump
> --config=/etc/ckan/default/production.ini ugis_ckan_database.pg_dump
>
> Nigel Babu
> Developer, Open Knowledge
>
>
> On 20 May 2014 02:15, CKAN UGIS <ckan.ugis at gmail.com> wrote:
>
> > Hello,
> >
> > I'm now a maintainer of CKAN 2.0.3 instance. I didn't install it, but it
> > looks like it's been installed from package.
> >
> > I'm trying to upgrade to 2.2, but I'm getting an ImportError when I try
> to
> > make a database dump. The weird thing is that pip freeze shows that
> > fanstatic is installed.
> >
> > Here's what I did:
> >
> > student at CKAN:~$ . /usr/lib/ckan/default/bin/activate
> > (default)student at CKAN:~$ cd /usr/lib/ckan/default/src/ckan
> > (default)student at CKAN:/usr/lib/ckan/default/src/ckan$ sudo paster db
> dump
> > --config=/etc/ckan/default/production.ini ugis_ckan_database.pg_dump
> > sudo: unable to resolve host CKAN
> > [sudo] password for student:
> > Traceback (most recent call last):
> >   File "/usr/bin/paster", line 4, in <module>
> >     command.run()
> >   File "/usr/lib/python2.7/dist-packages/paste/script/command.py", line
> > 103, in run
> >     command = commands[command_name].load()
> >   File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 1989, in
> > load
> >     entry = __import__(self.module_name, globals(),globals(),
> ['__name__'])
> >   File "/usr/lib/ckan/default/src/ckan/ckan/lib/cli.py", line 10, in
> > <module>
> >     import ckan.lib.fanstatic_resources as fanstatic_resources
> >   File "/usr/lib/ckan/default/src/ckan/ckan/lib/fanstatic_resources.py",
> > line 6, in <module>
> >     from fanstatic import Library, Resource, Group, get_library_registry
> > ImportError: No module named fanstatic
> > (default)student at CKAN:/usr/lib/ckan/default/src/ckan$ pip freeze
> > Babel==0.9.6
> > Beaker==1.6.4
> > FormAlchemy==1.4.2
> > FormEncode==1.2.6
> > Genshi==0.6
> > Jinja2==2.6
> > Mako==0.9.0
> > MarkupSafe==0.15
> > Pairtree==0.7.1-T
> > Paste==1.7.5.1
> > PasteDeploy==1.5.0
> > PasteScript==1.7.5
> > Pygments==1.6
> > Pylons==0.9.7
> > Routes==1.13
> > SQLAlchemy==0.7.8
> > Tempita==0.5.1
> > WebError==0.10.3
> > WebHelpers==1.3
> > WebOb==1.0.8
> > WebTest==1.4.3
> > apachemiddleware==0.1.1
> > argparse==1.2.1
> > -e git+
> >
> https://github.com/okfn/ckan@b58fcc9b0474d71d33b840897e417fdbc716c90a#egg=ckan-dev
> > decorator==3.4.0
> > distribute==0.6.24
> > fanstatic==0.12
> > nose==1.3.0
> > ofs==0.4.1
> > psycopg2==2.4.5
> > python-dateutil==1.5
> > python-openid==2.2.5
> > pyutilib.component.core==4.5.3
> > repoze.lru==0.6
> > repoze.who==1.0.19
> > repoze.who-friendlyform==1.0.8
> > repoze.who.plugins.openid==0.5.3
> > requests==1.1.0
> > simplejson==3.3.1
> > solrpy==0.9.5
> > sqlalchemy-migrate==0.7.2
> > vdm==0.11
> > wsgiref==0.1.2
> > zope.interface==4.0.1
> >
> > Can you give any hints on how to solve this?
> >
> > Thanks,
> > Dmitry.
> >
> > _______________________________________________
> > ckan-dev mailing list
> > ckan-dev at lists.okfn.org
> > https://lists.okfn.org/mailman/listinfo/ckan-dev
> > Unsubscribe: https://lists.okfn.org/mailman/options/ckan-dev
> >
> >
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL: <
> https://lists.okfn.org/pipermail/ckan-dev/attachments/20140520/3bd8b8ba/attachment.html
> >
>
> ------------------------------
>
> Subject: Digest Footer
>
> _______________________________________________
> ckan-dev mailing list
> ckan-dev at lists.okfn.org
> https://lists.okfn.org/mailman/listinfo/ckan-dev
> Unsubscribe: https://lists.okfn.org/mailman/optionss/ckan-dev
>
>
> ------------------------------
>
> End of ckan-dev Digest, Vol 43, Issue 69
> ****************************************
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.okfn.org/pipermail/ckan-dev/attachments/20140626/7064d740/attachment-0002.html>


More information about the ckan-dev mailing list