Unexpected exception when configuring file multiFileConverter for task 'Apply PerfectMatch'

Hi,

I sometimes meet "Unexpected exception when configuring file multiFileConverter for task 'Apply PerfectMatch'" on Trados 2021 SR1(16.1.8.4404) during Automatic task "PerfectMatch".

How can we fix this issue? This problem occurs from 2021 on my environment.

Here is the log

<SDLErrorDetails time="2021/10/04 9:44:43">
<ErrorMessage>Unexpected exception when configuring file multiFileConverter for task 'Apply PerfectMatch': Failed to create an instance of translation provider 'sdltm.file:///C:/Trados/XXX.sdltm'..</ErrorMessage>
<Exception>
<Type>Sdl.ProjectApi.ProjectApiException, Sdl.ProjectApi, Version=16.0.0.0, Culture=neutral, PublicKeyToken=c28cdb26c445c888</Type>
<HelpLink />
<Source>Sdl.ProjectApi.Implementation</Source>
<HResult>-2146233088</HResult>
<StackTrace><![CDATA[ at Sdl.ProjectApi.Implementation.TaskExecution.ContentProcessingTaskImplementation.TaskFileExecuter.ConfigureConverter(IMultiFileConverter multiFileConverter, Language targetLanguage)
at Sdl.ProjectApi.Implementation.TaskExecution.ContentProcessingTaskImplementation.TaskFileExecuter.CreateMultiFileConverter(IProjectFile tf, String filePath)
at Sdl.ProjectApi.Implementation.TaskExecution.ContentProcessingTaskImplementation.TaskFileExecuter.Parse(String targetFilePath)]]></StackTrace>
<InnerException>
<Type>Sdl.ProjectAutomation.Core.ProjectAutomationException, Sdl.ProjectAutomation.Core, Version=16.0.0.0, Culture=neutral, PublicKeyToken=c28cdb26c445c888</Type>
<HelpLink />
<Source>Sdl.ProjectAutomation.FileBased</Source>
<HResult>-2146233088</HResult>
<StackTrace><![CDATA[ at Sdl.ProjectAutomation.FileBased.Internal.AutomationServerEvents.HandleTranslationProviderException(ITranslationProviderItem translationProviderItem, Exception exception)
at Sdl.ProjectApi.Helpers.ProjectCascadeFactory.GetTranslationProviderLanguageDirection(ITranslationProviderItem translationProviderItem, LanguagePair languageDirection, Boolean performUpdate, Boolean refreshCache)
at Sdl.ProjectApi.Helpers.ProjectCascadeFactory.CreateProjectCascadeEntries(IList`1 projectCascadeEntryDataList, LanguagePair languagePair, Boolean readOnly, Boolean refreshCache)
at Sdl.ProjectApi.Helpers.ProjectCascadeFactory.CreateCascade(ProjectCascadeSettings projectCascadeSettings, Boolean refreshCache)
at Sdl.ProjectApi.Helpers.LanguageDirectionHelper.CreateCascade(ILanguageDirection languageDirection, ProjectCascadeEntryDataFilterFunction filter, IComparer`1 sort, Boolean readOnly, Boolean refreshCache)
at Sdl.ProjectApi.Helpers.LanguageObjectsCache.GetLanguageResources(ILanguageDirection languageDirection)
at Sdl.ProjectApi.Helpers.LanguageObjectsCache.<>c__DisplayClass4_0.<GetLanguageResources>b__0(String _)
at System.Collections.Concurrent.ConcurrentDictionary`2.GetOrAdd(TKey key, Func`2 valueFactory)
at Sdl.ProjectApi.Helpers.LanguageObjectsCache.GetLanguageResources(IProject project, Language language)
at Sdl.ProjectApi.Helpers.LanguageObjectsCache.GetLanguageResources(ITranslatableFile file)
at Sdl.ProjectApi.AutomaticTasks.AbstractContentProcessorTaskImplementation.AddSegmentorToConverter(IExecutingTaskFile executingTaskFile, IBilingualProcessorContainer multiFileConverter)
at Sdl.ProjectApi.AutomaticTasks.PerfectMatch.PerfectMatchTask.ConfigureConverter(IExecutingTaskFile executingTaskFile, IMultiFileConverter multiFileConverter)
at Sdl.ProjectApi.Implementation.TaskExecution.ContentProcessingTaskImplementation.TaskFileExecuter.ConfigureConverter(IMultiFileConverter multiFileConverter, Language targetLanguage)]]></StackTrace>
<InnerException>
<Type>System.NullReferenceException, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</Type>
<HelpLink />
<Source>Sdl.Core.PluginFramework</Source>
<HResult>-2147467261</HResult>
<StackTrace><![CDATA[ at Sdl.Core.PluginFramework.ObjectRegistry`2.CreateObjects()
at Sdl.LanguagePlatform.TranslationMemoryApi.TranslationProviderManager.GetTranslationProviderFactories()
at Sdl.LanguagePlatform.TranslationMemoryApi.TranslationProviderManager.CreateTranslationProvider(Uri translationProviderUri, String translationProviderState, ITranslationProviderCredentialStore credentialStore)
at Sdl.ProjectApi.TranslationProviderCache.CreateTranslationProvider(Uri translationProviderUri, String translationProviderState, ITranslationProviderCredentialStore credentialStore)
at Sdl.ProjectApi.TranslationProviderCache.GetTranslationProvider(Uri translationProviderUri, String translationProviderState, ITranslationProviderCredentialStore credentialStore, Boolean performUpdate, Boolean refreshCache)
at Sdl.ProjectApi.Helpers.ProjectCascadeFactory.GetTranslationProviderLanguageDirection(ITranslationProviderItem translationProviderItem, LanguagePair languageDirection, Boolean performUpdate, Boolean refreshCache)]]></StackTrace>
</InnerException>
</InnerException>
</Exception>
<Environment>
<ProductName>SDL Trados Studio</ProductName>
<ProductVersion>Studio16</ProductVersion>
<EntryAssemblyFileVersion>16.1.8.4404</EntryAssemblyFileVersion>
<OperatingSystem>Microsoft Windows 10 Enterprise</OperatingSystem>
<ServicePack>NULL</ServicePack>
<OperatingSystemLanguage>1033</OperatingSystemLanguage>
<CodePage>932</CodePage>
<LoggedOnUser>ROW\jpnmai</LoggedOnUser>
<DotNetFrameWork>4.0.30319.42000</DotNetFrameWork>
<ComputerName>XXXX</ComputerName>
<ConnectedToNetwork>True</ConnectedToNetwork>
<PhysicalMemory>33270148 MB</PhysicalMemory>
</Environment>
</SDLErrorDetails>

Thanks,

Masayuki

Parents
  • Hi ,

    Can you please show me a code sample that causes this error?

    I've tried to reproduce it by running the PerfectMatch Batch task when I create a project:

    var projectInfo = new ProjectInfo
    {
    Name = "TestProject",
    SourceLanguage = new Language(CultureInfo.GetCultureInfo("en-US")), //import Sdl.core.globalization.dll
    TargetLanguages = new[] {new Language(CultureInfo.GetCultureInfo("de-DE")),},
    //file path where you want to save the project
    LocalProjectFolder = $@""
    };

    //import Sdl.ProjectAutomation.FileBased
    var fileBasedProject = new FileBasedProject(projectInfo);

    //HERE YOU NEED TO ADD THE PATH FOR FILES YOU WANT TO INCLUDE IN YOUR PROJECT
    var filesPath = new[] {@"C"};

    //add files to project
    var projectFiles = fileBasedProject.AddFiles(filesPath);
    //Translation provider configuration
    var translationProviderConfig = new TranslationProviderConfiguration();
    var entry = new TranslationProviderCascadeEntry(
    @"En-DeTM.sdltm", true, true, true);
    translationProviderConfig.Entries.Add(entry);
    fileBasedProject.UpdateTranslationProviderConfiguration(translationProviderConfig);
    //we need to run automatic task to create the project in studio
    fileBasedProject.RunAutomaticTask(projectFiles.GetIds(), AutomaticTaskTemplateIds.Scan);
    var taskSequence = fileBasedProject.RunAutomaticTasks(projectFiles.GetIds(),
    new[]
    {
    AutomaticTaskTemplateIds.ConvertToTranslatableFormat,
    AutomaticTaskTemplateIds.CopyToTargetLanguages, AutomaticTaskTemplateIds.PerfectMatch,
    AutomaticTaskTemplateIds.PreTranslateFiles,
    });
    if (taskSequence.Status == TaskStatus.Completed)
    {
    //project was created succesfully
    }
    else
    {
    if (taskSequence.Status.Equals(TaskStatus.Failed))
    {
    foreach (var subTask in taskSequence.SubTasks)
    {
    }
    }
    }
    fileBasedProject.Save();
    }

    Kind regards,

    Andrea Ghisa

  • Is there any updates ? I still get error on latest CU. I use Trados Studio 2021 SR2 - 16.2.10.9305

    emoji
  • I am on TradosStudio2022_17.0.4.13209 and the error is still there

    emoji
Reply Children
No Data