Monday 24 October 2011

FWS-ore categories/taxonomy

The categories (classification taxonomy) for FWS-ore were arrived at after consideration of the American Library of Congress Classification including, but not exclusively:
B- Philosophy. Psychology. Religion
G- Geography. Anthropolgy. Recreation
H- Social Sciences
J- Political Science
K- Law
L- Education
Q- Science
R- Medicine
S- Agriculture
T- Technology
The categories chosen reflect the top-level descriptors for the main drivers and effects of Food & Water insecurity. It is expected that this initial taxonomy will evolve as more papers are added to the FWS-ore archive.

Tuesday 18 October 2011

Documenting how fws/xPapers works.

Unfortunately the documentation to xPapers is somewhat lacking. There is only an installation manual, the code is reasonably well commented but there is nothing to explain how everything fits together. Over the last few weeks we've been gradually working this out ourselves. To help anyone else who might use xPapers (and future employees on this project) we've begun to document what each file/directory does on our wiki at https://github.com/fws-hub/xPapers/wiki/File-Descriptions.

Friday 14 October 2011

Getting rid of "defined(%hash) is deprecated" warnings.

We've been getting the warning message:

defined(%hash) is deprecated at /home/xpapers/lib/Rose/DBx/Object/Cached/FastMmap.pm line 334.
(Maybe you should just omit the defined()?)


from a lot of the cron jobs in xpapers, this had been generating hundreds of emails per day and burying real errors. It turns out just by changing line 334 in FastMmap.pm from:

(defined %$SETTINGS ? %$SETTINGS : ()),

to

%$SETTINGS ? %$SETTINGS : (),

seems to fix it. I've not had any errors so far suggesting that this was incorrect.

Friday 7 October 2011

getting bibliography imports working

We have been having trouble with bibliography imports in xpapers. After trying to upload a bibtex bibliography we found that the page just hung saying it was initializing. After a lot of debugging this was found to be due to 2 reasons:

  1. Bibutils which came precompiled with xpapers didn't work on our system. This was supposed to be compiled for an x86_64 architecutre (which I thought we were using). Perhaps it was a Gentoo/Debian incompatibility or a libc incompatibility. Anyway recompiling bibutils fixed this one.
  2. Line 98 of assets/mason/utils/process_batch.pl incorrectly referenced /home/xpapers/var/log/batch.log, the logs directory is var/logs not var/log. Having this spelt wrong broke the submission process.

Discussions now appearing!

We have been posting discussions and although we could see them in the database they weren't appearing on the website. I suspected this was a problem with sphinx not indexing them correctly. Then we found that the MySQL password had been changed but not updated in /usr/local/sphinx/etc/sphinx.conf.

However, restarting Sphinx still did not fix the problem and Sphinx complained with several warnings similar to

precaching index 'forums_idx'
WARNING: index 'forums_idx': '/home/xpapers/etc/wordforms.txt' differs from the original

Then I re-read the documentation! Although we had set up cron jobs the example provided does not include re-indexing Sphinx so it's necessary to run the following from time to time.

$SPHINX/bin/indexer --all --rotate

Now the discussions are appearing and seem to be working fine.

Thursday 6 October 2011

finally got some papers to appear

We've been having a problem with xPapers ever since we installed it with none of the content actually showing up. We can add papers manually or have them harvested from an OAI repository, we can see those entries in the database, but can't actually view them under the search, "New Items", "Browse by Area" or "Browse Journals". The only way to find content was to go to the "Submit Material" menu and choose "Archives we Track" and then view the list of papers that had come from a particular archive or by seeing recently added content in the admin panel.

It turns out that by default the search and browsing options have a button ticked saying "professional authors only". This default can be disabled by running the following SQL statement in mysql command line:

UPDATE queries SET proOnly='0' WHERE id='1';

I've not yet worked out how you mark added content as being from a professional author, but at least we can now view some papers!