Strange error when migrating XML1-based sdlftsettings files to XML2-based sdlftsettings

We need to migrate XML1-based sdlftsettings files to XML2-based sdlftsettings files in Trados Studio 2024 using the procedure as described under the link below.

gateway.sdl.com/CommunityKnowledge

When doing so for a set of 3 sdlftsettings files, we get the error message below.
The error occurs between step 5 (Namespaces) and step 6 (Parser Rules).
The only thing we can do is click away the error message.
Next, all parser rules seem to migrate correctly, but due to the red cross present in each cell in the 1st column (Details) we cannot click Next and complete the migration.

Error dialog box in Trados Studio with a red cross icon, stating 'Resource Filters.UI.Xml2.warning.gif could not be found in assembly Filters.UI.Xml2.' with an OK button.

Trados Studio 'Create File Type' window showing a list of parser rules with red cross icons in the 'Details' column, indicating an error for each item.

No information on this error message to be found anywhere.



Generated Image Alt-Text
[edited by: RWS Community AI at 3:51 AM (GMT 0) on 15 Nov 2024]
emoji
Parents
  • Hi  , the issue is caused by the "fct:ExternalLink" parser rule, as it references a namespace that was not added under Namespace mapping in the filter settings. As this should not prevent you from migrating the filter, I logged the issue for our Development (as CRQ-40344), so it can be fixed in the future. 

    emoji
  •  

    I sent you an email to explain this in a little more detail but for the benefit of others who might stumble across this thread the main points are these.

    First of all when you get to this page pay attention to the messages:

    Trados Studio screenshot showing the 'Create File Type' wizard with a list of settings. Warnings are visible for 'Parser rules' and 'Namespace mappings' indicating they require review.

    In my case there are two warnings that should be considered: 

    • Parser Rules
    • Namespace Settings

    Everything else is ok for the migration.  So what this means in practice is that when you get to here you need to check and see whether the XML files you are handling use namespaces:

    Trados Studio 'Create File Type' wizard displaying the 'Namespace mapping' section with an information dialog box advising to list all namespaces and assign a prefix.

    The old XMLv1 filetype was a bit trickier, and also more forgiving, to set up for namespaces so you may not have done this in the old filetype.  So in the original settings file you had a rule like this:

    Trados Studio 'Options' window with the 'Parser' section expanded, showing a rule where the prefix 'fct' is used in the XPath expression.

    You can see the rule used a namespace in the XPath, but in the namespaces section this was not declared at all:

    Trados Studio 'Options' window with the 'Namespaces' section selected, showing options for namespace resolution without any namespaces listed.

    So, when you migrate the settings the XML v2 filetype requires this namespace information.  It is easy enough to solve once you know which namespace is missing as you just add it when you get to step 5 in the migration workflow I showed above.  So in this case you would add fct to the Prefix.  The Uri won't be in the settings file as you didn't add it in the old settings so you need to get that from the XML files you are translating.  In this case something like this:

    xmlns:fct="">www.fct.com/somename" 

    So the entry would be this:

    Trados Studio 'Create File Type' wizard showing the 'Namespace mapping' section with 'fct' as the prefix and 'http:www.fct.comsomename' as the URI.

    Once you do that all is well.

    Now, given this is pretty straightforward to identify where a namespace was used in the old parser rules this is going to be easy if you still have access to the old version of Trados Studio.  But if you don't then here's a simple Python script that will report the missing info when you run it and select the old settings file. 

    namespace_corrections.zip

    Run the script in a Python processsor (Visual Studio Code, PyCharm or Jupitor Notebook for example), select the old settings file when prompted and you'll get a result like this:

    Missing namespace declarations found:
    Prefix: fct
    Uri: [MISSING URI]

    So you only need to get the Uri from one of your translatable XML files.

    Paul Filkin | RWS Group

    ________________________
    Design your own training!

    You've done the courses and still need to go a little further, or still not clear? 
    Tell us what you need in our Community Solutions Hub

    emoji


    Generated Image Alt-Text
    [edited by: RWS Community AI at 12:04 PM (GMT 0) on 1 Nov 2024]
Reply
  •  

    I sent you an email to explain this in a little more detail but for the benefit of others who might stumble across this thread the main points are these.

    First of all when you get to this page pay attention to the messages:

    Trados Studio screenshot showing the 'Create File Type' wizard with a list of settings. Warnings are visible for 'Parser rules' and 'Namespace mappings' indicating they require review.

    In my case there are two warnings that should be considered: 

    • Parser Rules
    • Namespace Settings

    Everything else is ok for the migration.  So what this means in practice is that when you get to here you need to check and see whether the XML files you are handling use namespaces:

    Trados Studio 'Create File Type' wizard displaying the 'Namespace mapping' section with an information dialog box advising to list all namespaces and assign a prefix.

    The old XMLv1 filetype was a bit trickier, and also more forgiving, to set up for namespaces so you may not have done this in the old filetype.  So in the original settings file you had a rule like this:

    Trados Studio 'Options' window with the 'Parser' section expanded, showing a rule where the prefix 'fct' is used in the XPath expression.

    You can see the rule used a namespace in the XPath, but in the namespaces section this was not declared at all:

    Trados Studio 'Options' window with the 'Namespaces' section selected, showing options for namespace resolution without any namespaces listed.

    So, when you migrate the settings the XML v2 filetype requires this namespace information.  It is easy enough to solve once you know which namespace is missing as you just add it when you get to step 5 in the migration workflow I showed above.  So in this case you would add fct to the Prefix.  The Uri won't be in the settings file as you didn't add it in the old settings so you need to get that from the XML files you are translating.  In this case something like this:

    xmlns:fct="">www.fct.com/somename" 

    So the entry would be this:

    Trados Studio 'Create File Type' wizard showing the 'Namespace mapping' section with 'fct' as the prefix and 'http:www.fct.comsomename' as the URI.

    Once you do that all is well.

    Now, given this is pretty straightforward to identify where a namespace was used in the old parser rules this is going to be easy if you still have access to the old version of Trados Studio.  But if you don't then here's a simple Python script that will report the missing info when you run it and select the old settings file. 

    namespace_corrections.zip

    Run the script in a Python processsor (Visual Studio Code, PyCharm or Jupitor Notebook for example), select the old settings file when prompted and you'll get a result like this:

    Missing namespace declarations found:
    Prefix: fct
    Uri: [MISSING URI]

    So you only need to get the Uri from one of your translatable XML files.

    Paul Filkin | RWS Group

    ________________________
    Design your own training!

    You've done the courses and still need to go a little further, or still not clear? 
    Tell us what you need in our Community Solutions Hub

    emoji


    Generated Image Alt-Text
    [edited by: RWS Community AI at 12:04 PM (GMT 0) on 1 Nov 2024]
Children
No Data