GIPP L2COMM not backward compatible starting from 4.3.0
name: General Issue (FA)
about: Use this template for reporting an anomaly.
Please make sure that this is a bug. As per our GitHub Policy, we only address code/doc bugs, performance issues and build/installation issues on GitHub.
System information
- OS Platform and Distribution (e.g., Linux Ubuntu 16.04): Debian 10
- Maja installed from (source or binary): source
- Maja version (use command below): release_4.3.0
- Maja commit sha (if Maja is installed from source): 90df6515
- Python version (From binpkg or custom): from Superbuild_Archive
- Complementary info (i.e. GCC/Compiler version) : gcc (Debian 7.4.0-6) 7.4.0
Describe the current behavior
The L2COMM parameter Directional_Correction_Option changed from boolean to 'Roy/Lut/None' with 4.3.x. When starting a new run with start_maja, the downloaded GIPPs still contain the former 'true' attribute, which leads to the following error:
2021-02-17 12:32:50 [31091] PROGRESS MAJA 4.3 initialize:479 Starting MAJA_L2_BACKWARD_CHAIN
Traceback (most recent call last):
File "/home/colinj/code/maja/install/maja/4.3.0/lib/python/orchestrator/launcher/maja.py", line 103, in <module>
main()
File "/home/colinj/code/maja/install/maja/4.3.0/lib/python/orchestrator/launcher/maja.py", line 74, in main
lprocessor.pre_processing()
File "/home/colinj/code/maja/install/maja/4.3.0/lib/python/orchestrator/processor/l2_backward_processor.py", line 86, in pre_processing
super(L2BackwardProcessor, self).pre_processing()
File "/home/colinj/code/maja/install/maja/4.3.0/lib/python/orchestrator/processor/l2_processor.py", line 227, in pre_processing
dircormodel = DirectionalCorrection.get_dircorr_method(dircor_model_str)
File "/home/colinj/code/maja/install/maja/4.3.0/lib/python/orchestrator/common/constants.py", line 83, in get_dircorr_method
raise MajaBusinessException("Utilities:GetDirCorrMethod: The Directional Correction model " + str_name + "does not exist.")
NameError: name 'MajaBusinessException' is not defined
Traceback (most recent call last):
File "/home/colinj/code/maja/install/maja/4.3.0/lib/python/StartMaja/Start_maja.py", line 562, in <module>
s.run()
File "/home/colinj/code/maja/install/maja/4.3.0/lib/python/StartMaja/Start_maja.py", line 504, in run
return_code = wp.execute(self.maja, self.dtm, self.gipp, self.userconf)
File "/home/colinj/code/maja/install/maja/4.3.0/lib/python/StartMaja/Chain/Workplan.py", line 219, in execute
return_code = self.launch_maja(maja, wdir=self.wdir, inputdir=self.input_dir, outdir=self.outdir, conf=conf)
File "/home/colinj/code/maja/install/maja/4.3.0/lib/python/StartMaja/Chain/Workplan.py", line 170, in launch_maja
return FileSystem.run_external_app(maja, args, logfile=logfile, skip_error=self.skip_errors)
File "/home/colinj/code/maja/install/maja/4.3.0/lib/python/StartMaja/Common/FileSystem.py", line 188, in run_external_app
raise subprocess.CalledProcessError(return_code, cmd)
subprocess.CalledProcessError: Command '/home/colinj/code/maja/install/maja/4.3.0/bin/maja -w /home/colinj/tmp/Start_maja_7998dad6c90e52d1b9661d70ef573a6d/maja_working_directory --input /home/colinj/tmp/Start_maja_7998dad6c90e52d1b9661d70ef573a6d --output /home/colinj/data/S2_L2A_120m/Alpes_cams/32TPR --mode L2BACKWARD -ucs /home/colinj/code/maja/install/maja/4.3.0/lib/python/StartMaja/userconf --TileId 32TPR --loglevel PROGRESS' returned non-zero exit status 1.
Describe the expected behavior
We could tag a dedicated 4.3 compliant GIPP version in the repository, but this error would still happen to users who update their code from 4.2.x to 4.3.x without removing pre-existing GIPP folder. I'd suggest we assume that a L2COMM that contains the former 'true' value activates 'Roy' by default, such that the following:
<Directional_Correction_Option>true</Directional_Correction_Option>
would be equivalent to:
<Directional_Correction_Option>Roy</Directional_Correction_Option>
Urgency/Criticity
- Urgency (Select Low/Medium/High): Medium
- Criticity (Select Low/Medium/High): Medium
Code to reproduce the issue
Any run using release 4.3.0 with start_maja, starting from empty GIPP directory.
Correction
(Optional) Provide a version number (Major.Minor.Patch, e.g. 3.2.1) when the correction shall be introduced.