[QGIS-Developer] Processing R scripts - TypeError: cannot concatenate 'str' and 'NoneType' objects

René-Luc Dhont rldhont at gmail.com
Tue Jun 6 05:36:39 PDT 2017


Hi Dev,

I have fixed https://issues.qgis.org/issues/16618 in 2.18 and 2.14.

Regards,
René-Luc

Le 05/06/2017 à 12:09, Giovanni Manghi a écrit :
> Hi,
>
> I confirm that in previous QGIS releases (2.14/2.16 for example) R
> scripts were working as expected.
>
> So I added
>
> https://issues.qgis.org/issues/16618
>
> to the list of regressions that must be fixed in time for the next LTR
>
> https://docs.google.com/spreadsheets/d/1frZQU8bwGX499WMvtOc6GDIWqEuSv3QHz3zc90TS46Q/edit?usp=sharing
>
>
> cheers!
>
> -- G --
>
>
>
>> Maybe a fix ...
>>
>> On Fri, Jun 2, 2017 at 8:31 PM, Anita Graser <anitagraser at gmx.at> wrote:
>>
>>> File "C:/OSGEO4~1/apps/qgis-ltr/./python/plugins\processing\algs\r\RAlgorithm.py",
>>> line 404, in getExportCommands
>>>
>>> commands.append('cat("##' + out.name + '",file="' + outputDataFile +
>>> '",sep="\n",append=TRUE)')
>>>
>>> TypeError: cannot concatenate 'str' and 'NoneType' objects
>>>
>> Not sure if it breaks anything else, but if I add
>>
>>              elif isinstance(out, OutputHTML):
>>                  pass
>>
>> before the offending
>>
>>              elif out.name != RAlgorithm.R_OUTPUT_VALUES:
>>                  commands.append('cat("##' + out.name + '",file="' +
>> outputDataFile + '",sep="\n",append=TRUE)')
>>                  commands.append('cat(' + out.name + ',file="' +
>> outputDataFile + '",sep="\n",append=TRUE)')
>>
>> Then the HTML output is created and visible in the results viewer and there
>> is no error.
>>
>> I'm not sure what the problematic lines were supposed to do anyway ...
> _______________________________________________
> QGIS-Developer mailing list
> QGIS-Developer at lists.osgeo.org
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer



More information about the QGIS-Developer mailing list