compose error

Hello,

Does anyone know what this error means?

Screenshot of Trados Studio showing a document with multiple instances of the code 'Krc'. An error message box is visible with the text 'Macro definitions are probably too long andor recursive'.

It happens after adding a margin note code <ufm>H66<ufn>, which is <px;;0>H66<pa> to be displayed in the frills.

There are no error if no margin note is added. Once it is added, this error pops up. 

This page contains a large table (21 columns), does it relate to the content of the page?

Regards,

Chung



Generated Image Alt-Text
[edited by: Trados AI at 5:31 AM (GMT 0) on 5 Mar 2024]
emoji
  • Hi Chung

    It is nothing to do with the text on the page - it is to do with the macros you have written - either they are too long (which I doubt) OR they are being sent round in circles - so check the logic of the macros and make sure they are not re-referencing the same macro over and over again.

    Chris

    emoji
  • Hi Chris,

    If I push some rows of the table to the next page, there will be no error with the margin note added.

    Chung

    emoji
  • Chung,

    Welcome to the tedious world of macro debugging.
    If you push rows over, you change the conditions that occur and hence your macro loop might no longer occur.
    You will have to do a lot of experiments do determine which macro created your problem.
    You might deactivate macro by macro by putting an X or _ in front of the macro name in the macro definition and see which one is the one that gives you problems 

    emoji
  • Hi Bart,

    Oh, it seems to be a upper limit on looping all the lines in a page using <WHILE;!opened;checkline>, where checkline is <OPEN;next;main;line>

    Chung

    emoji
  • Hi Chung,

    I just wanted to chime in to add some information to your discovery.

    If you had searched the XPP documentation for the error message you would have gotten this hit under the Frills Processing section of the XyMacros manual:

    Warning message about frills processing loop in XPP documentation stating to use caution as lines over 65535 bytes cause a fatal error due to long or recursive macro definitions.

    So, it is a known limitation of the old frills processing macro writing language in combination with the maximum length of a database line in XPP (of 65535 bytes).

    The situation is typically handled by adding a loop counter to the frills processing loop and then every 100 loops or so (you'll have to determine the # that works for each specific loop) you spit out a <qa> or <mh;0><qa> if the <mh;0> is necessary to act like a "character" in order for the <qa> to actually cause composition to start a new line.

    I hope that helps.

    Jonathan Dagresta
    RWS Group/
    XPP Development

    emoji


    Generated Image Alt-Text
    [edited by: Trados AI at 5:32 AM (GMT 0) on 5 Mar 2024]
  • And I forgot to add that when this composition error occurs (with XPP 9.1.0 or later), in the composition log you will also find the output of a representation of the line contents just before the line overflowed.

    We added this to give some "composition context" when the error occurs to try to help the user diagnose where and why the problem was occurring.

    Jonathan Dagresta
    RWS Group/
    XPP Development

    emoji
  • Fantastic!

    I added a <mh;0><qa> to each line, it solve the problem.

    Thanks Jonathan.

    emoji