napkin-1.0.0
Safe HaskellNone
LanguageGHC2021

Napkin.Cli.Repl.Helper

Documentation

runSpecProgram :: (ReifiesBackend b, Typeable b, HasBackendQueryStats b, CSVImport b, Backend b, Command (CreateTable (BackendTableMeta b)) () b, Command (CreateView (BackendViewMeta b)) () b, Command (CreateMaterializedView (BackendMaterializedViewMeta b)) () b, Command (CreateTableDDL (BackendTableMeta b)) () b, Command AnnotateCommand () b, Command ReadAnnotationCommand TableAnnotations b, Command CheckTableExists Bool b, Command InsertIntoQuery () b, Command RenameTable () b, Command CopyTable () b, Command DropTable () b, Command DropView () b, Command DeleteFrom () b, Command UpdateQuery () b, Command InsertIntoTable () b, Command GetTableKind TableKind b, Command GetRelationSchema [BackendSchemaField b] b, ToDbBackend b, RunBackendEffect b, Default (BackendTableMeta b), Default (BackendViewMeta b), MaybeDefault (YamlBackendMaterializedViewMeta b), RenderSql (Ref SExp) b, RenderSql (Ref Relation) b, RenderSql (Ref Table) b, RenderSql String b, RenderSql (Alias (Ref Table)) b, RenderSql (Alias Relation) b, RenderSql (Alias SExp) b, RenderSql Query b, RenderSql SExp b, RenderSql From b, RenderSql Relation b, RenderSql Name b, HasBackendSchemaField b, ToDumpItem b (BackendSpecificEffect b), Show (BackendTableMeta b), Show (BackendViewMeta b), Show (BackendMaterializedViewMeta b), Eq (BackendTableMeta b), Eq (BackendViewMeta b), Eq (BackendMaterializedViewMeta b)) => SpecFilesWithOverrides -> SpecMetaArgs -> Ref Table -> Sem '[RecreateTable b :: (Type -> Type) -> Type -> Type, Output ExtraDependencies :: (Type -> Type) -> Type -> Type, Reader HiddenDependencies, Reader HiddenArtifacts, Assertion :: (Type -> Type) -> Type -> Type, BackendSpecificEffect b, Reader TargetName, Input TemporaryTableName :: (Type -> Type) -> Type -> Type, Reader ConnectionString, External :: (Type -> Type) -> Type -> Type, FatalError :: (Type -> Type) -> Type -> Type, Input RandomToken :: (Type -> Type) -> Type -> Type, Time :: (Type -> Type) -> Type -> Type, Output LogLine :: (Type -> Type) -> Type -> Type, SqlRender :: (Type -> Type) -> Type -> Type, SqlParse :: (Type -> Type) -> Type -> Type, SqlRead b :: (Type -> Type) -> Type -> Type, SqlWrite b :: (Type -> Type) -> Type -> Type, AnnotateRead b :: (Type -> Type) -> Type -> Type, AnnotateWrite b :: (Type -> Type) -> Type -> Type, LocalFile :: (Type -> Type) -> Type -> Type, Template :: (Type -> Type) -> Type -> Type, LoadQuery :: (Type -> Type) -> Type -> Type, Reader QueryTransformer, Input MetaArguments :: (Type -> Type) -> Type -> Type, Reader SQLDialect, Fail :: (Type -> Type) -> Type -> Type] a -> IO (Either NapkinEffectError a) #

runHookProgram :: (ReifiesBackend b, Typeable b, HasBackendQueryStats b, CSVImport b, Backend b, Command (CreateTable (BackendTableMeta b)) () b, Command (CreateView (BackendViewMeta b)) () b, Command (CreateMaterializedView (BackendMaterializedViewMeta b)) () b, Command (CreateTableDDL (BackendTableMeta b)) () b, Command AnnotateCommand () b, Command ReadAnnotationCommand TableAnnotations b, Command CheckTableExists Bool b, Command InsertIntoQuery () b, Command RenameTable () b, Command CopyTable () b, Command DropTable () b, Command DropView () b, Command DeleteFrom () b, Command UpdateQuery () b, Command InsertIntoTable () b, Command GetTableKind TableKind b, Command GetRelationSchema [BackendSchemaField b] b, ToDbBackend b, RunBackendEffect b, Default (BackendTableMeta b), Default (BackendViewMeta b), MaybeDefault (YamlBackendMaterializedViewMeta b), RenderSql (Ref SExp) b, RenderSql (Ref Relation) b, RenderSql (Ref Table) b, RenderSql String b, RenderSql (Alias (Ref Table)) b, RenderSql (Alias Relation) b, RenderSql (Alias SExp) b, RenderSql Query b, RenderSql SExp b, RenderSql From b, RenderSql Relation b, RenderSql Name b, HasBackendSchemaField b, ToDumpItem b (BackendSpecificEffect b), Show (BackendTableMeta b), Show (BackendViewMeta b), Show (BackendMaterializedViewMeta b), Eq (BackendTableMeta b), Eq (BackendViewMeta b), Eq (BackendMaterializedViewMeta b)) => SpecFilesWithOverrides -> SpecMetaArgs -> Ref Table -> Sem '[Assertion :: (Type -> Type) -> Type -> Type, Embed IO, BackendSpecificEffect b, Error FatalErrorInfo :: (Type -> Type) -> Type -> Type, Input RandomToken :: (Type -> Type) -> Type -> Type, Input UTCTime :: (Type -> Type) -> Type -> Type, Output LogLine :: (Type -> Type) -> Type -> Type, SqlRender :: (Type -> Type) -> Type -> Type, SqlParse :: (Type -> Type) -> Type -> Type, SqlRead b :: (Type -> Type) -> Type -> Type, SqlWrite b :: (Type -> Type) -> Type -> Type, AnnotateRead b :: (Type -> Type) -> Type -> Type, AnnotateWrite b :: (Type -> Type) -> Type -> Type, LocalFile :: (Type -> Type) -> Type -> Type, Template :: (Type -> Type) -> Type -> Type, LoadQuery :: (Type -> Type) -> Type -> Type, Reader QueryTransformer, Input MetaArguments :: (Type -> Type) -> Type -> Type, Reader SQLDialect, Fail :: (Type -> Type) -> Type -> Type, Reader TargetName, Input TemporaryTableName :: (Type -> Type) -> Type -> Type, Reader ConnectionString, External :: (Type -> Type) -> Type -> Type, FatalError :: (Type -> Type) -> Type -> Type, Input RandomToken :: (Type -> Type) -> Type -> Type, Time :: (Type -> Type) -> Type -> Type, Output LogLine :: (Type -> Type) -> Type -> Type, SqlRender :: (Type -> Type) -> Type -> Type, SqlParse :: (Type -> Type) -> Type -> Type, SqlRead b :: (Type -> Type) -> Type -> Type, SqlWrite b :: (Type -> Type) -> Type -> Type, AnnotateRead b :: (Type -> Type) -> Type -> Type, AnnotateWrite b :: (Type -> Type) -> Type -> Type, LocalFile :: (Type -> Type) -> Type -> Type, Template :: (Type -> Type) -> Type -> Type, LoadQuery :: (Type -> Type) -> Type -> Type, Reader QueryTransformer, Input MetaArguments :: (Type -> Type) -> Type -> Type, Reader SQLDialect, Fail :: (Type -> Type) -> Type -> Type] a -> IO (Either NapkinEffectError (Either (NonEmpty AssertionEntry) ([AssertionEntry], a))) #

runGlobalHookProgram :: (ReifiesBackend b, Typeable b, HasBackendQueryStats b, CSVImport b, Backend b, Command (CreateTable (BackendTableMeta b)) () b, Command (CreateView (BackendViewMeta b)) () b, Command (CreateMaterializedView (BackendMaterializedViewMeta b)) () b, Command (CreateTableDDL (BackendTableMeta b)) () b, Command AnnotateCommand () b, Command ReadAnnotationCommand TableAnnotations b, Command CheckTableExists Bool b, Command InsertIntoQuery () b, Command RenameTable () b, Command CopyTable () b, Command DropTable () b, Command DropView () b, Command DeleteFrom () b, Command UpdateQuery () b, Command InsertIntoTable () b, Command GetTableKind TableKind b, Command GetRelationSchema [BackendSchemaField b] b, ToDbBackend b, RunBackendEffect b, Default (BackendTableMeta b), Default (BackendViewMeta b), MaybeDefault (YamlBackendMaterializedViewMeta b), RenderSql (Ref SExp) b, RenderSql (Ref Relation) b, RenderSql (Ref Table) b, RenderSql String b, RenderSql (Alias (Ref Table)) b, RenderSql (Alias Relation) b, RenderSql (Alias SExp) b, RenderSql Query b, RenderSql SExp b, RenderSql From b, RenderSql Relation b, RenderSql Name b, HasBackendSchemaField b, ToDumpItem b (BackendSpecificEffect b), Show (BackendTableMeta b), Show (BackendViewMeta b), Show (BackendMaterializedViewMeta b), Eq (BackendTableMeta b), Eq (BackendViewMeta b), Eq (BackendMaterializedViewMeta b)) => SpecFilesWithOverrides -> SpecMetaArgs -> Sem '[Assertion :: (Type -> Type) -> Type -> Type, Embed IO, BackendSpecificEffect b, FatalError :: (Type -> Type) -> Type -> Type, Input RandomToken :: (Type -> Type) -> Type -> Type, Time :: (Type -> Type) -> Type -> Type, Output LogLine :: (Type -> Type) -> Type -> Type, SqlRender :: (Type -> Type) -> Type -> Type, SqlParse :: (Type -> Type) -> Type -> Type, SqlRead b :: (Type -> Type) -> Type -> Type, SqlWrite b :: (Type -> Type) -> Type -> Type, AnnotateRead b :: (Type -> Type) -> Type -> Type, AnnotateWrite b :: (Type -> Type) -> Type -> Type, LocalFile :: (Type -> Type) -> Type -> Type, Template :: (Type -> Type) -> Type -> Type, LoadQuery :: (Type -> Type) -> Type -> Type, Reader QueryTransformer, Input MetaArguments :: (Type -> Type) -> Type -> Type, Reader SQLDialect, Fail :: (Type -> Type) -> Type -> Type] a -> IO (Either NapkinEffectError (Either (NonEmpty AssertionEntry) ([AssertionEntry], a))) #

runCustomHook :: (ReifiesBackend b, Typeable b, HasBackendQueryStats b, CSVImport b, Backend b, Command (CreateTable (BackendTableMeta b)) () b, Command (CreateView (BackendViewMeta b)) () b, Command (CreateMaterializedView (BackendMaterializedViewMeta b)) () b, Command (CreateTableDDL (BackendTableMeta b)) () b, Command AnnotateCommand () b, Command ReadAnnotationCommand TableAnnotations b, Command CheckTableExists Bool b, Command InsertIntoQuery () b, Command RenameTable () b, Command CopyTable () b, Command DropTable () b, Command DropView () b, Command DeleteFrom () b, Command UpdateQuery () b, Command InsertIntoTable () b, Command GetTableKind TableKind b, Command GetRelationSchema [BackendSchemaField b] b, ToDbBackend b, RunBackendEffect b, Default (BackendTableMeta b), Default (BackendViewMeta b), MaybeDefault (YamlBackendMaterializedViewMeta b), RenderSql (Ref SExp) b, RenderSql (Ref Relation) b, RenderSql (Ref Table) b, RenderSql String b, RenderSql (Alias (Ref Table)) b, RenderSql (Alias Relation) b, RenderSql (Alias SExp) b, RenderSql Query b, RenderSql SExp b, RenderSql From b, RenderSql Relation b, RenderSql Name b, HasBackendSchemaField b, ToDumpItem b (BackendSpecificEffect b), Show (BackendTableMeta b), Show (BackendViewMeta b), Show (BackendMaterializedViewMeta b), Eq (BackendTableMeta b), Eq (BackendViewMeta b), Eq (BackendMaterializedViewMeta b)) => SpecFilesWithOverrides -> SpecMetaArgs -> HookProgramWithArgParser b -> Ref Table -> [(Text, Value)] -> IO (Either NapkinEffectError (Either (NonEmpty AssertionEntry) ([AssertionEntry], ()))) #

runCustomSpec :: (ReifiesBackend b, Typeable b, HasBackendQueryStats b, CSVImport b, Backend b, Command (CreateTable (BackendTableMeta b)) () b, Command (CreateView (BackendViewMeta b)) () b, Command (CreateMaterializedView (BackendMaterializedViewMeta b)) () b, Command (CreateTableDDL (BackendTableMeta b)) () b, Command AnnotateCommand () b, Command ReadAnnotationCommand TableAnnotations b, Command CheckTableExists Bool b, Command InsertIntoQuery () b, Command RenameTable () b, Command CopyTable () b, Command DropTable () b, Command DropView () b, Command DeleteFrom () b, Command UpdateQuery () b, Command InsertIntoTable () b, Command GetTableKind TableKind b, Command GetRelationSchema [BackendSchemaField b] b, ToDbBackend b, RunBackendEffect b, Default (BackendTableMeta b), Default (BackendViewMeta b), MaybeDefault (YamlBackendMaterializedViewMeta b), RenderSql (Ref SExp) b, RenderSql (Ref Relation) b, RenderSql (Ref Table) b, RenderSql String b, RenderSql (Alias (Ref Table)) b, RenderSql (Alias Relation) b, RenderSql (Alias SExp) b, RenderSql Query b, RenderSql SExp b, RenderSql From b, RenderSql Relation b, RenderSql Name b, HasBackendSchemaField b, ToDumpItem b (BackendSpecificEffect b), Show (BackendTableMeta b), Show (BackendViewMeta b), Show (BackendMaterializedViewMeta b), Eq (BackendTableMeta b), Eq (BackendViewMeta b), Eq (BackendMaterializedViewMeta b)) => SpecFilesWithOverrides -> SpecMetaArgs -> SpecProgramWithArgParser b -> Ref Table -> [(Text, Value)] -> IO (Either NapkinEffectError ()) #

fromListText :: [(Text, v)] -> KeyMap v #