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();
// add ordinal followers
newTemplateLangResBundle.OrdinalFollowers = defaultLg.OrdinalFollowers;
// add abbreviations
newTemplateLangResBundle.Abbreviations = defaultLg.Abbreviations;
// add segmentation rules
newTemplateLangResBundle.SegmentationRules = defaultLg.SegmentationRules; // <<<------

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


  • , 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


  • 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

  • Hello ,

    do you have any news on this bug in GroupShare 2020? Any information when the next CU is coming?

    Kind regards

    Sébastien Desautel

  • Hi, the next GS 2020 CU will be available at the end of this year. The UI issues will be solved, we worked on multiple issues related to segmentation on the UI side.

    As for the error on the API side with defaultLangResProvider.GetDefaultLanguageResources(CultureInfo.GetCultureInfo("de-DE"));, can you give us more info on what error GS throws?


  • Hi Paula, thanks for your answer.

    I checked the code again but I can't remember exactly how it was. When I start the code again, I get an error right at the 2nd line:

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

    error message: The type initializer for '"Sdl.LanguagePlatform.TranslationMemoryApi.DefaultLanguageResourceProvider"' threw an exception.

    I'm working with the Studio 2019 API.

    Any idea?

    Kind regards