stanfordnlp/CoreNLP · error · IllegalArgumentException
Could not find Redwood log property:
Error message
Could not find Redwood log property:
What it means
After parsing, parse() tracks which log.* properties were consumed in the 'used' set and throws this IllegalArgumentException for any remaining property starting with 'log.' — i.e. an unrecognized or misspelled Redwood logging property.
Solutions
- Fix or remove the offending log.* property; valid keys include log.method, log.handlers, log.channels.debug, log.collapse, log.filter, etc.
- Check the key spelling against RedwoodConfiguration documentation for your library version.
- Rename application-specific keys so they do not start with the reserved 'log.' prefix.
- If a property worked before, verify it still exists in the current library version (API changes between releases).
Example fix
// before
props.setProperty("log.colaps", "none"); // typo
// after
props.setProperty("log.collapse", "none"); Defensive patterns
Strategy: validation
Validate before calling
Set<String> known = Set.of("log.method", "log.handlers", "log.channels.debug", "log.collapse", "log.filter", "log.adapt.javautillogging");
for (String key : props.stringPropertyNames()) {
if (key.startsWith("log.") && !known.contains(key)) {
throw new IllegalArgumentException("Unknown Redwood log property: " + key);
}
} Try / catch
try {
RedwoodConfiguration.applyProperties(props);
} catch (IllegalArgumentException e) {
if (e.getMessage().startsWith("Could not find Redwood log property:")) {
String bad = e.getMessage().substring(e.getMessage().lastIndexOf(' ') + 1);
props.remove(bad); // or fix the key, then retry
RedwoodConfiguration.applyProperties(props);
} else throw e;
} Prevention
- Keep the set of valid log.* keys in sync with your library version's documentation.
- Namespace your own app settings away from the reserved 'log.' prefix.
- After upgrading CoreNLP/Redwood, re-check all log.* keys against the new version.
When it happens
Trigger: Passing a Properties object with a key starting with log. that Redwood does not understand, e.g. log.loglevel, log.colour, log.colaps — any typo of a supported key.
Common situations: Typos in keys like log.neural vs log.neurl; inventing keys expecting they'd work; upgrading/downgrading CoreNLP where a log.* property name changed or was removed.
Understand the failure class
Background: "Invalid value" and "allowed values are" config errors: what your library rejected and how to fix it — this error's family across 41 libraries.
Related errors
- Cannot modify Redwood when within a track
- Unknown collapse mode (Redwood):
- Unknown properties: " + names
- Unknown property: " + names.iterator().next()
- Unknown value for log.method
AI-assisted analysis of stanfordnlp/CoreNLP@1b7edd19c4 (2026-09-10).
Data as JSON: /api/errors/0a108f701bee0cf0.
Report an issue: GitHub.
Appendix: source
Thrown at src/edu/stanford/nlp/util/logging/RedwoodConfiguration.java:625
//--File
String outputFile = get(props, "log.file", null, used);
if (outputFile != null) {
config.defaultFile = new File(outputFile);
config = config.handlers(Handlers.defaultFile);
}
//--Console
config = config.output(get(props, "log.output", "stdout", used));
//--Console
config = config.handlers(Handlers.chain(chain.toArray(new LogRecordHandler[chain.size()]), Handlers.output));
//--Error Check
for(Object propAsObj : props.keySet()) {
String prop = propAsObj.toString();
if(prop.startsWith("log.") && !used.contains(prop)){
throw new IllegalArgumentException("Could not find Redwood log property: " + prop);
}
}
//--Return
return config;
}
/**
* Parses a properties file and applies it immediately to Redwood
* @param props The properties to apply
*/
public static void apply(Properties props){
parse(props).apply();
}
/*
public static void main(String[] args) {
RedwoodConfiguration.empty().neatExit().capture(System.out).capture(System.err)View on GitHub (pinned to 1b7edd19c4)