villano-lab / nrCascadeSim

calculating the NR spectrum resulting from neutron-capture cascades.
MIT License
0 stars 1 forks source link

[JOSS Pre-Review]: Main executable example fails #48

Closed villaa closed 2 years ago

villaa commented 2 years ago

The first example that a user encounters in the Executables of nrCascadeSim section of the docs fails. It will run without producing warning or errors, but if run from the top level of the project repo so that levelfiles/Si28_ngam_all_cascades_rfmt_sorted.txt is in the given example path the content of the resulting ROOT TTree in the file is empty

# realizeCascades --verbose -n 100000 -o output.root levelfiles/Si28_ngam_all_cascades_rfmt_sorted.txt
levelfiles/Si28_ngam_all_cascades_rfmt_sorted.txt
Seed used: 339870340
MTRand: 0x55c868a47d70
# ls -lh output.root
-rw-r--r-- 1 root root 4.6K Dec 10 07:08 output.root
# root -l output.root
root [0]
Attaching file output.root as _file0...
(TFile *) 0x55c3f3ee8dc0
root [1] _file0->ls()
TFile**     output.root
 TFile*     output.root
  KEY: TTree    cascade;1   cascade
root [2] cascade->Print()
******************************************************************************
*Tree    :cascade   : cascade                                                *
*Entries :        0 : Total =             329 bytes  File  Size =        188 *
*        :          : Tree compression factor =   1.00                       *
******************************************************************************
root [3]

This doesn't seem correct given that the example says it will:

simulate 100000 events for 28Si and output them to a file...

As the project includes over 30 levelfiles it would be nice to show specific run examples and output in the docs as well rather than just example source.

villaa commented 2 years ago

@matthewfeickert I cannot reproduce this--please include your system specs.

matthewfeickert commented 2 years ago

It is the Docker image included in the summary. https://github.com/openjournals/joss-reviews/issues/3932#issuecomment-990735982

Though it is nothing specific to that Docker image, as I can reproduce the same thing locally.

Full example: ```console $ git clone --depth 1 https://github.com/villano-lab/nrCascadeSim.git --branch v1.2.3 --single-branch Cloning into 'nrCascadeSim'... remote: Enumerating objects: 189, done. remote: Counting objects: 100% (189/189), done. remote: Compressing objects: 100% (172/172), done. remote: Total 189 (delta 16), reused 139 (delta 11), pack-reused 0 Receiving objects: 100% (189/189), 3.78 MiB | 12.62 MiB/s, done. Resolving deltas: 100% (16/16), done. Note: switching to '59d756c592dc0801340876e803c4a5393d6b0cc0'. You are in 'detached HEAD' state. You can look around, make experimental changes and commit them, and you can discard any commits you make in this state without impacting any branches by switching back to a branch. If you want to create a new branch to retain commits you create, you may do so (now or later) by using -c with the switch command. Example: git switch -c Or undo this operation with: git switch - Turn off this advice by setting config variable advice.detachedHead to false (base) feickert@ThinkPad-X1:/tmp$ cd nrCascadeSim/ (base) feickert@ThinkPad-X1:/tmp/nrCascadeSim$ root --version ROOT Version: 6.24/02 Built for linuxx8664gcc on Jul 20 2021, 13:40:00 From tags/v6-24-02@v6-24-02 (base) feickert@ThinkPad-X1:/tmp/nrCascadeSim$ root-config --cflags -pthread -std=c++17 -m64 -I/home/feickert/bin/root-cern/include (base) feickert@ThinkPad-X1:/tmp/nrCascadeSim$ make g++ -fPIC -c -D__GIT_VERSION=\"v1.2.3\" -IMersenne -Iinc src//isotope_info.c `root-config --cflags --glibs` -std=c++14 -L. -L/tmp/nrCascadeSim/bin/lib mv isotope_info.o /tmp/nrCascadeSim/bin/lib/ g++ -fPIC -c -D__GIT_VERSION=\"v1.2.3\" -IMersenne -Iinc src//weisskopf.c `root-config --cflags --glibs` -std=c++14 -L. -L/tmp/nrCascadeSim/bin/lib mv weisskopf.o /tmp/nrCascadeSim/bin/lib/ g++ -fPIC -c -D__GIT_VERSION=\"v1.2.3\" -IMersenne -Iinc src//lindhard.c `root-config --cflags --glibs` -std=c++14 -L. -L/tmp/nrCascadeSim/bin/lib mv lindhard.o /tmp/nrCascadeSim/bin/lib/ g++ -fPIC -c -D__GIT_VERSION=\"v1.2.3\" -IMersenne -Iinc src//cascadeProd.c `root-config --cflags --glibs` -std=c++14 -L. -L/tmp/nrCascadeSim/bin/lib src//cascadeProd.c: In function ‘cri* Cascade(int, int, double, int, double*, double*, double, MTRand*)’: src//cascadeProd.c:1113:1: warning: control reaches end of non-void function [-Wreturn-type] 1113 | } | ^ mv cascadeProd.o /tmp/nrCascadeSim/bin/lib/ g++ -fPIC -c -D__GIT_VERSION=\"v1.2.3\" -IMersenne -Iinc src//edepmath.c `root-config --cflags --glibs` -std=c++14 -L. -L/tmp/nrCascadeSim/bin/lib mv edepmath.o /tmp/nrCascadeSim/bin/lib/ g++ -fPIC -c -D__GIT_VERSION=\"v1.2.3\" -IMersenne -Iinc src//rootUtil.c `root-config --cflags --glibs` -std=c++14 -L. -L/tmp/nrCascadeSim/bin/lib In file included from /home/feickert/bin/root-cern/include/TString.h:29, from /home/feickert/bin/root-cern/include/TNamed.h:26, from /home/feickert/bin/root-cern/include/TDictionary.h:44, from /home/feickert/bin/root-cern/include/TClass.h:23, from /home/feickert/bin/root-cern/include/TTree.h:36, from inc/rootUtil.h:3, from src//rootUtil.c:8: /home/feickert/bin/root-cern/include/ROOT/RStringView.hxx:84:17: error: expected type-specifier 84 | operator std::string_view() const { return std::string_view(fData,fLength); } | ^~~ In file included from /home/feickert/bin/root-cern/include/TNamed.h:26, from /home/feickert/bin/root-cern/include/TDictionary.h:44, from /home/feickert/bin/root-cern/include/TClass.h:23, from /home/feickert/bin/root-cern/include/TTree.h:36, from inc/rootUtil.h:3, from src//rootUtil.c:8: /home/feickert/bin/root-cern/include/TString.h:115:13: error: expected type-specifier 115 | operator std::string_view() const { return std::string_view(Data(),fExtent); } | ^~~ /home/feickert/bin/root-cern/include/TString.h:280:32: error: ‘string_view’ in namespace ‘std’ does not name a type 280 | explicit TString(const std::string_view &sub); | ^~~~~~~~~~~ /home/feickert/bin/root-cern/include/TString.h:280:27: note: ‘std::string_view’ is only available from C++17 onwards 280 | explicit TString(const std::string_view &sub); | ^~~ /home/feickert/bin/root-cern/include/TString.h:317:37: error: ‘string_view’ in namespace ‘std’ does not name a type 317 | TString &operator=(const std::string_view &s); | ^~~~~~~~~~~ /home/feickert/bin/root-cern/include/TString.h:317:32: note: ‘std::string_view’ is only available from C++17 onwards 317 | TString &operator=(const std::string_view &s); | ^~~ /home/feickert/bin/root-cern/include/TString.h:444:9: error: ‘string_view’ in namespace ‘std’ does not name a type 444 | std::string_view View() const { return std::string_view(GetPointer(),Length()); } | ^~~~~~~~~~~ /home/feickert/bin/root-cern/include/TString.h:444:4: note: ‘std::string_view’ is only available from C++17 onwards 444 | std::string_view View() const { return std::string_view(GetPointer(),Length()); } | ^~~ In file included from /home/feickert/bin/root-cern/include/TNamed.h:26, from /home/feickert/bin/root-cern/include/TDictionary.h:44, from /home/feickert/bin/root-cern/include/TClass.h:23, from /home/feickert/bin/root-cern/include/TTree.h:36, from inc/rootUtil.h:3, from src//rootUtil.c:8: /home/feickert/bin/root-cern/include/TString.h:839:53: error: ‘string_view’ in namespace ‘std’ does not name a type 839 | inline Bool_t operator==(const char *s1, const std::string_view &s2) | ^~~~~~~~~~~ /home/feickert/bin/root-cern/include/TString.h:839:48: note: ‘std::string_view’ is only available from C++17 onwards 839 | inline Bool_t operator==(const char *s1, const std::string_view &s2) | ^~~ /home/feickert/bin/root-cern/include/TString.h:839:15: error: ‘Bool_t operator==(const char*, const int&)’ must have an argument of class or enumerated type 839 | inline Bool_t operator==(const char *s1, const std::string_view &s2) | ^~~~~~~~ /home/feickert/bin/root-cern/include/TString.h:844:37: error: ‘string_view’ in namespace ‘std’ does not name a type 844 | inline Bool_t operator==(const std::string_view &s1, const char *s2) | ^~~~~~~~~~~ /home/feickert/bin/root-cern/include/TString.h:844:32: note: ‘std::string_view’ is only available from C++17 onwards 844 | inline Bool_t operator==(const std::string_view &s1, const char *s2) | ^~~ /home/feickert/bin/root-cern/include/TString.h:844:15: error: ‘Bool_t operator==(const int&, const char*)’ must have an argument of class or enumerated type 844 | inline Bool_t operator==(const std::string_view &s1, const char *s2) | ^~~~~~~~ /home/feickert/bin/root-cern/include/TString.h:857:37: error: ‘string_view’ in namespace ‘std’ does not name a type 857 | std::string printValue(const std::string_view* val); | ^~~~~~~~~~~ /home/feickert/bin/root-cern/include/TString.h:857:32: note: ‘std::string_view’ is only available from C++17 onwards 857 | std::string printValue(const std::string_view* val); | ^~~ In file included from inc/rootUtil.h:4, from src//rootUtil.c:8: /home/feickert/bin/root-cern/include/TFile.h:327:45: error: ‘std::string_view’ has not been declared 327 | static Bool_t SetCacheFileDir(std::string_view cacheDir, Bool_t operateDisconnected = kTRUE, | ^~~~~~~~~~~ /home/feickert/bin/root-cern/include/TFile.h: In static member function ‘static Bool_t TFile::SetCacheFileDir(ROOT::Internal::TStringView, Bool_t, Bool_t)’: /home/feickert/bin/root-cern/include/TFile.h:326:36: error: ‘string_view’ is not a member of ‘std’ 326 | { return SetCacheFileDir(std::string_view(cacheDir), operateDisconnected, forceCacheread); } | ^~~~~~~~~~~ /home/feickert/bin/root-cern/include/TFile.h:326:36: note: ‘std::string_view’ is only available from C++17 onwards make: *** [Makefile:39: /tmp/nrCascadeSim/bin/lib/rootUtil.o] Error 1 (base) feickert@ThinkPad-X1:/tmp/nrCascadeSim$ sed -i 's/c++14/c++17/g' Makefile (base) feickert@ThinkPad-X1:/tmp/nrCascadeSim$ make clean && make rm -f /tmp/nrCascadeSim/bin/lib/*.o rm -f /tmp/nrCascadeSim/bin/lib/*.so rm -f /tmp/nrCascadeSim/bin/realizeCascades rm -f /usr/local/bin/realizeCascades rm -f *.o rm -f *.so rm -rf /tmp/nrCascadeSim/bin/lib g++ -fPIC -c -D__GIT_VERSION=\"v1.2.3\" -IMersenne -Iinc src//isotope_info.c `root-config --cflags --glibs` -std=c++17 -L. -L/tmp/nrCascadeSim/bin/lib mv isotope_info.o /tmp/nrCascadeSim/bin/lib/ g++ -fPIC -c -D__GIT_VERSION=\"v1.2.3\" -IMersenne -Iinc src//weisskopf.c `root-config --cflags --glibs` -std=c++17 -L. -L/tmp/nrCascadeSim/bin/lib mv weisskopf.o /tmp/nrCascadeSim/bin/lib/ g++ -fPIC -c -D__GIT_VERSION=\"v1.2.3\" -IMersenne -Iinc src//lindhard.c `root-config --cflags --glibs` -std=c++17 -L. -L/tmp/nrCascadeSim/bin/lib In file included from src//lindhard.c:5: Mersenne/MersenneTwister.h: In member function ‘MTRand::uint32 MTRand::randInt()’: Mersenne/MersenneTwister.h:187:18: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 187 | register uint32 s1; | ^~ Mersenne/MersenneTwister.h: In member function ‘void MTRand::seed(MTRand::uint32*, MTRand::uint32)’: Mersenne/MersenneTwister.h:232:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 232 | register int i = 1; | ^ Mersenne/MersenneTwister.h:233:18: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 233 | register uint32 j = 0; | ^ Mersenne/MersenneTwister.h:234:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 234 | register int k = ( N > seedLength ? N : seedLength ); | ^ Mersenne/MersenneTwister.h: In member function ‘void MTRand::seed()’: Mersenne/MersenneTwister.h:269:20: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 269 | register uint32 *s = bigSeed; | ^ Mersenne/MersenneTwister.h:270:16: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 270 | register int i = N; | ^ Mersenne/MersenneTwister.h:271:17: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 271 | register bool success = true; | ^~~~~~~ Mersenne/MersenneTwister.h: In member function ‘void MTRand::initialize(MTRand::uint32)’: Mersenne/MersenneTwister.h:289:19: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 289 | register uint32 *s = state; | ^ Mersenne/MersenneTwister.h:290:19: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 290 | register uint32 *r = state; | ^ Mersenne/MersenneTwister.h:291:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 291 | register int i = 1; | ^ Mersenne/MersenneTwister.h: In member function ‘void MTRand::reload()’: Mersenne/MersenneTwister.h:305:19: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 305 | register uint32 *p = state; | ^ Mersenne/MersenneTwister.h:306:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 306 | register int i; | ^ Mersenne/MersenneTwister.h: In member function ‘void MTRand::save(MTRand::uint32*) const’: Mersenne/MersenneTwister.h:345:19: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 345 | register uint32 *sa = saveArray; | ^~ Mersenne/MersenneTwister.h:346:25: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 346 | register const uint32 *s = state; | ^ Mersenne/MersenneTwister.h:347:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 347 | register int i = N; | ^ Mersenne/MersenneTwister.h: In member function ‘void MTRand::load(MTRand::uint32*)’: Mersenne/MersenneTwister.h:355:19: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 355 | register uint32 *s = state; | ^ Mersenne/MersenneTwister.h:356:19: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 356 | register uint32 *la = loadArray; | ^~ Mersenne/MersenneTwister.h:357:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 357 | register int i = N; | ^ Mersenne/MersenneTwister.h: In function ‘std::ostream& operator<<(std::ostream&, const MTRand&)’: Mersenne/MersenneTwister.h:366:33: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 366 | register const MTRand::uint32 *s = mtrand.state; | ^ Mersenne/MersenneTwister.h:367:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 367 | register int i = mtrand.N; | ^ Mersenne/MersenneTwister.h: In function ‘std::istream& operator>>(std::istream&, MTRand&)’: Mersenne/MersenneTwister.h:375:27: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 375 | register MTRand::uint32 *s = mtrand.state; | ^ Mersenne/MersenneTwister.h:376:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 376 | register int i = mtrand.N; | ^ mv lindhard.o /tmp/nrCascadeSim/bin/lib/ g++ -fPIC -c -D__GIT_VERSION=\"v1.2.3\" -IMersenne -Iinc src//cascadeProd.c `root-config --cflags --glibs` -std=c++17 -L. -L/tmp/nrCascadeSim/bin/lib In file included from inc/lindhard.h:1, from src//cascadeProd.c:9: Mersenne/MersenneTwister.h: In member function ‘MTRand::uint32 MTRand::randInt()’: Mersenne/MersenneTwister.h:187:18: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 187 | register uint32 s1; | ^~ Mersenne/MersenneTwister.h: In member function ‘void MTRand::seed(MTRand::uint32*, MTRand::uint32)’: Mersenne/MersenneTwister.h:232:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 232 | register int i = 1; | ^ Mersenne/MersenneTwister.h:233:18: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 233 | register uint32 j = 0; | ^ Mersenne/MersenneTwister.h:234:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 234 | register int k = ( N > seedLength ? N : seedLength ); | ^ Mersenne/MersenneTwister.h: In member function ‘void MTRand::seed()’: Mersenne/MersenneTwister.h:269:20: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 269 | register uint32 *s = bigSeed; | ^ Mersenne/MersenneTwister.h:270:16: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 270 | register int i = N; | ^ Mersenne/MersenneTwister.h:271:17: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 271 | register bool success = true; | ^~~~~~~ Mersenne/MersenneTwister.h: In member function ‘void MTRand::initialize(MTRand::uint32)’: Mersenne/MersenneTwister.h:289:19: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 289 | register uint32 *s = state; | ^ Mersenne/MersenneTwister.h:290:19: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 290 | register uint32 *r = state; | ^ Mersenne/MersenneTwister.h:291:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 291 | register int i = 1; | ^ Mersenne/MersenneTwister.h: In member function ‘void MTRand::reload()’: Mersenne/MersenneTwister.h:305:19: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 305 | register uint32 *p = state; | ^ Mersenne/MersenneTwister.h:306:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 306 | register int i; | ^ Mersenne/MersenneTwister.h: In member function ‘void MTRand::save(MTRand::uint32*) const’: Mersenne/MersenneTwister.h:345:19: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 345 | register uint32 *sa = saveArray; | ^~ Mersenne/MersenneTwister.h:346:25: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 346 | register const uint32 *s = state; | ^ Mersenne/MersenneTwister.h:347:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 347 | register int i = N; | ^ Mersenne/MersenneTwister.h: In member function ‘void MTRand::load(MTRand::uint32*)’: Mersenne/MersenneTwister.h:355:19: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 355 | register uint32 *s = state; | ^ Mersenne/MersenneTwister.h:356:19: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 356 | register uint32 *la = loadArray; | ^~ Mersenne/MersenneTwister.h:357:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 357 | register int i = N; | ^ Mersenne/MersenneTwister.h: In function ‘std::ostream& operator<<(std::ostream&, const MTRand&)’: Mersenne/MersenneTwister.h:366:33: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 366 | register const MTRand::uint32 *s = mtrand.state; | ^ Mersenne/MersenneTwister.h:367:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 367 | register int i = mtrand.N; | ^ Mersenne/MersenneTwister.h: In function ‘std::istream& operator>>(std::istream&, MTRand&)’: Mersenne/MersenneTwister.h:375:27: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 375 | register MTRand::uint32 *s = mtrand.state; | ^ Mersenne/MersenneTwister.h:376:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 376 | register int i = mtrand.N; | ^ src//cascadeProd.c: In function ‘cri* Cascade(int, int, double, int, double*, double*, double, MTRand*)’: src//cascadeProd.c:1113:1: warning: control reaches end of non-void function [-Wreturn-type] 1113 | } | ^ mv cascadeProd.o /tmp/nrCascadeSim/bin/lib/ g++ -fPIC -c -D__GIT_VERSION=\"v1.2.3\" -IMersenne -Iinc src//edepmath.c `root-config --cflags --glibs` -std=c++17 -L. -L/tmp/nrCascadeSim/bin/lib In file included from inc/edepmath.h:1, from src//edepmath.c:8: Mersenne/MersenneTwister.h: In member function ‘MTRand::uint32 MTRand::randInt()’: Mersenne/MersenneTwister.h:187:18: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 187 | register uint32 s1; | ^~ Mersenne/MersenneTwister.h: In member function ‘void MTRand::seed(MTRand::uint32*, MTRand::uint32)’: Mersenne/MersenneTwister.h:232:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 232 | register int i = 1; | ^ Mersenne/MersenneTwister.h:233:18: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 233 | register uint32 j = 0; | ^ Mersenne/MersenneTwister.h:234:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 234 | register int k = ( N > seedLength ? N : seedLength ); | ^ Mersenne/MersenneTwister.h: In member function ‘void MTRand::seed()’: Mersenne/MersenneTwister.h:269:20: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 269 | register uint32 *s = bigSeed; | ^ Mersenne/MersenneTwister.h:270:16: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 270 | register int i = N; | ^ Mersenne/MersenneTwister.h:271:17: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 271 | register bool success = true; | ^~~~~~~ Mersenne/MersenneTwister.h: In member function ‘void MTRand::initialize(MTRand::uint32)’: Mersenne/MersenneTwister.h:289:19: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 289 | register uint32 *s = state; | ^ Mersenne/MersenneTwister.h:290:19: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 290 | register uint32 *r = state; | ^ Mersenne/MersenneTwister.h:291:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 291 | register int i = 1; | ^ Mersenne/MersenneTwister.h: In member function ‘void MTRand::reload()’: Mersenne/MersenneTwister.h:305:19: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 305 | register uint32 *p = state; | ^ Mersenne/MersenneTwister.h:306:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 306 | register int i; | ^ Mersenne/MersenneTwister.h: In member function ‘void MTRand::save(MTRand::uint32*) const’: Mersenne/MersenneTwister.h:345:19: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 345 | register uint32 *sa = saveArray; | ^~ Mersenne/MersenneTwister.h:346:25: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 346 | register const uint32 *s = state; | ^ Mersenne/MersenneTwister.h:347:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 347 | register int i = N; | ^ Mersenne/MersenneTwister.h: In member function ‘void MTRand::load(MTRand::uint32*)’: Mersenne/MersenneTwister.h:355:19: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 355 | register uint32 *s = state; | ^ Mersenne/MersenneTwister.h:356:19: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 356 | register uint32 *la = loadArray; | ^~ Mersenne/MersenneTwister.h:357:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 357 | register int i = N; | ^ Mersenne/MersenneTwister.h: In function ‘std::ostream& operator<<(std::ostream&, const MTRand&)’: Mersenne/MersenneTwister.h:366:33: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 366 | register const MTRand::uint32 *s = mtrand.state; | ^ Mersenne/MersenneTwister.h:367:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 367 | register int i = mtrand.N; | ^ Mersenne/MersenneTwister.h: In function ‘std::istream& operator>>(std::istream&, MTRand&)’: Mersenne/MersenneTwister.h:375:27: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 375 | register MTRand::uint32 *s = mtrand.state; | ^ Mersenne/MersenneTwister.h:376:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 376 | register int i = mtrand.N; | ^ mv edepmath.o /tmp/nrCascadeSim/bin/lib/ g++ -fPIC -c -D__GIT_VERSION=\"v1.2.3\" -IMersenne -Iinc src//rootUtil.c `root-config --cflags --glibs` -std=c++17 -L. -L/tmp/nrCascadeSim/bin/lib In file included from inc/cascadeProd.h:1, from inc/rootUtil.h:7, from src//rootUtil.c:8: Mersenne/MersenneTwister.h: In member function ‘MTRand::uint32 MTRand::randInt()’: Mersenne/MersenneTwister.h:187:18: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 187 | register uint32 s1; | ^~ Mersenne/MersenneTwister.h: In member function ‘void MTRand::seed(MTRand::uint32*, MTRand::uint32)’: Mersenne/MersenneTwister.h:232:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 232 | register int i = 1; | ^ Mersenne/MersenneTwister.h:233:18: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 233 | register uint32 j = 0; | ^ Mersenne/MersenneTwister.h:234:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 234 | register int k = ( N > seedLength ? N : seedLength ); | ^ Mersenne/MersenneTwister.h: In member function ‘void MTRand::seed()’: Mersenne/MersenneTwister.h:269:20: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 269 | register uint32 *s = bigSeed; | ^ Mersenne/MersenneTwister.h:270:16: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 270 | register int i = N; | ^ Mersenne/MersenneTwister.h:271:17: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 271 | register bool success = true; | ^~~~~~~ Mersenne/MersenneTwister.h: In member function ‘void MTRand::initialize(MTRand::uint32)’: Mersenne/MersenneTwister.h:289:19: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 289 | register uint32 *s = state; | ^ Mersenne/MersenneTwister.h:290:19: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 290 | register uint32 *r = state; | ^ Mersenne/MersenneTwister.h:291:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 291 | register int i = 1; | ^ Mersenne/MersenneTwister.h: In member function ‘void MTRand::reload()’: Mersenne/MersenneTwister.h:305:19: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 305 | register uint32 *p = state; | ^ Mersenne/MersenneTwister.h:306:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 306 | register int i; | ^ Mersenne/MersenneTwister.h: In member function ‘void MTRand::save(MTRand::uint32*) const’: Mersenne/MersenneTwister.h:345:19: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 345 | register uint32 *sa = saveArray; | ^~ Mersenne/MersenneTwister.h:346:25: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 346 | register const uint32 *s = state; | ^ Mersenne/MersenneTwister.h:347:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 347 | register int i = N; | ^ Mersenne/MersenneTwister.h: In member function ‘void MTRand::load(MTRand::uint32*)’: Mersenne/MersenneTwister.h:355:19: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 355 | register uint32 *s = state; | ^ Mersenne/MersenneTwister.h:356:19: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 356 | register uint32 *la = loadArray; | ^~ Mersenne/MersenneTwister.h:357:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 357 | register int i = N; | ^ Mersenne/MersenneTwister.h: In function ‘std::ostream& operator<<(std::ostream&, const MTRand&)’: Mersenne/MersenneTwister.h:366:33: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 366 | register const MTRand::uint32 *s = mtrand.state; | ^ Mersenne/MersenneTwister.h:367:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 367 | register int i = mtrand.N; | ^ Mersenne/MersenneTwister.h: In function ‘std::istream& operator>>(std::istream&, MTRand&)’: Mersenne/MersenneTwister.h:375:27: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 375 | register MTRand::uint32 *s = mtrand.state; | ^ Mersenne/MersenneTwister.h:376:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 376 | register int i = mtrand.N; | ^ mv rootUtil.o /tmp/nrCascadeSim/bin/lib/ g++ -fPIC -shared /tmp/nrCascadeSim/bin/lib/lindhard.o /tmp/nrCascadeSim/bin/lib/weisskopf.o /tmp/nrCascadeSim/bin/lib/isotope_info.o /tmp/nrCascadeSim/bin/lib/cascadeProd.o /tmp/nrCascadeSim/bin/lib/edepmath.o /tmp/nrCascadeSim/bin/lib/rootUtil.o `root-config --cflags --glibs` -std=c++17 -o /tmp/nrCascadeSim/bin/lib/libncap.so g++ -fPIC -Wl,-rpath /tmp/nrCascadeSim/bin/lib -D__GIT_VERSION=\"v1.2.3\" -IMersenne -Iinc -L. -L/tmp/nrCascadeSim/bin/lib /tmp/nrCascadeSim/bin/realizeCascades.cpp `root-config --cflags --glibs` -std=c++17 -lncap -o /tmp/nrCascadeSim/bin/realizeCascades In file included from inc/cascadeProd.h:1, from /tmp/nrCascadeSim/bin/realizeCascades.cpp:29: Mersenne/MersenneTwister.h: In member function ‘MTRand::uint32 MTRand::randInt()’: Mersenne/MersenneTwister.h:187:18: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 187 | register uint32 s1; | ^~ Mersenne/MersenneTwister.h: In member function ‘void MTRand::seed(MTRand::uint32*, MTRand::uint32)’: Mersenne/MersenneTwister.h:232:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 232 | register int i = 1; | ^ Mersenne/MersenneTwister.h:233:18: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 233 | register uint32 j = 0; | ^ Mersenne/MersenneTwister.h:234:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 234 | register int k = ( N > seedLength ? N : seedLength ); | ^ Mersenne/MersenneTwister.h: In member function ‘void MTRand::seed()’: Mersenne/MersenneTwister.h:269:20: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 269 | register uint32 *s = bigSeed; | ^ Mersenne/MersenneTwister.h:270:16: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 270 | register int i = N; | ^ Mersenne/MersenneTwister.h:271:17: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 271 | register bool success = true; | ^~~~~~~ Mersenne/MersenneTwister.h: In member function ‘void MTRand::initialize(MTRand::uint32)’: Mersenne/MersenneTwister.h:289:19: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 289 | register uint32 *s = state; | ^ Mersenne/MersenneTwister.h:290:19: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 290 | register uint32 *r = state; | ^ Mersenne/MersenneTwister.h:291:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 291 | register int i = 1; | ^ Mersenne/MersenneTwister.h: In member function ‘void MTRand::reload()’: Mersenne/MersenneTwister.h:305:19: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 305 | register uint32 *p = state; | ^ Mersenne/MersenneTwister.h:306:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 306 | register int i; | ^ Mersenne/MersenneTwister.h: In member function ‘void MTRand::save(MTRand::uint32*) const’: Mersenne/MersenneTwister.h:345:19: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 345 | register uint32 *sa = saveArray; | ^~ Mersenne/MersenneTwister.h:346:25: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 346 | register const uint32 *s = state; | ^ Mersenne/MersenneTwister.h:347:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 347 | register int i = N; | ^ Mersenne/MersenneTwister.h: In member function ‘void MTRand::load(MTRand::uint32*)’: Mersenne/MersenneTwister.h:355:19: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 355 | register uint32 *s = state; | ^ Mersenne/MersenneTwister.h:356:19: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 356 | register uint32 *la = loadArray; | ^~ Mersenne/MersenneTwister.h:357:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 357 | register int i = N; | ^ Mersenne/MersenneTwister.h: In function ‘std::ostream& operator<<(std::ostream&, const MTRand&)’: Mersenne/MersenneTwister.h:366:33: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 366 | register const MTRand::uint32 *s = mtrand.state; | ^ Mersenne/MersenneTwister.h:367:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 367 | register int i = mtrand.N; | ^ Mersenne/MersenneTwister.h: In function ‘std::istream& operator>>(std::istream&, MTRand&)’: Mersenne/MersenneTwister.h:375:27: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 375 | register MTRand::uint32 *s = mtrand.state; | ^ Mersenne/MersenneTwister.h:376:15: warning: ISO C++17 does not allow ‘register’ storage class specifier [-Wregister] 376 | register int i = mtrand.N; | (base) feickert@ThinkPad-X1:/tmp/nrCascadeSim$ ./bin/realizeCascades --verbose -n 100000 -o output.root levelfiles/Si28_ngam_all_cascades_rfmt_sorted.txt levelfiles/Si28_ngam_all_cascades_rfmt_sorted.txt Seed used: 1790478553 MTRand: 0x55fe2f2c4e40 (base) feickert@ThinkPad-X1:/tmp/nrCascadeSim$ root -l output.root root [0] Attaching file output.root as _file0... (TFile *) 0x55b030883b80 root [1] _file0->ls() TFile** output.root TFile* output.root KEY: TTree cascade;1 cascade root [2] cascade->Print() ****************************************************************************** *Tree :cascade : cascade * *Entries : 0 : Total = 329 bytes File Size = 188 * * : : Tree compression factor = 1.00 * ****************************************************************************** root [3] .q ```
villaa commented 2 years ago

Ok, that's docker image made by:

docker run --rm -ti -v $PWD:$PWD -w $PWD atlasamglab/stats-base:root6.24.06

matthewfeickert commented 2 years ago

If you run though the example I posted in full it seems that the MersenneTwister code that you vendor is not C++17 compliant. If you aren't going to support anything above c++14 that need to be made clear in the project, but that also means that the software is severely limited.

villaa commented 2 years ago

If you run though the example I posted in full it seems that the MersenneTwister code that you vendor is not C++17 compliant. If you aren't going to support anything above c++14 that need to be made clear in the project, but that also means that the software is severely limited.

yes, we understand this issue. There is a separate issue in github about it (#27). And it is also the reason for the "hard-coding" in the Makefile. The team doesn't currently care about compatibility with a wide range of compilers, so I'm trying not to spend time on that; and the API for the new MT seems to have changed. But it may be inevitable that all these issues depend on #27

matthewfeickert commented 2 years ago

The team doesn't currently care about compatibility with a wide range of compilers, so I'm trying not to spend time on that

Hopefully the other issues will resolve this en route, as the current pinning to c++14 limits the general use of the software.

Now that I think more about it though, this behavior is just weird and I think shows a bug. Anything written in c++14 should compile in c++17 given that backwards compatibility is a C++ strength, so the fact that things aren't working I think is a sign of buggy behavior (though you may already have this noted in another Issue).

the API for the new MT seems to have changed. But it may be inevitable that all these issues depend on #27

Okay, sounds good as it seems that you have a clear focus on the work that needs to be done there! :+1:

If it helps at all for testing, I've answered part of my question in https://github.com/villano-lab/nrCascadeSim/issues/45#issuecomment-993109070 as it seems that the ROOT team still compiles their Docker releases with the oldest supported version for the time being, even if LCG doesn't.

However, this gives the same failing behavior as I see on c++17

$ docker run --rm -ti rootproject/root:6.24.06-ubuntu20.04 /bin/bash
# apt update -y && apt install -y -qq git
# cd /tmp/
# git clone --depth 1 https://github.com/villano-lab/nrCascadeSim.git --branch v1.2.3 --single-branch
# cd nrCascadeSim/
# root --version
ROOT Version: 6.24/06
Built for linuxx8664gcc on Sep 02 2021, 14:20:23
From tags/v6-24-06@v6-24-06
# root-config --cflags
-pthread -std=c++14 -m64 -I/opt/root/include
# make
g++ -fPIC -c -D__GIT_VERSION=\"v1.2.3\" -IMersenne -Iinc src//isotope_info.c `root-config --cflags --glibs` -std=c++14 -L. -L/tmp/nrCascadeSim/bin/lib
mv isotope_info.o /tmp/nrCascadeSim/bin/lib/
g++ -fPIC -c -D__GIT_VERSION=\"v1.2.3\" -IMersenne -Iinc src//weisskopf.c `root-config --cflags --glibs` -std=c++14 -L. -L/tmp/nrCascadeSim/bin/lib
mv weisskopf.o /tmp/nrCascadeSim/bin/lib/
g++ -fPIC -c -D__GIT_VERSION=\"v1.2.3\" -IMersenne -Iinc src//lindhard.c `root-config --cflags --glibs` -std=c++14 -L. -L/tmp/nrCascadeSim/bin/lib
mv lindhard.o /tmp/nrCascadeSim/bin/lib/
g++ -fPIC -c -D__GIT_VERSION=\"v1.2.3\" -IMersenne -Iinc src//cascadeProd.c `root-config --cflags --glibs` -std=c++14 -L. -L/tmp/nrCascadeSim/bin/lib
src//cascadeProd.c: In function ‘cri* Cascade(int, int, double, int, double*, double*, double, MTRand*)’:
src//cascadeProd.c:1113:1: warning: control reaches end of non-void function [-Wreturn-type]
 1113 | }
      | ^
mv cascadeProd.o /tmp/nrCascadeSim/bin/lib/
g++ -fPIC -c -D__GIT_VERSION=\"v1.2.3\" -IMersenne -Iinc src//edepmath.c `root-config --cflags --glibs` -std=c++14 -L. -L/tmp/nrCascadeSim/bin/lib
mv edepmath.o /tmp/nrCascadeSim/bin/lib/
g++ -fPIC -c -D__GIT_VERSION=\"v1.2.3\" -IMersenne -Iinc src//rootUtil.c `root-config --cflags --glibs` -std=c++14 -L. -L/tmp/nrCascadeSim/bin/lib
mv rootUtil.o /tmp/nrCascadeSim/bin/lib/
g++ -fPIC -shared /tmp/nrCascadeSim/bin/lib/lindhard.o /tmp/nrCascadeSim/bin/lib/weisskopf.o /tmp/nrCascadeSim/bin/lib/isotope_info.o /tmp/nrCascadeSim/bin/lib/cascadeProd.o /tmp/nrCascadeSim/bin/lib/edepmath.o /tmp/nrCascadeSim/bin/lib/rootUtil.o `root-config --cflags --glibs` -std=c++14 -o /tmp/nrCascadeSim/bin/lib/libncap.so
g++ -fPIC -Wl,-rpath /tmp/nrCascadeSim/bin/lib -D__GIT_VERSION=\"v1.2.3\" -IMersenne -Iinc -L. -L/tmp/nrCascadeSim/bin/lib /tmp/nrCascadeSim/bin/realizeCascades.cpp `root-config --cflags --glibs` -std=c++14 -lncap -o /tmp/nrCascadeSim/bin/realizeCascades
# make install
cp /tmp/nrCascadeSim/bin/realizeCascades /usr/local/bin/
# realizeCascades --verbose -n 100000 -o output.root levelfiles/Si28_ngam_all_cascades_rfmt_sorted.txt
levelfiles/Si28_ngam_all_cascades_rfmt_sorted.txt
Seed used: 690075872
MTRand: 0x55ebae093520
root@bf99907b8b24:/tmp/nrCascadeSim# root -l output.root
root [0]
Attaching file output.root as _file0...
(TFile *) 0x55a43e6720d0
root [1] _file0->ls()
TFile**     output.root
 TFile*     output.root
  KEY: TTree    cascade;1   cascade
root [2] cascade->Print()
******************************************************************************
*Tree    :cascade   : cascade                                                *
*Entries :        0 : Total =             329 bytes  File  Size =        200 *
*        :          : Tree compression factor =   1.00                       *
******************************************************************************
root [3]

This also backs up my thoughts from above that there is some buggy behavior in the examples.

villaa commented 2 years ago

I think our solution to issue #12 introduced a bug where the cascades only get written when the verbosity flag is on. This wasn't showing up in the testing because we simply got an md5 sum of the output file, but never check that the output file has data.

matthewfeickert commented 2 years ago

I think our solution to issue #12 introduced a bug where the cascades only get written when the verbosity flag is on.

One final piece of maybe helpful info for debugging: The lack of file content is independent of if --verbose is given or not

# ...continuing in the same Docker image as above in this Issue
root@6cd75515d66f:/tmp/nrCascadeSim# realizeCascades -n 100000 -o output.root levelfiles/Si28_ngam_all_cascades_rfmt_sorted.txt
Seed used: 2054424945
MTRand: 0x5566c46e6520
root@6cd75515d66f:/tmp/nrCascadeSim# realizeCascades --verbose -n 100000 -o output_verbose.root levelfiles/Si28_ngam_all_cascades_rfmt_sorted.txt
levelfiles/Si28_ngam_all_cascades_rfmt_sorted.txt
Seed used: 11983732
MTRand: 0x55ebbbe8b520
root@6cd75515d66f:/tmp/nrCascadeSim# root -l output.root 
root [0] 
Attaching file output.root as _file0...
(TFile *) 0x55f6ed1537d0
root [1] _file0->ls()
TFile**     output.root 
 TFile*     output.root 
  KEY: TTree    cascade;1   cascade
root [2] cascade->Print()
******************************************************************************
*Tree    :cascade   : cascade                                                *
*Entries :        0 : Total =             329 bytes  File  Size =        200 *
*        :          : Tree compression factor =   1.00                       *
******************************************************************************
root [3] .q
root@6cd75515d66f:/tmp/nrCascadeSim# root -l output_verbose.root
root [0] 
Attaching file output_verbose.root as _file0...
(TFile *) 0x55f469baac80
root [1] _file0->ls()
TFile**     output_verbose.root 
 TFile*     output_verbose.root 
  KEY: TTree    cascade;1   cascade
root [2] cascade->Print()
******************************************************************************
*Tree    :cascade   : cascade                                                *
*Entries :        0 : Total =             329 bytes  File  Size =        200 *
*        :          : Tree compression factor =   1.00                       *
******************************************************************************
root [3] 

but I'll stop commenting here and I'll just follow up in the review as you already have things up and tracking again in Issue #12, which is great. :+1:

villaa commented 2 years ago

I think our solution to issue #12 introduced a bug where the cascades only get written when the verbosity flag is on.

One final piece of maybe helpful info for debugging: The lack of file content is independent of if --verbose is given or not

Verbosity has many levels. The bug makes it so results are only printed at level 2 or above. try --verbose=2 or -v2. In any case we are trying to fix the bug in #12 which was re-opened.

matthewfeickert commented 2 years ago

Verbosity has many levels. The bug makes it so results are only printed at level 2 or above. try --verbose=2 or -v2.

Ah okay. :+1: I'd suggest also improving the help for the CLI then as

realizeCascades --help
Usage:  (null) options [ inputfile(s) ]
  -d, --seed          <integer>      seed for random numbers 
  -h, --help                         print usage 
  -n, --numgen        <number>       number of traces to generate 
  -o, --outfile       <filename>     name the output file 
  -s, --silent                       silent, no standard out 
  -v, --verbose       <level>        Print verbose messages at level <level>
  -V, --version                      print version and exit
  -l, --log           <filename>     Log additional output to the specified file. If this option is not used, no logging will occur.

makes it seems like you would use

--verbose 2

which will just run happily doing nothing without giving any errors or warnings. Requiring the = for

--verbose=2

isn't clear at the moment.

villaa commented 2 years ago

We use the GNU getopt, I don't know why the equal sign is required in this post it is claimed that you should be able to do either. However, now that I think about it the final argument to this program has no flag and the argument to --verbose is optional so I don't know how getopt would know the difference between --verbose 2 input_file and --verbose 2 input_file where in the latter case 2 is the name of the first input file (input_file is the second input file) and verbose is given without a "level."

Come to think of it, have we tested the multiple input-file appropriately?

Incidentally there are also some standard behaviors of the --help and --version options that we don't currently respect, so those should probably be upgraded. Note these are GNU software standards.

villaa commented 2 years ago

Note: here is a list of software licenses for the --version output.

villaa commented 2 years ago

here is an example of standard text for the usage output.

nuclearGoblin commented 2 years ago

Currently having the same issue even when using --verbose=2 or --verbose=3.

villaa commented 2 years ago

Currently having the same issue even when using --verbose=2 or --verbose=3.

@gerudo7 which version are you using? I thought I fixed this in v1.2.4 (hotfix)

nuclearGoblin commented 2 years ago

@villaa sorry, was just coming back to update - I thought I'd checked everything before commenting, but it looks like I was using an obsolete levelfile (to be clear - one that was removed from the repository but was left over locally because of some old work). It is working for me now

villaa commented 2 years ago

This was essentially fixed b/c PR #54 allowed PR #57 and now the C++17 on Ubuntu20 is being explicitly tested in Travis and is passing on v1.2.4.