Feature #25534
Merge branch feature/MagneticFieldService in nug4 and make a new release
100%
Description
Hi,
I have re-implemented the MagneticFieldService in nug4 to be able to override it with a custom service and added the handling on non-uniform Bfields in the Detector Construction.
Lynn and Alex are aware of this, and it appears that there is no obvious conflicts with NOvA/LArSoft at the moment.
History
#1 Updated by Lynn Garren 2 months ago
- Assignee set to Lynn Garren
- Status changed from New to Assigned
We'll get started on this. It will be included along with some other changes in the nutools suite.
#2 Updated by Lynn Garren 2 months ago
- Status changed from Assigned to Resolved
nug4 v1_07_00 is tagged and ready to be installed as part of next weeks larsoft release.
#3 Updated by Lynn Garren 2 months ago
- % Done changed from 0 to 100
#4 Updated by Lynn Garren about 2 months ago
- Status changed from Resolved to Feedback
Turns out that this update breaks larreco. We request an accompanying PR from the authors.
Concerning the service modifications, in principle no changes are needed. I defined everything in the $NUG4_DIR/fcl/magfield.fcl as default. However, If your code needs the MagneticField service as before, it will need some changes. - art::ServiceHandle<mag::MagneticField>() -> art::ServiceHandle<mag::MagneticFieldService>() and get the provider from the service via the provider() method (See DetectorConstruction.cxx) Or you can do a la LArSoft with providerFrom<mag::MagneticFieldService>() if you can. Also there includes/libs will need to be changed: - #include "nug4/MagneticField/MagneticField.h" -> #include "nug4/MagneticFieldServices/MagneticFieldService.h" - nug4_MagneticField_MagneticField_service -> nug4_MagneticFieldServices_MagneticFieldServiceStandard_service
#5 Updated by Lynn Garren about 2 months ago
Note that you will need to build larg4, larsim, and larreco together. Use "mrb uv nug4 v1_07_00" to change the build to use nug4 v1_07_00.
Lynn
#6 Updated by Eldwan Brianne about 2 months ago
I have made the necessary modification in larreco. How should I proceed? Make a PR on the larreco github right?
[Edit] I have made a PR in larreco: https://github.com/LArSoft/larreco/pull/28
#7 Updated by Lynn Garren about 2 months ago
Thank you. I'll provide PR's for larg4 and larsim to enable testing.
#8 Updated by Lynn Garren about 2 months ago
Unfortunately, the gensingle test fails with the following error. Would you please fix? Thanks
%MSG-s ArtException: Early 25-Feb-2021 12:25:14 CST JobSetup cet::exception caught in art ---- Configuration BEGIN Library specification "MagneticField" does not correspond to any library in CET_PLUGIN_PATH of type "service" ---- Configuration END %MSG
#9 Updated by Eldwan Brianne about 2 months ago
I noticed that I needed to modify the mag field fcl in lardata to specify the service provider.
See lardata PR: https://github.com/LArSoft/lardata/pull/14
Trying to trigger a build following the tutorial (https://cdcvs.fnal.gov/redmine/projects/lar_ci/wiki/How_to_trigger_the_default_CI_build) with a certificate. I cannot manage it for some reason.. Getting
Triggering CI build workflow: default_wf trigger attempt # 1/10 curl: (22) The requested URL returned error: 400 Bad Request curl: (22) The requested URL returned error: 400 Bad Request
Command used on dunegpvm machine:
trigger --build-delay 0 --cert /tmp/x509up_u54588 --version develop --workflow default_wf --revisions "LArSoft/larg4#22 LArSoft/larsim#65 LArSoft/larreco#28 LArSoft/lardata#14"
#10 Updated by Lynn Garren about 2 months ago
Thanks for all your work fixing build problems. I have a question about fcl files. There are a number of them with the line below. Does that line need to change?
MagneticField: @local::no_mag_larsoft
#11 Updated by Vito Di Benedetto about 2 months ago
@Eldwan,
most likely the reason why your trigger command fails, is because the certificate you are providing is not accepted by Jenkins build service.
By running:
CI_CERT=/tmp/ci_cert.pem kx509 -o ${CI_CERT}
you are supposed to get a certificate from CIlogon CA:
voms-proxy-info -all -f ${CI_CERT} | grep issuer issuer : /DC=org/DC=cilogon/C=US/O=CILogon/CN=CILogon Silver CA 1
In your trigger command I see you refer as certificate the file /tmp/x509up_u54588
, that is the default place pointed by X509_USER_PROXY
.
In case you run a voms-proxy-init
command, the original cert is converted in a proxy grid certificate that is issued by incommon
CA.
Probably for /tmp/x509up_u54588
you are getting something like this:
voms-proxy-info -all | grep issuer issuer : /DC=org/DC=cilogon/C=US/O=Fermi National Accelerator Laboratory/OU=People/CN=Vito Di Benedetto/CN=UID:vito issuer : /DC=org/DC=incommon/C=US/ST=Illinois/L=Batavia/O=Fermi Research Alliance/OU=Fermilab/CN=voms1.fnal.gov
and this certificate is not accepted by Jenkins build service.
That's the reason why the tutorial use a custom
file to store the certificate, this way it is detached by the proxy grid certificate usually stored in a path like /tmp/x509up_u$(id -u)
.
In case you still need to trigger a CI build to test this combination of PRs, please, try the trigger command with the dedicated certificate file to verify this works for you.
Hopefully this helps to clarify the issue.
#12 Updated by Eldwan Brianne about 2 months ago
@Lynn,
It does not need to change. I modified the corresponding fcl entry in lardata so that there is no need to modify all other fcl that uses
MagneticField: @local::no_mag_larsoft
@Vito,
Thanks for the details.
#13 Updated by Kyle Knoepfel about 2 months ago
- Status changed from Feedback to Resolved
This will go in this week's LArSoft release.
#14 Updated by Lynn Garren about 2 months ago
nug4 v1_07_00 is used by larsoft v09_17_02.
#15 Updated by Kyle Knoepfel about 2 months ago
- Status changed from Resolved to Closed