UIUCLibrary / ea-pdf

Code for processing and archiving emails
Other
9 stars 2 forks source link

Error: The value 'UNKNOWN VERSION' is not a valid value for fo-processor-version param; allowed values must start with 'FOP' or 'XEP'. #11

Closed duckduckgrayduck closed 5 months ago

duckduckgrayduck commented 5 months ago

I have all of the dependencies set up on Linux, but receive the following error any time I try to run the tool on the following documents: https://drive.google.com/file/d/1L6BQF8waliJ4DP7Su5FEOWv_mcoO6WkC/view?usp=drive_link https://drive.google.com/file/d/11h4NB-TJ7ptVdtSDoGRxMgC-7Jl3Y-G-/view?usp=drive_link

fail: EaPdfCmd.EmailToEaPdfProcessor[0] Error: (name='check-params') The value 'UNKNOWN VERSION' is not a valid value for fo-processor-version param; allowed values must start with 'FOP' or 'XEP'. fail: EaPdfCmd.EmailToEaPdfProcessor[0] Error at xsl:text on line 68 column 16 of eaxs_to_fo.xsl: XTMM9000 Processing terminated by xsl:message at line 68 in eaxs_to_fo.xsl In template rule with match="/" on line 74 of eaxs_to_fo.xsl crit: EaPdfCmd.EmailToEaPdfProcessor[0] Processing terminated by xsl:message at line 68 in eaxs_to_fo.xsl

Here is my appsettings.json:

{ "Logging": { "LogLevel": { "Default": "Information" } },

"XsltProcessors": { "Default": "Saxon", // "Saxon" is currently the only supported XSLT processor "Saxon": { "ClassPath": "/home/s/Downloads/email archiver/saxon/saxon-he-11.5.jar" } },

"FoProcessors": { "Default": "FOP", // "Fop" or "Xep" "Fop": { "JarFilePath": "/home/s/Downloads/email archiver/fop.jar", "ConfigFilePath": "/home/s/Downloads/email archiver/ea-pdf/EaPdf/XResources/fop.xconf" }, "Xep": { "ClassPath": "/home/s/Downloads/email archiver/saxon/saxon-he-11.5.jar", "ConfigFilePath": "/home/s/Downloads/email archiver/ea-pdf/EaPdf/XResources/xep.xml" } },

"EmailToEaxsProcessorSettings": { "HashAlgorithmName": "SHA256", "SaveAttachmentsAndBinaryContentExternally": true, "WrapExternalContentInXml": false, //this must be true if the FO processor is XEP (really only if there are PDF attachments) "PreserveBinaryAttachmentTransferEncodingIfPossible": false, "PreserveTextAttachmentTransferEncoding": false, "IncludeSubFolders": false, "ExternalContentFolder": "ExtBodyContent", "OneFilePerMessageFile": false, "MaximumXmlFileSize": 0, //no limit "SaveTextAsXhtml": true, "LogToXmlThreshold": "Information", "DefaultFileExtension": ".mbox", "SkipUntilMessageId": null, "SkipAfterMessageId": null, "ExtraHtmlCharacterEntities": { "QUOT": 134 }, "ForceParse": false },

"EaxsToEaPdfProcessorSettings": { "XsltFoFilePath": "/home/s/Downloads/email archiver/ea-pdf/EaPdf/XResources/eaxs_to_fo.xsl", "XsltXmpFilePath": "/home/s/Downloads/email archiver/ea-pdf/EaPdf/XResources/eaxs_to_xmp.xsl", "XsltRootXmpFilePath": "/home/s/Downloads/email archiver/ea-pdf/EaPdf/XResources/eaxs_to_root_xmp.xsl",

/*
    Mapping of unicode language scripts to font families.  This is used to select the appropriate font family for a given script.  The font family names must exist in the FO processor's font configuration.
    The outer element name is an ISO 15924 4-letter codes for the script. A special entry with key 'default' should be in the dictionary with all three base font families specified. 
    This will be used as the default if a script entry is not found in the list.  Usually, this will be fonts with Latin or Western character sets, but could be fonts for a specific language.
    If a 'default' entry is not present, an entry for 'latn' (Latin) will be used as the default.  If neither 'default' nor 'latn' is found, the first alphabetical entry in the dictionary will be used 
    as the default which may produce unintended results.  Regardless of original order, the mappings are sorted alphabetically when loaded from the config file.

    The inner element name is the base font family, <Serif>, <SansSerif>, or <Monospace>; the first element is the default if no base font family is specified
    The value is a comma-separated list of font family names; these names must exist in the FO processor's font configuration
*/
"LanguageFontMapping": {
  "Default": { //This will be the default of no other entry matches the script
    "Serif": "serif",
    "SansSerif": "sans-serif",
    "Monospace": "monospace"
  },
  "Hebr": { //Hebrew
    "Serif": "serif",
    "SansSerif": "sans-serif",
    "Monospace": "monospace"
  },
  "Arab": { //Arabic
    "Serif": "Traditional Arabic,serif",
    "SansSerif": "Simplified Arabic,sans-serif",
    "Monospace": "Simplified Arabic Fixed,monospace"
  },
  "Hira": { //Hiragana (Japanese)
    "Serif": "Kurinto Text JP",
    "SansSerif": "Kurinto Sans JP",
    "Monospace": "Kurinto Mono JP"
  },
  "Kana": { // Katakana (Japanese)
    "Serif": "Kurinto Text JP",
    "SansSerif": "Kurinto Sans JP",
    "Monospace": "Kurinto Mono JP"
  },
  "Hrkt": { //Hiragana or Katakana (Japanese)
    "Serif": "Kurinto Text JP",
    "SansSerif": "Kurinto Sans JP",
    "Monospace": "Kurinto Mono JP"
  },
  "Hang": { //Hangul (Korean)
    "Serif": "Kurinto Text KR",
    "SansSerif": "Kurinto Sans KR",
    "Monospace": "Kurinto Mono KR"
  },
  "Hani": { //Han (Chinese: Simplified - SC, Traditional - TC, Hong Kong - HK, and Rare - CJK)
    "Serif": "Kurinto Text SC,Kurinto Text TC,Kurinto Text HK,Kurinto Text CJK",
    "SansSerif": "Kurinto Sans SC,Kurinto Sans TC,Kurinto Sans HK,Kurinto Sans CJK",
    "Monospace": "Kurinto Mono SC,Kurinto Mono TC,Kurinto Mono HK,Kurinto Mono CJK"
  }
}

} }

I pointed xep to saxon as I didn't install xep. I even specified to use the fop processor in the command line and still receive these errors.

thabing commented 5 months ago

The fop.jar file was not in correct directory.