arxiv.submission.services.classic.log module

Interface to the classic admin log.

arxiv.submission.services.classic.log.ON_EVENT = {<class 'arxiv.submission.domain.event.UnFinalizeSubmission'>: [<function log_unfinalize>], <class 'arxiv.submission.domain.event.proposal.AcceptProposal'>: [<function log_accept_system_cross>], <class 'arxiv.submission.domain.event.flag.AddContentFlag'>: [<function log_stopwords>]}

Logging functions to call when an event is comitted.

arxiv.submission.services.classic.log.admin_log(program, command, text, notify=False, username=None, hostname=None, submission_id=None, paper_id=None, document_id=None)[source]

Add an entry to the admin log.

Parameters
  • program (str) – Name of the application generating the log entry.

  • command (str) – Name of the command generating the log entry.

  • text (str) – Content of the admin log entry.

  • notify (bool) –

  • username (str) –

  • hostname (str) – Hostname or IP address of the client.

  • submission_id (int) –

  • paper_id (str) –

  • document_id (int) –

Return type

AdminLogEntry

arxiv.submission.services.classic.log.handle(event, before, after)[source]

Generate an admin log entry for an event that is being committed.

Looks for a logging function in ON_EVENT and, if found, calls it with the passed parameters.

Parameters
Return type

None

arxiv.submission.services.classic.log.log_accept_system_cross(event, before, after)[source]

Create a log entry when a system cross is accepted.

Return type

None

arxiv.submission.services.classic.log.log_classifier_failed(event, before, after)[source]

Create a log entry when the classifier returns no suggestions.

Return type

None

arxiv.submission.services.classic.log.log_stopwords(event, before, after)[source]

Create a log entry when there is a problem with stopword content.

Return type

None

arxiv.submission.services.classic.log.log_unfinalize(event, before, after)[source]

Create a log entry when a user pulls their submission for changes.

Return type

None