-
Notifications
You must be signed in to change notification settings - Fork 43
A summary of frequently encountered errors and their solutions.
Step ZERO
If something doesn't work, try running cmsenv
, and source FinalStateAnalysis/environment.sh
and then try again.
You have the wrong SCRAM_ARCH set. You need to do:
export SCRAM_ARCH=slc5_amd64_gcc434
for CMSSW_4_X_Y and:
export SCRAM_ARCH=slc5_amd64_gcc462
for CMSSW_5_X_Y. Note these will change for future CMSSW versions!
These are generally problems that happen when you are trying to checkout
or update the code (git pull origin master
).
This error occurs when you try to git pull
outside of the FinalStateAnalysis
directory (which is the "root" of the git repository). Solution is to run the
command in that directory.
This means that you have files changed in your working area that are also
changed in the code update you are trying to pull. You can see locally modified
files by running git status
.
You have two options:
- Commit your changes
git add [the files]
,git commit -m "my commit message"
, and then pull again. - Reset (lose/throw away/discard) your changes (danger!)
git checkout -- [files]
- "Stash" your changes (advanced)
git stash
You need to create a github.com account, and generate a SSH key pair. Instructions to do this are at Generating SSH keys:
First, always make sure that you did:
source environment.sh
in the FinalStateAnalysis directory to setup your environment.
Generally this means that you have either not setup your environment, or not
compiled the area (scram b -j 6
in the src/
directory). Make sure that
scram b compiled the code successfully, without errors!
In CMSSW_7_X_X, the default compiler flags include some "tight" flags which cause coding errors that are typically treated as warnings by the compiler, such as unused variables or comparison between signed and unsigned data types, to be treated as errors, causing unsuccessful compilation if these are encountered. It is necessary to relax these, which can be done by setting USER_CXXFLAGS. The necessary flags are set in environment.sh, so you should not encounter this if you have set your environment correctly.
This is a special case, generally only needed for plotting - rootpy
is an
external package that needs to be downloaded and installed:
cd $CMSSW_BASE/src/FinalStateAnalysis/recipe/external/src git clone [email protected]:ekfriis/rootpy.git cd $CMSSW_BASE/src/FinalStateAnalysis/recipe ./install_python.sh
When upgrading to SLC6, you may encounter an error similar to this when compiling:
... /afs/cern.ch/cms/sw/ReleaseCandidates/vol1/slc5_amd64_gcc472/external/clhep/2.1.3.1-cms2/include/CLHEP/Units/PhysicalConstants.h:80:21: error: 'CLHEP::electron_charge' defined but not used [-Werror=unused-variable] cc1plus: some warnings being treated as errors gmake: ***[tmp/slc5_amd64_gcc472/src/FastSimulation/ShowerDevelopment/src/FastSimulationShowerDevelopment/HDShower.o] Error 1
To switch off the -Werror=unused-variable
flag, run scram with:
USER_CXXFLAGS="-Wno-delete-non-virtual-dtor -Wno-error=unused-but-set-variable -Wno-error=unused-variable" scram b
- Using Git
- Developing in FSA
- The PAT Tuple
- Ntuple Tools
- Plot Tools
- Package Description for each subpackage
- List of provided EDM Plugins
- List of provided Helper Scripts
- Definitions and Additional Information