refactor: Rework providers and templates logic

This commit is contained in:
Petr Mironychev
2025-02-22 19:39:28 +01:00
committed by GitHub
parent bd25736a55
commit d96f44d42c
44 changed files with 701 additions and 524 deletions

View File

@ -58,7 +58,10 @@ void RequestHandler::sendLLMRequest(const LLMConfig &config, const QJsonObject &
reply->deleteLater();
m_activeRequests.remove(requestId);
if (reply->error() != QNetworkReply::NoError) {
LOG_MESSAGE(QString("Error in QodeAssist request: %1").arg(reply->errorString()));
LOG_MESSAGE(QString("Error details: %1\nStatus code: %2\nResponse: %3")
.arg(reply->errorString())
.arg(reply->attribute(QNetworkRequest::HttpStatusCodeAttribute).toInt())
.arg(QString(reply->readAll())));
emit requestFinished(requestId, false, reply->errorString());
} else {
LOG_MESSAGE("Request finished successfully");