Initial Commit
BibUpload: smart record uploader

* Enhances write_message() function to allow for lazy printing of messages.
  When calling write_message(msg), msg can now be a callable, that is
  executed only if the necessary verbosity level is reached (thus
  allowing printing detailed information without performance penalties).

BibRecord: new identical_records() API

* Adds a new identical_records() API function, that allow to
  compare for identity two records, without considering the 005
  MARC tag (i.e. their modification timestamp).

BibUpload: smart record uploader

* Adds bibupload_revisionverifier submodule to compare the submitted record
  revision information (stored in MARC tag 005) against the list of
  known archived revisions of the record, in order to generate a record patch.
  (Useful when cataloguer modifies an older version of a record while another
  cataloguer touches the record in question, because revision verification
  step will now merge the two wanted changes together).  As a side effect,
  the --replace mode of bibupload will be always changed to --correct mode with
  the wanted record patch. In case of conflicting needs (when two users
  modified the same fields), the bibupload ends with an error and submits the
  given modifications to the holding pen.
  (closes #816) (closes #864)

* Implements field deletion in bibupload based on DELETE_CODE and DELETE_VALUE
  set for the field.
  (closes #897)

* Updates DB only for those elements that are modified in the
  submitted version.

* Drops support for not documented (and no longer used) FMT tags.

* Deprecates support for --reference/-z in favor of --correct/-c.

Co-authored-by: Samuele Kaplun <samuele.kaplun@cern.ch>

BibUpload: bibrec timestamp bug

* In 70f76183f018c1a3bb7313c39b6a4ce8e5e908a4 bibupload was modified
  to store as record modification time the initial timestamp of when the
  modification began, rather than the latest timestamp of when modification
  finished (as it was before this patch).
  This might lead to all sorts of malfunctions if tasks such as bibindex,
  bibrank, refextract, bibauthorid, etc. are run at the same time of
  a bibupload. This commit partially reverts this behaviour by indeed
  storing only the very latest timestamp into the bibrec table (so
  that other bibtasks are not missing the update).
  (fixes #1431)

BibUpload: sensible history and other goodies

* Drops support for not documented and unbound option opt_tag.

* Drops support for unused (and complicating) CLI --stage option.

* Stores history only if a record is really modified. Includes
  a migration kit to remove useless history entries.
  (references #498) (closes #1250)

* Take use of new write_message lazy mode, that allows computing
  strings to print, only if verbosity level is reached.

* Introduce new CFG_BIBUPLOAD_DISABLE_RECORD_REVISIONS flag
  to control whether it is desired to optionally disable keep
  track of record revisions in a history table (e.g. in case
  record updates are all coming from an external system which
  already keeps track of history).
  (closes #871)

* Minimize that handling of fulltextes to when the incoming record
  refers to 8564 tags or contain FFT tags.

* Since the 005 timestamp granularity is of the order of seconds,
  properly introduces sleeping points of 1 second, in case a record
  is modified a second time within the same second.

* Removes try..except: clauses that were capturing all exception
  and just logged them as warning.

* Additionally takes care of properly update record timestamp only
  if there was really a metadata update or at least one FFT tag.

x

BibUpload: BibCatalog connection

* When BibUpload can't automatically resolve a given revision conflict
  it is putting the modification in the Holding Pen. At the same time
  now a ticket is created in BibCatalog to be able to refer to it.

Conflicts:
	modules/bibupload/lib/bibupload.py
	modules/bibupload/lib/bibupload_config.py
	modules/bibupload/lib/bibupload_regression_tests.py

Conflicts:
	modules/bibupload/lib/bibupload.py
	po/ar.po
	po/bg.po
	po/hr.po
OAIRepository: no bibupload -n

* When scheduling bibuploads to add/update OAI information, remove
  the -n option, which would otherwise lead to certain records not
  been exported during incremental harvesting.
BibAuthorID: fixed bug in authorpage

* a query of the kind CFG_SITE/author/somename?recid=somerecid redirects to the person
  search instead of landing on the author profile.
* changed the autogenerated subject in the HepNames box mail-request to include the author's
  canonical name and HepNames recid.
OPS: deprecated correctly bibupload --stage/-s
intbitset: union() and isdisjoint() support

* Adds support for new union() and isdisjoint() set methods.

* Updates intbitset interface to look like set built-in in Python 2.6.

* Supports initialization of an intbitset from a set.
RefExtract: Moved arXiv BibFilter logic into RefExtract (extract_journal_reference)
DocExtract: Bug fixing journal reference extraction
DocExtract: RefExtract fixes applied after review (minor fixes)