Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
haskell-gargantext
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
153
Issues
153
List
Board
Labels
Milestones
Merge Requests
9
Merge Requests
9
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
gargantext
haskell-gargantext
Commits
25f18d7c
Commit
25f18d7c
authored
Nov 24, 2022
by
Przemyslaw Kaminski
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[api] fix to_json for GargError
parent
376f3410
Pipeline
#3403
canceled with stage
Changes
2
Pipelines
1
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
2 deletions
+3
-2
Prelude.hs
src/Gargantext/API/Prelude.hs
+2
-1
Routes.hs
src/Gargantext/API/Routes.hs
+1
-1
No files found.
src/Gargantext/API/Prelude.hs
View file @
25f18d7c
...
@@ -29,6 +29,7 @@ import Control.Monad.Reader (ReaderT)
...
@@ -29,6 +29,7 @@ import Control.Monad.Reader (ReaderT)
import
Control.Monad.Error.Class
(
MonadError
(
..
))
import
Control.Monad.Error.Class
(
MonadError
(
..
))
import
Crypto.JOSE.Error
as
Jose
import
Crypto.JOSE.Error
as
Jose
import
Data.Aeson.Types
import
Data.Aeson.Types
import
qualified
Data.Text
as
Text
import
Data.Typeable
import
Data.Typeable
import
Data.Validity
import
Data.Validity
import
Gargantext.API.Admin.Orchestrator.Types
import
Gargantext.API.Admin.Orchestrator.Types
...
@@ -115,7 +116,7 @@ data GargError
...
@@ -115,7 +116,7 @@ data GargError
makePrisms
''
G
argError
makePrisms
''
G
argError
instance
ToJSON
GargError
where
instance
ToJSON
GargError
where
toJSON
_
=
String
"SomeGargErrorPleaseReport"
toJSON
err
=
object
[(
"error"
,
String
$
Text
.
pack
$
show
err
)]
instance
Exception
GargError
instance
Exception
GargError
...
...
src/Gargantext/API/Routes.hs
View file @
25f18d7c
...
@@ -289,7 +289,7 @@ addCorpusWithForm user cid =
...
@@ -289,7 +289,7 @@ addCorpusWithForm user cid =
serveJobsAPI
AddCorpusFormJob
$
\
i
log'
->
serveJobsAPI
AddCorpusFormJob
$
\
i
log'
->
let
let
log''
x
=
do
log''
x
=
do
printDebug
"[addToCorpusWithForm] "
x
--
printDebug "[addToCorpusWithForm] " x
liftBase
$
log'
x
liftBase
$
log'
x
in
New
.
addToCorpusWithForm
user
cid
i
log''
(
jobLogInit
3
)
in
New
.
addToCorpusWithForm
user
cid
i
log''
(
jobLogInit
3
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment