esmolanka / sexp-grammar

Invertible parsing for S-expressions
33 stars 4 forks source link

testsuite & benchmark failed to compile in Stackage Nightly #21

Closed juhp closed 2 years ago

juhp commented 3 years ago
Building benchmark 'sexp-grammar-bench' for sexp-grammar-2.3.3..                             
[1 of 1] Compiling Main                                                                                                     

/var/stackage/work/unpack-dir/unpacked/sexp-grammar-2.3.3-92fcc9c9ea4b87f6c125482378aabe58d12dc6381426282331a902cd47c474d8/bench/Main.hs:161:22: error:
    • Overlapping instances for NFData1                                                                                     
                                  (Sexp.Compose (Sexp.LocatedBy Position) Sexp.SexpF)        
        arising from a use of ‘force’                                                                                       
      Matching instances:                                                                                                   
        two instances involving out-of-scope types                                                                          
        (use -fprint-potential-instances to see them all)                                                                   
    • In the first argument of ‘($)’, namely ‘force’                                                                        
      In the second argument of ‘($)’, namely                                                                               
        ‘force $ either error id (toSexp exprGrammarTH expr)’                                                               
      In a stmt of a 'do' block:                                                                                            
        sexp <- evaluate                                                                                                    
                  $ force $ either error id (toSexp exprGrammarTH expr)                      
    |                                                                                                                       
161 |   sexp <- evaluate $ force $ either error id (toSexp exprGrammarTH expr)               
    |                      ^^^^^                                                                                            
juhp commented 3 years ago

Hmm the testsuite also gave an error actually?:

Test suite failure for package sexp-grammar-2.3.3
    sexp-grammar-test:  executable not found
Full log available at /var/stackage/work/unpack-dir/.stack-work/logs/sexp-grammar-2.3.3-test.log

Test suite executable "sexp-grammar-test not found for sexp-grammar:test:sexp-grammar-test   
Possible causes of this issue:                                                                                              
* No module named "Main". The 'main-is' source file should usually have a header indicating that it's a 'Main' module.
* A cabal file that refers to nonexistent other files (e.g. a license-file that doesn't exist). Running 'cabal check' may po
int out these issues.

Not sure why this happened now.

esmolanka commented 3 years ago

Hm... Thanks. I'm having a look

esmolanka commented 3 years ago

@juhp I believe I've fixed the overlapping instances issue by adding some CPP in 033ea421ae0422a299116697d8b999239b66733f.

W.r.t. the testsuite issue, I am not sure what happened there, too -- I can't reproduce it neither with stack and nightly resolver nor with cabal. Is there anything useful in the logs?

juhp commented 3 years ago

Not that I know - you/we can try to re-enable the testsuite in Stackage if you wish.

esmolanka commented 3 years ago

Thanks -- I'll do a pull request re-enabling both the test suite and the benchmark, then.