Defekte in GroupShare 2020 with handling of segmentation rules

Hello SDL developers,

we are currently working on migrating our groupshare installation. We developed years ago an application to migrate TMs with all its settings: segmentations rules. variables, ordinal followers and abbreviations. This worked in the past, but not for the migration to GS2020: we have a problem with the segmentation rules.

here a code snippet to explain the problem:

//create a default provider to get the standard values
DefaultLanguageResourceProvider defaultLangResProvider = new DefaultLanguageResourceProvider();
LanguageResourceBundle defaultLg = defaultLangResProvider.GetDefaultLanguageResources(CultureInfo.GetCultureInfo("de-AT"));
LanguageResourceBundle newTemplateLangResBundle = new LanguageResourceBundle(CultureInfo.GetCultureInfo("de-AT"));
// add variables
newTemplateLangResBundle.Variables = new Wordlist();
newTemplateLangResBundle.Variables.Add("test");
// add ordinal followers
newTemplateLangResBundle.OrdinalFollowers = defaultLg.OrdinalFollowers;
newTemplateLangResBundle.OrdinalFollowers.Add("test.");
// add abbreviations
newTemplateLangResBundle.Abbreviations = defaultLg.Abbreviations;
newTemplateLangResBundle.Abbreviations.Add("test.");
// add segmentation rules
newTemplateLangResBundle.SegmentationRules = defaultLg.SegmentationRules; // <<<------
serverLangResTemplate.LanguageResourceBundles.Add(newTemplateLangResBundle);
serverLangResTemplate.Save();

The code line marked with <<<------ is not working. I get an error message: 500 (Internal Server Error).
If I remove this line, the language resource is saved properly and the 3 standard segmentation rules are set in the segmentation rules list.

This means that I have no possiblity to change the segmentation rules or delete them to have a paragraph based segmentation. I always get the internal server error.


The problem seems to be larger as the UI currently doesn't allow to change the segmentation rules properly. Maybe the 2 problems are linked together.

Can you check this problem and correct my code if I missed something?

Kind regards

Sébastien

Parents
  • , Hello Robert, maybe you can take a look at this one too. We've been told to write in the forum to get sure, that the problem is known by the dev team and that a patch will be ready as soon as possible.
    In the meantime, I could test some manual settings in GroupShare 2020 to check if something could be changed in the segmentation rules and indeed, I was able to set up a paragraph based TM (verified through the API). But the UI still gives the information, that the default segmentation is set.

    Can you give me some more insight, if somebody is working on that problem and if yes, how it looks like for the next CU? an idea when the next CU for GroupShare 2020 comes?

    Kind regards

    Sébastien

  • If I'm not mistaken, if you create TM as paragraph based then in UI it shows as sentence based but it will segment accordingly - can you please confirm this?

  • Hello Patrick,

    no this is not correct or at least not systematic. I've just tried many times to get the paragraph-based settings in a test TM but I couldn't get any positive results. What does work is to remove some rules from the segmentation rules list. But if I take them all to get the paragraph based setting through another way, the default settings are set up again.

    And unfortunately, I couldn't reproduce the result I mentioned yesterday. It was in a language resource template but it doesn't work today.

    At least we have a workaround I just thought of: I will set up an "impossible" regex in a segmentation rule to get what we want. This way we will see that the segmentation are customized in the UI and it will behave like a paragraph-based TM.

    Another problem I met today in relation with GroupShare 2020 concerns the GetDefaultLanguageResources function. The following code throws an error

    LanguageResourceBundle defaultLg =  defaultLangResProvider.GetDefaultLanguageResources(CultureInfo.GetCultureInfo("de-DE"));

    whereas it works perfectly well if I run it on our GroupShare 2015 server.

    Maybe you can also take a look here.

    Kind regards

    Sébastien Desautel

Reply
  • Hello Patrick,

    no this is not correct or at least not systematic. I've just tried many times to get the paragraph-based settings in a test TM but I couldn't get any positive results. What does work is to remove some rules from the segmentation rules list. But if I take them all to get the paragraph based setting through another way, the default settings are set up again.

    And unfortunately, I couldn't reproduce the result I mentioned yesterday. It was in a language resource template but it doesn't work today.

    At least we have a workaround I just thought of: I will set up an "impossible" regex in a segmentation rule to get what we want. This way we will see that the segmentation are customized in the UI and it will behave like a paragraph-based TM.

    Another problem I met today in relation with GroupShare 2020 concerns the GetDefaultLanguageResources function. The following code throws an error

    LanguageResourceBundle defaultLg =  defaultLangResProvider.GetDefaultLanguageResources(CultureInfo.GetCultureInfo("de-DE"));

    whereas it works perfectly well if I run it on our GroupShare 2015 server.

    Maybe you can also take a look here.

    Kind regards

    Sébastien Desautel

Children