Questions tagged [json]
JSON (JavaScript Object Notation) is a serializable data interchange format that is a machine and human readable. Do not use this tag for native JavaScript objects or JavaScript object literals. Before you ask a question, validate your JSON using a JSON validator such as JSONLint (https://jsonlint.com).
105,260
questions with no upvoted or accepted answers
39
votes
5
answers
3k
views
How can I serialize a jgrapht simple graph to json?
I have a simple directed graph from jgrapht and I am trying to serialize it into a JSON file using jackson as follows:
ObjectMapper mapper = new ObjectMapper();
File output = new File("P:\\tree....
25
votes
1
answer
532
views
Updating AngularJS scope after validating search form in Symfony2
Hi fellow developers,
We have to rewrite a software application in Symfony2 with AngularJS, we use Symfony2 for the MVC purpose and AngularJS for the useful functions.
Here's our problem, we first ...
20
votes
0
answers
4k
views
Losing precision when passing numbers through the JSONDecoder in Swift 4
I'm sending some JSON data to our server and in the process having issues when encoding certain values with the new Swift 4 JSONDecoder. Take this playground example:
import Foundation
struct ...
19
votes
1
answer
2k
views
Owin Middleware vs ExceptionHandler vs HttpMessageHandler (DelegatingHandler)
Please anyone give me some idea how following three modules work together in asp.net Web API 2.1
Owin Middleware
HttpMessageHandler (or DelegatingHandler)
ExceptionHandler
What I am trying to do is ...
16
votes
1
answer
577
views
Heroku - configuring scheduler in app.json
Is there a way to get the Heroku Scheduler to be configured with
a script to run
frequency
Using app.json addons configuration, so that it is set up automatically from a Github "Deploy to Heroku" ...
16
votes
0
answers
1k
views
How to disable object reference when using @JsonIdentityInfo?
When I use JsonIdentityInfo , for example
@JsonIdentityInfo(generator = ObjectIdGenerators.IntSequenceGenerator.class, property = "@dataSet")
The Jackson will replace object, which has appear to id ,...
15
votes
2
answers
11k
views
Webpack-dev-server "Cannot GET /"
i'm trying to get my webpack-dev-server to run but i face always the error "Cannot Get /" at the browser.
I know that there are serveral questions with the same error, but none of them ...
14
votes
0
answers
5k
views
jest test getting undefined for imported json files
I'm using JSON schema file for form creation and validation. When I'm going to test that component, in jest testing environment all imported *.json files getting undefined.
E.g.
import schema from "./...
14
votes
1
answer
1k
views
Measuring rails json api with rack mini profiler
How do we get rack-mini-profiler to show in a rails json api? I believe this was asked here: How to profile a rails controller that returns a json response with rack-mini-profiler? but the only answer ...
13
votes
0
answers
4k
views
meta-schema features in VS Code extension warning in version ^1.68.0
So basically I have a VS Code extension that provides JSON file validation based on the built in JSON validator. The schema that I'm validating against (OpenAPI 3.1.x) uses meta-schema features, i.e. $...
13
votes
0
answers
7k
views
How to use the type "expandable" correctly?
Question
How to use the type "expandable" correctly?
Description
I have a batch that runs every hour and sends some stats to our slack. Each JSON output can be quite large and I'm looking for a way ...
13
votes
1
answer
755
views
Aquery ajax request seems not starting in android
I think the code that I build for getting data from the server in JSON is not starting. In the logcat there is no text from "log.v". Also, the code that I made seems not good with the try-catch all ...
13
votes
2
answers
4k
views
Grails REST API - Render JSON with paging, metadata and custom include fields from params
I'm looking for a best way to design a custom JSON response for RESTful API in Grails based on this presentation Design Beautiful REST + JSON APIs by Les Hazlewood.
Here is my Domain class
class ...
13
votes
1
answer
7k
views
Is there a way to get substring of a string value in JSONPath?
Basically, I need to get a part of the string value using JSONPath. I cannot get the full value using JSONPath first and then get the part of it using another language.
Is there any way to do it in ...
13
votes
1
answer
6k
views
An exception in Json.NET: Token PropertyName in state "Start" would result in an invalid JavaScript object
I see the error in my prod server log; can u give me any hint about what kinds of situations would trigger the error? Thanks.
Token PropertyName in state Start would result in an invalid JavaScript ...