Bug report: 'ImportConverter' 'Process' limits the number of characters of the exe + params. the maximum is 360.

  • In dicom.ini:

    Code
    ImportConverter3 = ifnotequal "%m", "MR"; stop; process study after 3 by F:\MRLinac\ClinicalTest\XVIMRLv1.16\012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789\XVIMRL.exe "[DICOM local server]:%V0010,0020:%V0010,0020.patient\%V0020,000d.study\%V0020,000e.series\any&ImageType=ORIGINAL.scan"

    In the serverstatus.log from Conquest DICOM server:

    Code
    8/14/2019 1:39:25 PM [XVIMRL_B5] Importconverter3.6: queued process ser - (single object of F20190807) to F:\MRLinac\ClinicalTest\XVIMRLv1.16\012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789\XVIMRL.exe "[DICOM local server]:F180515A:F180515A.patient\1.3.46.670589.11.79008.5.0.10628.2019041716163908010.study\1.3.46.670589.11.79008.5.0.7260.2019041717033285678.series\any&ImageType=ORIGINAL.sca"
    ...

    The total length(

    F:\MRLinac\ClinicalTest\XVIMRLv1.16\012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789\XVIMRL.exe "[DICOM local server]:F180515A:F180515A.patient\1.3.46.670589.11.79008.5.0.10628.2019041716163908010.study\1.3.46.670589.11.79008.5.0.7260.2019041717033285678.series\any&ImageType=ORIGINAL.sca"

    ) is 360.

    Anything after character 360 will be removed.

    It would be cool to support more characters. 8)

  • Some filesystems also have issues with the total length of the file path. That's a very long path and looking critically, it's just 0-9 repeated 12 times. What's the purpose of building a path like that?


    Look into to using filesystem links if you can't fix your path. You should be able to work around this without needing a CQ change.

  • Hi,


    since patientID is max 16, and UIDs are max 64, your output 'path' is max ~240 characters. So by limiting the path length of the exe file, you can easily guarantee to fit the command line in 360 characters. So I am not inclined to modify the source for an issue that is easily avoidable.


    regards


    Marcel

  • On the clinical PC for testing we were only allowed to install our software in a specific folder which has a very long file path.

    It was not a good example for using 0-9 repeated 12 times as folder name. It was only handy for me to locate this issue.

    It is not an issue for us now and it can be indeed avoided by limiting the file path length.

    But it becomes more robust if it supports more characters. Imaging there is an application that needs lots of parameters. Then 360 becomes a constrain.

    Code
    ImportConverter3 = ifnotequal "%m", "MR"; stop; process study after 3 by F:\MyApp.exe "[DICOM local server]:%V0010,0020:%V0010,0020.patient\%V0020,000d.study\%V0020,000e.series\any&ImageType=ORIGINAL.scan" "V0008,0060" "%V0008,0018" "%V0008,0014" "%V0008,0055" "%V0020,0052" "Vxxxx,yyyy"


    Maybe it should be mentioned in the 'windowsmanual'.

  • Moreover during the test last week there is one issue from importConverter that i could not re-produce from my local pc. The scan URL ends with (wrong) patient ID.

    My setting and log file are:

    The ImportConverter is

    Code
    ImportConverter3 = ifnotequal "%m", "MR"; stop; ifnotmatch "%V0018,1030", "*T2*"; stop; ifnotmatch "%V0008,103E", "cT2_4DTSE*"; process series after 3 by E:\XVIMRL\NO_CRAP_IN_THE_XVIMRL_FOLDERS_PLEASE\ClinicalTestXVIMRL\V1.16\XVIMRL.exe /online "[XVIMRL_B5]:%V0010,0020:%V0010,0020.patient\%V0020,000d.study\%V0020,000e.series\any&ImageType=ORIGINAL.scan"; process series after 3 by E:\XVIMRL\NO_CRAP_IN_THE_XVIMRL_FOLDERS_PLEASE\ClinicalTestXVIMRL\V1.16\XVIMRL.exe /online "[XVIMRL_B5]:%V0010,0020:%V0010,0020.patient\%V0020,000d.study\%V0020,000e.series\any.scan"

    The serverstatus for the first patient (ID: F20190807) shows below. The total length (E:\XVIMRL\NO_CRAP_IN_THE_XVIMRL_FOLDERS_PLEASE\ClinicalTestXVIMRL\V1.16\XVIMRL.exe /online "[XVIMRL_B5]:F20190807:F20190807.patient\1.3.46.670589.11.79008.5.0.12924.2019081413174156012.F20190807) is just 194. And the patient ID is in the end of the string which is not expected behavior.

    Quote

    8/14/2019 1:39:25 PM [XVIMRL_B5] Importconverter3.6: queued process ser - (single object of F20190807) to E:\XVIMRL\NO_CRAP_IN_THE_XVIMRL_FOLDERS_PLEASE\ClinicalTestXVIMRL\V1.16\XVIMRL.exe /online "[XVIMRL_B5]:F20190807:F20190807.patient\1.3.46.670589.11.79008.5.0.12924.2019081413174156012.F20190807

    Then I tried another patient (ID: F20190415). This scan URL even ends with the patient ID of the first patient.

    Quote

    8/14/2019 1:48:11 PM [XVIMRL_B5] Importconverter3.6: queued process ser - (single object of F20190415) to E:\XVIMRL\NO_CRAP_IN_THE_XVIMRL_FOLDERS_PLEASE\ClinicalTestXVIMRL\V1.16\XVIMRL.exe /online "[XVIMRL_B5]:F20190415:F20190415.patient\1.3.46.670589.11.79008.5.0.14000.2019080217022436018.F20190807

    Then I changed the importConverter to

    Code
    ImportConverter3 = ifnotequal "%m", "MR"; stop; ifnotmatch "%V0018,1030", "*T2*"; stop; process series after 3 by E:\XVIMRL\NO_CRAP_IN_THE_XVIMRL_FOLDERS_PLEASE\ClinicalTestXVIMRL\V1.16\XVIMRL.exe /online "[XVIMRL_B5]:%V0010,0020:%V0010,0020.patient\%V0020,000d.study\%V0020,000e.series\any.scan


    It works fine.


    Quote

    8/14/2019 1:55:23 PM [XVIMRL_B5] Importconverter3.4: queued process stu - (single object of F20190807) to E:\XVIMRL\NO_CRAP_IN_THE_XVIMRL_FOLDERS_PLEASE\ClinicalTestXVIMRL\V1.16\XVIMRL.exe /online "[XVIMRL_B5]:F20190807:F20190807.patient\1.3.46.670589.11.79008.5.0.12924.2019081413174156012.study\1.3.46.670589.11.79008.5.0.5452.2019081413361528324.series\any.scan"

  • Hi,


    the generated process has a limit of 360 characters, but the importconverter itself has a limit of 512 characters, after which the terminating \0 is not added. These limits are not properly enforced - so you are facing results of a buffer overrun.


    For more reliable operation I would suggest to call a lua file from the ImportConverter, which uses script('process ....) to queue one or more converters based one the values read from Data. In any case, lua is the advised method of scripting conquest. The 'importconverter' text is hand-parsed and sensitive to all sorts of limitations.


    regards,


    Marcel

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!