Skip to content

Commit

Permalink
Merge pull request #39264 from michael-pitt/FixTokenTransition_error
Browse files Browse the repository at this point in the history
Fix the mismatch in transition ID for idealGeo
  • Loading branch information
cmsbuild authored Sep 1, 2022
2 parents 3b039e0 + 6364eea commit 73bb0f6
Showing 1 changed file with 7 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,9 @@ class CTPPSGeometryESModule : public edm::ESProducer {
edm::ESGetToken<PDetGeomDesc, VeryForwardIdealGeometryRecord> dbToken_;
const bool fromPreprocessedDB_, fromDD4hep_;

edm::ESGetToken<DetGeomDesc, IdealGeometryRecord> idealGDToken2_;
edm::ESGetToken<DetGeomDesc, IdealGeometryRecord> idealGDToken_;
edm::ESGetToken<DetGeomDesc, VeryForwardIdealGeometryRecord> idealDBGDToken2_;
edm::ESGetToken<DetGeomDesc, VeryForwardIdealGeometryRecord> idealDBGDToken_;
edm::ESGetToken<CTPPSRPAlignmentCorrectionsData, RPRealAlignmentRecord> realAlignmentToken_;
edm::ESGetToken<CTPPSRPAlignmentCorrectionsData, RPMisalignedAlignmentRecord> misAlignmentToken_;
Expand All @@ -110,6 +112,7 @@ CTPPSGeometryESModule::CTPPSGeometryESModule(const edm::ParameterSet& iConfig)

if (buildMisalignedGeometry_) {
auto c2 = setWhatProduced(this, &CTPPSGeometryESModule::produceMisalignedGDFromPreprocessedDB);
idealDBGDToken2_ = c2.consumesFrom<DetGeomDesc, VeryForwardIdealGeometryRecord>(edm::ESInputTag());
misAlignmentToken_ =
c2.consumesFrom<CTPPSRPAlignmentCorrectionsData, RPMisalignedAlignmentRecord>(edm::ESInputTag());
}
Expand All @@ -123,6 +126,7 @@ CTPPSGeometryESModule::CTPPSGeometryESModule(const edm::ParameterSet& iConfig)

if (buildMisalignedGeometry_) {
auto c2 = setWhatProduced(this, &CTPPSGeometryESModule::produceMisalignedGD);
idealGDToken2_ = c2.consumesFrom<DetGeomDesc, IdealGeometryRecord>(edm::ESInputTag());
misAlignmentToken_ =
c2.consumesFrom<CTPPSRPAlignmentCorrectionsData, RPMisalignedAlignmentRecord>(edm::ESInputTag());
}
Expand All @@ -137,6 +141,7 @@ CTPPSGeometryESModule::CTPPSGeometryESModule(const edm::ParameterSet& iConfig)

if (buildMisalignedGeometry_) {
auto c2 = setWhatProduced(this, &CTPPSGeometryESModule::produceMisalignedGD);
idealGDToken2_ = c2.consumesFrom<DetGeomDesc, IdealGeometryRecord>(edm::ESInputTag());
misAlignmentToken_ =
c2.consumesFrom<CTPPSRPAlignmentCorrectionsData, RPMisalignedAlignmentRecord>(edm::ESInputTag());
}
Expand Down Expand Up @@ -239,7 +244,7 @@ std::unique_ptr<DetGeomDesc> CTPPSGeometryESModule::produceMisalignedGDFromPrepr
const VeryForwardMisalignedGeometryRecord& iRecord) {
return produceGD(iRecord.getRecord<VeryForwardIdealGeometryRecord>(),
iRecord.tryToGetRecord<RPMisalignedAlignmentRecord>(),
idealDBGDToken_,
idealDBGDToken2_,
misAlignmentToken_,
"CTPPSGeometryESModule::produceMisalignedGDFromPreprocessedDB");
}
Expand All @@ -260,7 +265,7 @@ std::unique_ptr<DetGeomDesc> CTPPSGeometryESModule::produceMisalignedGD(
const VeryForwardMisalignedGeometryRecord& iRecord) {
return produceGD(iRecord.getRecord<IdealGeometryRecord>(),
iRecord.tryToGetRecord<RPMisalignedAlignmentRecord>(),
idealGDToken_,
idealGDToken2_,
misAlignmentToken_,
"CTPPSGeometryESModule::produceMisalignedGD");
}
Expand Down

0 comments on commit 73bb0f6

Please sign in to comment.