Skip to content

Commit

Permalink
Fix 'bytes can only contain ASCII' error on python3
Browse files Browse the repository at this point in the history
  • Loading branch information
nyalldawson authored and m-kuhn committed Jan 19, 2017
1 parent 01cd784 commit f5e4c9d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/python/qgspythonutilsimpl.cpp
Expand Up @@ -619,11 +619,11 @@ QString QgsPythonUtilsImpl::homePythonPath()
QString settingsDir = QgsApplication::qgisSettingsDirPath();
if ( QDir::cleanPath( settingsDir ) == QDir::homePath() + QStringLiteral( "/.qgis3" ) )
{
return QStringLiteral( "b\"%1/.qgis3/python\".decode('utf-8')" ).arg( QDir::homePath() );
return QStringLiteral( "\"%1/.qgis3/python\"" ).arg( QDir::homePath() );
}
else
{
return "b\"" + settingsDir.replace( '\\', QLatin1String( "\\\\" ) ) + "python\".decode('utf-8')";
return "\"" + settingsDir.replace( '\\', QLatin1String( "\\\\" ) ) + "python\"";
}
}

Expand Down

0 comments on commit f5e4c9d

Please sign in to comment.