Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create Travis continuous build #34

Closed
epost opened this issue Sep 12, 2018 · 18 comments
Closed

Create Travis continuous build #34

epost opened this issue Sep 12, 2018 · 18 comments
Assignees

Comments

@epost
Copy link
Member

epost commented Sep 12, 2018

No description provided.

@tg-x
Copy link
Collaborator

tg-x commented Sep 12, 2018

I'd create a Nix package and let Travis build with Nix.

The alternative would be building with stack: https://docs.haskellstack.org/en/stable/travis_ci/

@epost
Copy link
Member Author

epost commented Sep 13, 2018

Yeah that'd be great!

@tg-x
Copy link
Collaborator

tg-x commented Sep 17, 2018

Got styx working, but then ran into some build issues, any idea what's wrong/missing?

Configuring aql-0.1.0.0...                                                                                                                                                                                                                                                                                                     
Preprocessing library for aql-0.1.0.0..                                                                                                                                                                                                                                                                                        
Building library for aql-0.1.0.0..                                                                                                                                                                                                                                                                                             
[1 of 3] Compiling Language.AQL     ( src/Language/AQL.hs, dist/dist-sandbox-31d5d605/build/Language/AQL.o )                                                                                                                                                                                                                   
                                                                                                                                                                                                                                                                                                                               
src/Language/AQL.hs:246:20: error:                                                                                                                                                                                                                                                                                             
    * Ambiguous type variable `var0' arising from a use of `typeOfCol'                                                                                                                                                                                                                                                         
      prevents the constraint `(Show var0)' from being solved.                                                                                                                                                                                                                                                                 
      Relevant bindings include                                                                                                                                                                                                                                                                                                
        validateTypeside :: Typeside var0 ty0 sym0 -> Err ()                                                                                                                                                                                                                                                                   
          (bound at src/Language/AQL.hs:246:1)                                                                                                                                                                                                                                                                                 
      Probable fix: use a type annotation to specify what `var0' should be.                                                                                                                                                                                                                                                    
      These potential instances exist:                                                                                                                                                                                                                                                                                         
        instance (Show var, Show ty, Show sym, Show en, Show fk, Show att,                                                                                                                                                                                                                                                     
                  Show gen, Show sk, Show x, Show y) =>                                                                                                                                                                                                                                                                        
                 Show (Algebra var ty sym en fk att gen sk x y)                                                                                                                                                                                                                                                                
          -- Defined at src/Language/AQL.hs:489:10                                                                                                                                                                                                                                                                             
        instance (Show sk, Show gen, Show att, Show fk, Show sym, Show ty,                                                                                                                                                                                                                                                     
                  Show en, Show var) =>                                                                                                                                                                                                                                                                                        
                 Show (Collage var ty sym en fk att gen sk)                                                                                                                                                                                                                                                                    
          -- Defined at src/Language/AQL.hs:101:19                                                                                                                                                                                                                                                                             
        instance (Show var, Show ty, Show sym, Show en, Show fk, Show att,                                                                                                                                                                                                                                                     
                  Show gen, Show sk) =>                                                                                                                                                                                                                                                                                        
                 Show (EQ var ty sym en fk att gen sk)                                                                                                                                                                                                                                                                         
          -- Defined at src/Language/AQL.hs:88:10                                                                                                                                                                                                                                                                              
        ...plus 44 others                                                                                                                                                                                                                                                                                                      
        ...plus five instances involving out-of-scope types                                                                                                                                                                                                                                                                    
        (use -fprint-potential-instances to see them all)                                                                                                                                                                                                                                                                      
    * In the first argument of `(.)', namely `typeOfCol'                                                                                                                                                                                                                                                                       
      In the expression: typeOfCol . tsToCol                                                                                                                                                                                                                                                                                   
      In an equation for `validateTypeside':                                                                                                                                                                                                                                                                                   
          validateTypeside = typeOfCol . tsToCol                                                                                                                                                                                                                                                                               
    |                                                                                                                                                                                                                                                                                                                          
246 | validateTypeside = typeOfCol . tsToCol                                                                                                                                                                                                                                                                                   
    |                    ^^^^^^^^^                                                                                                                                                                                                                                                                                             
                                                                                                                                                                                                                                                                                                                               
src/Language/AQL.hs:314:1: error:                                                                                                                                                                                                                                                                                              
    * Could not deduce (Eq var4) arising from a use of `=='                                                                                                                                                                                                                                                                    
      from the context: (Eq var, Eq sym, Eq ty)                                                                                                                                                                                                                                                                                
        bound by the instance declaration at src/Language/AQL.hs:314:1-59                                                                                                                                                                                                                                                      
      The type variable `var4' is ambiguous                                                                                                                                                                                                                                                                                    
      These potential instances exist:                                                                                                                                                                                                                                                                                         
        instance (Eq sk, Eq gen, Eq att, Eq fk, Eq sym, Eq ty, Eq en,                                                                                                                                                                                                                                                          
                  Eq var) =>                                                                                                                                                                                                                                                                                                   
                 Eq (Collage var ty sym en fk att gen sk)                                                                                                                                                                                                                                                                      
          -- Defined at src/Language/AQL.hs:101:15                                                                                                                                                                                                                                                                             
        instance (Eq sk, Eq gen, Eq att, Eq fk, Eq sym, Eq var) =>                                                                                                                                                                                                                                                             
                 Eq (EQ var ty sym en fk att gen sk)                                                                                                                                                                                                                                                                           
          -- Defined at src/Language/AQL.hs:86:91                                                                                                                                                                                                                                                                              
        instance Eq InstExpRaw' -- Defined at src/Language/AQL.hs:737:13                                                                                                                                                                                                                                                       
        ...plus 43 others                                                                                                                                                                                                                                                                                                      
        ...plus five instances involving out-of-scope types                                                                                                                                                                                                                                                                    
        (use -fprint-potential-instances to see them all)                                                                                                                                                                                                                                                                      
    * In the first argument of `not', namely `((==) a b)'                                                                                                                                                                                                                                                                      
      In the expression: not ((==) a b)                                                                                                                                                                                                                                                                                        
      In an equation for `/=': (/=) a b = not ((==) a b)                                                                                                                                                                                                                                                                       
      When typechecking the code for `/='                                                                                                                                                                                                                                                                                      
        in a derived instance for `Eq TypesideExp':                                                                                                                                                                                                                                                                            
        To see the code I am typechecking, use -ddump-deriv                                                                                                                                                                                                                                                                    
    |                                                                                                                                                                                                                                                                                                                          
314 | deriving instance (Eq var, Eq sym, Eq ty) => Eq TypesideExp
src/Language/AQL.hs:315:1: error:
    * Could not deduce (Show var2)
        arising from a use of `GHC.Show.$dmshow'
      from the context: (Show var, Show sym, Show ty)
        bound by the instance declaration at src/Language/AQL.hs:315:1-67
      The type variable `var2' is ambiguous
      These potential instances exist:
        instance (Show var, Show ty, Show sym, Show en, Show fk, Show att,
                  Show gen, Show sk, Show x, Show y) =>
                 Show (Algebra var ty sym en fk att gen sk x y)
          -- Defined at src/Language/AQL.hs:489:10
        instance (Show sk, Show gen, Show att, Show fk, Show sym, Show ty,
                  Show en, Show var) =>
                 Show (Collage var ty sym en fk att gen sk)
          -- Defined at src/Language/AQL.hs:101:19
        instance (Show var, Show ty, Show sym, Show en, Show fk, Show att,
                  Show gen, Show sk) =>
                 Show (EQ var ty sym en fk att gen sk)
          -- Defined at src/Language/AQL.hs:88:10
        ...plus 44 others
        ...plus five instances involving out-of-scope types
        (use -fprint-potential-instances to see them all)
    * In the expression: GHC.Show.$dmshow @TypesideExp
      In an equation for `show': show = GHC.Show.$dmshow @TypesideExp
      When typechecking the code for `show'
        in a derived instance for `Show TypesideExp':
        To see the code I am typechecking, use -ddump-deriv
      In the instance declaration for `Show TypesideExp'
    |
315 | deriving instance (Show var, Show sym, Show ty) => Show TypesideExp
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

src/Language/AQL.hs:315:1: error:
    * Could not deduce (Show var3) arising from a use of `showsPrec'
      from the context: (Show var, Show sym, Show ty)
        bound by the instance declaration at src/Language/AQL.hs:315:1-67
      The type variable `var3' is ambiguous
      These potential instances exist:
        instance (Show var, Show ty, Show sym, Show en, Show fk, Show att,
                  Show gen, Show sk, Show x, Show y) =>
                 Show (Algebra var ty sym en fk att gen sk x y)
          -- Defined at src/Language/AQL.hs:489:10
        instance (Show sk, Show gen, Show att, Show fk, Show sym, Show ty,
                  Show en, Show var) =>
                 Show (Collage var ty sym en fk att gen sk)
          -- Defined at src/Language/AQL.hs:101:19
        instance (Show var, Show ty, Show sym, Show en, Show fk, Show att,
                  Show gen, Show sk) =>
                 Show (EQ var ty sym en fk att gen sk)
          -- Defined at src/Language/AQL.hs:88:10
        ...plus 44 others
        ...plus five instances involving out-of-scope types
        (use -fprint-potential-instances to see them all)
    * In the first argument of `GHC.Show.showList__', namely
        `(showsPrec 0)'
      In the expression: GHC.Show.showList__ (showsPrec 0)
      In an equation for `showList':
          showList = GHC.Show.showList__ (showsPrec 0)
      When typechecking the code for `showList'
        in a derived instance for `Show TypesideExp':
        To see the code I am typechecking, use -ddump-deriv
    |
315 | deriving instance (Show var, Show sym, Show ty) => Show TypesideExp
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

src/Language/AQL.hs:370:18: error:
    * Ambiguous type variable `var1' arising from a use of `typeOfCol'
      prevents the constraint `(Show var1)' from being solved.
      Relevant bindings include
        validateSchema :: Schema var1 ty1 sym1 en0 fk0 att0 -> Err ()
          (bound at src/Language/AQL.hs:370:1)
      Probable fix: use a type annotation to specify what `var1' should be.
      These potential instances exist:
        instance (Show var, Show ty, Show sym, Show en, Show fk, Show att,
                  Show gen, Show sk, Show x, Show y) =>
                 Show (Algebra var ty sym en fk att gen sk x y)
          -- Defined at src/Language/AQL.hs:489:10
        instance (Show sk, Show gen, Show att, Show fk, Show sym, Show ty,
                  Show en, Show var) =>
                 Show (Collage var ty sym en fk att gen sk)
          -- Defined at src/Language/AQL.hs:101:19
        instance (Show var, Show ty, Show sym, Show en, Show fk, Show att,
                  Show gen, Show sk) =>
                 Show (EQ var ty sym en fk att gen sk)
          -- Defined at src/Language/AQL.hs:88:10
        ...plus 44 others
        ...plus five instances involving out-of-scope types
        (use -fprint-potential-instances to see them all)
    * In the first argument of `(.)', namely `typeOfCol'
      In the expression: typeOfCol . schToCol
      In an equation for `validateSchema':
          validateSchema = typeOfCol . schToCol
    |
370 | validateSchema = typeOfCol . schToCol
    |                  ^^^^^^^^^
cabal: Leaving directory '.'
cabal: Error: some packages failed to install:
aql-0.1.0.0-InKZO3mITIm7URSLbTp2t4 failed during the building phase. The
exception was:
ExitFailure 1

@wisnesky
Copy link
Contributor

wisnesky commented Sep 17, 2018 via email

@tg-x
Copy link
Collaborator

tg-x commented Sep 17, 2018

@wisnesky using the master branch here, is that what you mean?

don't see the dozen small files there, though.

@wisnesky
Copy link
Contributor

wisnesky commented Sep 17, 2018 via email

@tg-x
Copy link
Collaborator

tg-x commented Sep 17, 2018

@wisnesky ok, now I see the changes, and could also build it, some tests are failing, though:

Resolving dependencies...                                                                                                                                                                                                                                                                                                     
Configuring aql-0.1.0.0...                                                                                                                                                                                                                                                                                                    
Preprocessing library for aql-0.1.0.0..                                                                                                                                                                                                                                                                                       
Building library for aql-0.1.0.0..                                                                                                                                                                                                                                                                                            
ignoring (possibly broken) abi-depends field for packages                                                                                                                                                                                                                                                                     
Preprocessing test suite 'aql-test' for aql-0.1.0.0..                                                                                                                                                                                                                                                                         
Building test suite 'aql-test' for aql-0.1.0.0..                                                                                                                                                                                                                                                                              
[3 of 4] Compiling AQLSpec          ( test/AQLSpec.hs, dist/build/aql-test/aql-test-tmp/AQLSpec.o )                                                                                                                                                                                                                           
                                                                                                                                                                                                                                                                                                                              
test/AQLSpec.hs:23:33: error:                                                                                                                                                                                                                                                                                                 
    Not in scope: type constructor or class `Schema'                                                                                                                                                                                                                                                                          
   |                                                                                                                                                                                                                                                                                                                          
23 | schemaOne :: (Eq var, Eq fk) => Schema var String String String fk String                                                                                                                                                                                                                                                
   |                                 ^^^^^^                                                                                                                                                                                                                                                                                   
                                                                                                                                                                                                                                                                                                                              
test/AQLSpec.hs:25:84: error:                                                                                                                                                                                                                                                                                                 
    Not in scope: data constructor `EQ'                                                                                                                                                                                                                                                                                       
    Perhaps you want to remove `EQ' from the explicit hiding list                                                                                                                                                                                                                                                             
    in the import of `Prelude' (test/AQLSpec.hs:5:1-44).                                                                                                                                                                                                                                                                      
   |                                                                                                                                                                                                                                                                                                                          
25 |   Schema typesideDom (Set.singleton "A") Map.empty atts' Set.empty Set.empty (\en (EQ (lhs, rhs)) -> lhs == rhs)                                                                                                                                                                                                         
   |                                                                                    ^^                                                                                                                                                                                                                                    
                                                                                                                                                                                                                                                                                                                              
test/AQLSpec.hs:29:24: error:                                                                                                                                                                                                                                                                                                 
    Not in scope: type constructor or class `Schema'                                                                                                                                                                                                                                                                          
   |                                                                                                                                                                                                                                                                                                                          
29 | schemaTwo :: Eq var => Schema var String String String String String                                                                                                                                                                                                                                                     
   |                        ^^^^^^                                                                                                                                                                                                                                                                                            
                                                                                                                                                                                                                                                                                                                              
test/AQLSpec.hs:31:85: error:                                                                                                                                                                                                                                                                                                 
    Not in scope: data constructor `EQ'                                                                                                                                                                                                                                                                                       
    Perhaps you want to remove `EQ' from the explicit hiding list                                                                                                                                                                                                                                                             
    in the import of `Prelude' (test/AQLSpec.hs:5:1-44).                                                                                                                                                                                                                                                                      
   |                                                                                                                                                                                                                                                                                                                          
31 |   Schema typesideDom (Set.fromList ["A", "B"]) atts atts' Set.empty Set.empty (\en (EQ (lhs, rhs)) -> lhs == rhs)                                                                                                                                                                                                        
   |                                                                                     ^^                                                                                                                                                                                                                                   
                                                                                                                                                                                                                                                                                                                              
test/AQLSpec.hs:39:26: error:                                                                                                                                                                                                                                                                                                 
    Not in scope: type constructor or class `Typeside'                                                                                                                                                                                                                                                                        
   |                                                                                                                                                                                                                                                                                                                          
39 | typesideDom :: Eq var => Typeside var String String                                                                                                                                                                                                                                                                      
   |                          ^^^^^^^^                                                                                                                                                                                                                                                                                        
                                                                                                                                                                                                                                                                                                                              
test/AQLSpec.hs:40:67: error:                                                                                                                                                                                                                                                                                                 
    Not in scope: data constructor `EQ'                                                                                                                                                                                                                                                                                       
    Perhaps you want to remove `EQ' from the explicit hiding list                                                                                                                                                                                                                                                             
    in the import of `Prelude' (test/AQLSpec.hs:5:1-44).                                                                                                                                                                                                                                                                      
   |                                                                                                                                                                                                                                                                                                                          
40 | typesideDom = Typeside (Set.singleton "Dom") sym Set.empty (\ctx (EQ (lhs,rhs)) -> lhs == rhs)                                                                                                                                                                                                                           
   |                                                                   ^^                                                                                                                                                                                                                                                     

@wisnesky
Copy link
Contributor

wisnesky commented Sep 17, 2018 via email

@tg-x
Copy link
Collaborator

tg-x commented Sep 17, 2018

I'm using hpack to create a cabal file, then cabal build then cabal test (since styx uses cabal)

@tg-x
Copy link
Collaborator

tg-x commented Sep 17, 2018

@epost @wisnesky one of you also needs to enable travis at https://travis-ci.com/statebox/aql

@wisnesky
Copy link
Contributor

wisnesky commented Sep 17, 2018 via email

@tg-x
Copy link
Collaborator

tg-x commented Sep 17, 2018

yup, that worked:

Building test suite 'aql-test' for aql-0.1.0.0..
[3 of 4] Compiling AQLSpec          ( test/AQLSpec.hs, dist/build/aql-test/aql-test-tmp/AQLSpec.o )
[4 of 4] Compiling Main             ( test/Spec.hs, dist/build/aql-test/aql-test-tmp/Main.o )                                                                 
Linking dist/build/aql-test/aql-test ...                                                                                                                      
Running 1 test suites...                                                                                                                                      
Test suite aql-test: RUNNING...                                                                                                                               
Test suite aql-test: PASS                                                                                                                                     
Test suite logged to: dist/test/aql-0.1.0.0-aql-test.log                                                                                                      
1 of 1 test suites (1 of 1 test cases) passed.                                                                                                                

@tg-x
Copy link
Collaborator

tg-x commented Sep 17, 2018

nix pkgs & travis is config is in place, see 6e9673f,
now only need to enable travis for this repo

@epost epost self-assigned this Sep 17, 2018
@epost
Copy link
Member Author

epost commented Sep 17, 2018

Done! @tg-x, you rock!! 🤘

@tg-x
Copy link
Collaborator

tg-x commented Sep 17, 2018

@epost seems something is still missing..

here it says build is queued but it does not start building it:
https://github.com/statebox/aql/pull/36/checks

@epost
Copy link
Member Author

epost commented Sep 18, 2018

@tg-x I'm getting the following, which from this Travis issue seems to have to do with our account having run out of builds.
screen shot 2018-09-18 at 10 59 00

link: https://travis-ci.com/statebox/aql/requests?requestId=140688031

@epost
Copy link
Member Author

epost commented Sep 18, 2018

@wires It seems like we've run out of builds on Travis; see above. Could you check, and preferably make it go away magically?

@tg-x
Copy link
Collaborator

tg-x commented Sep 18, 2018

@epost @wires this is due to this repository being private, which travis charges for.
see travis for private repos.

so the options are:

  1. pay travis (see plans)
  2. make this repo public (see instructions)

@epost epost closed this as completed Oct 13, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants