mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
Osdu wellpath import: improve error handling.
This commit is contained in:
parent
8854abe482
commit
c5da22223b
@ -677,7 +677,9 @@ void RiaOsduConnector::requestParquetData( const QString& url, const QString& da
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
RiaLogging::error( "Download failed: " + url + " failed." + reply->errorString() );
|
QString errorMessage = "Download failed: " + url + " failed." + reply->errorString();
|
||||||
|
RiaLogging::error( errorMessage );
|
||||||
|
emit parquetDownloadFinished( QByteArray(), errorMessage );
|
||||||
}
|
}
|
||||||
} );
|
} );
|
||||||
}
|
}
|
||||||
|
@ -83,18 +83,18 @@ void RicWellPathsImportOsduFeature::onActionTriggered( bool isChecked )
|
|||||||
std::vector<RiuWellImportWizard::WellInfo> importedWells = wellImportwizard.importedWells();
|
std::vector<RiuWellImportWizard::WellInfo> importedWells = wellImportwizard.importedWells();
|
||||||
for ( auto w : importedWells )
|
for ( auto w : importedWells )
|
||||||
{
|
{
|
||||||
auto wellPath = new RimOsduWellPath;
|
|
||||||
wellPath->setName( w.name );
|
|
||||||
wellPath->setWellId( w.wellId );
|
|
||||||
wellPath->setWellboreId( w.wellboreId );
|
|
||||||
wellPath->setWellboreTrajectoryId( w.wellboreTrajectoryId );
|
|
||||||
|
|
||||||
oilField->wellPathCollection->addWellPath( wellPath );
|
|
||||||
|
|
||||||
auto [wellPathGeometry, errorMessage] =
|
auto [wellPathGeometry, errorMessage] =
|
||||||
RimWellPathCollection::loadWellPathGeometryFromOsdu( osduConnector, w.wellboreTrajectoryId );
|
RimWellPathCollection::loadWellPathGeometryFromOsdu( osduConnector, w.wellboreTrajectoryId );
|
||||||
if ( wellPathGeometry.notNull() )
|
if ( wellPathGeometry.notNull() )
|
||||||
{
|
{
|
||||||
|
auto wellPath = new RimOsduWellPath;
|
||||||
|
wellPath->setName( w.name );
|
||||||
|
wellPath->setWellId( w.wellId );
|
||||||
|
wellPath->setWellboreId( w.wellboreId );
|
||||||
|
wellPath->setWellboreTrajectoryId( w.wellboreTrajectoryId );
|
||||||
|
|
||||||
|
oilField->wellPathCollection->addWellPath( wellPath );
|
||||||
|
|
||||||
wellPath->setWellPathGeometry( wellPathGeometry.p() );
|
wellPath->setWellPathGeometry( wellPathGeometry.p() );
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
@ -66,22 +66,21 @@ void RicImportWellLogOsduFeature::onActionTriggered( bool isChecked )
|
|||||||
|
|
||||||
for ( OsduWellLog wellLog : wellLogs )
|
for ( OsduWellLog wellLog : wellLogs )
|
||||||
{
|
{
|
||||||
RimOsduWellLog* osduWellLog = new RimOsduWellLog;
|
auto [wellLogData, errorMessage] = RimWellPathCollection::loadWellLogFromOsdu( osduConnector, wellLog.id );
|
||||||
osduWellLog->setName( wellLog.id );
|
|
||||||
osduWellLog->setWellLogId( wellLog.id );
|
|
||||||
oilField->wellPathCollection->addWellLog( osduWellLog, wellPath );
|
|
||||||
|
|
||||||
auto [wellLogData, errorMessage] = RimWellPathCollection::loadWellLogFromOsdu( osduConnector, osduWellLog->wellLogId() );
|
|
||||||
if ( wellLogData.notNull() )
|
if ( wellLogData.notNull() )
|
||||||
{
|
{
|
||||||
|
RimOsduWellLog* osduWellLog = new RimOsduWellLog;
|
||||||
|
osduWellLog->setName( wellLog.id );
|
||||||
|
osduWellLog->setWellLogId( wellLog.id );
|
||||||
|
oilField->wellPathCollection->addWellLog( osduWellLog, wellPath );
|
||||||
|
|
||||||
osduWellLog->setWellLogData( wellLogData.p() );
|
osduWellLog->setWellLogData( wellLogData.p() );
|
||||||
|
osduWellLog->updateConnectedEditors();
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
RiaLogging::error( "Importing OSDU well log failed: " + errorMessage );
|
RiaLogging::error( "Importing OSDU well log failed: " + errorMessage );
|
||||||
}
|
}
|
||||||
|
|
||||||
osduWellLog->updateConnectedEditors();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user