`maxerrorlines` does not appear to work via `robot.running.model.TestSuite.run`

Author: nickbrustCreated Apr 15, 2024Updated Aug 31, 2026

I have some code that uses robot.running.TestSuiteBuilder:

python
        builder = TestSuiteBuilder()
        suite = builder.build("some_suite.robot")
        # run
        suite.run(output="out.xml", loglevel="TRACE", maxerrorlines=None)

yet I am seeing the: [ Message content over the limit has been removed. ] in the test-case-level error message.

And setting this to any str value (int throws AttributeError: 'int' object has no attribute 'upper') seems to have no effect on the message length (I've tried maxerrorlines="10", ="999", ="NONE" as well).

loglevel is working.


However, if I use subprocess to build a CLI command using --maxerrorlines NONE or robot.run with maxerrorlines=None, the error message is formatted properly.


Environment:

bash
pip list | grep robot
robotframework                7.0

python --version
Python 3.10.14

cat /etc/os-release 
PRETTY_NAME="Debian GNU/Linux 11 (bullseye)"
NAME="Debian GNU/Linux"
VERSION_ID="11"
VERSION="11 (bullseye)"
VERSION_CODENAME=bullseye
ID=debian
HOME_URL="https://www.debian.org/"
SUPPORT_URL="https://www.debian.org/support"
BUG_REPORT_URL="https://bugs.debian.org/"

Source: robotframework/robotframework