Coder Social home page Coder Social logo

json-printer's Issues

Cant parse json if an attribute have text/json.

Steps required to reproduce the problem

  1. Use the following json and run it through: php (new Printer)->print($json, ' ')

$json = {"type": "auth-token", "error": "Server error: POST https://wsx.xxxxxxx.net/sms/send resulted in a 500 Internal Server Error response:\n{"status":106000,"description":"Unknown error","translatedDescription":null}", "queue": "auth", "token": "XXXXX", "origin": "XXXXXX", "identifier": null, "recipients": [{"email": "[email protected]", "mobile": "11111111", "mobile_country_code": "0047"}], "request_ip": "x.xxx.xx.xxx", "destination": "004711111111", "consignor_id": null, "sms_error_code": null, "sms_error_description": null}

Expected Result

  • Valid JSON.

Actual Result

  • is not valid JSON.

Can't install using composer 2

I know that this is probably composer's fault, but I'd like to try anyway here.
In my current situation, I'm using ergebnis/composer-normalize 2.10.0 and ergebnis/json-printer 3.1.1

I would update vendors, but a "composer update" results in:

Your requirements could not be resolved to an installable set of packages.

  Problem 1
    - ergebnis/composer-normalize[2.10.0, ..., 2.11.0] require ergebnis/json-printer ^3.1.1 -> found ergebnis/json-printer[dev-main] but it does not match the constraint.
    - Root composer.json requires ergebnis/composer-normalize ^2.10 -> satisfiable by ergebnis/composer-normalize[2.10.0, 2.11.0].

It's like composer can't find correct versions for this library, looking for "dev-main"

I event did a differen try, creating an empty dir and executing "composer init --no-interaction && composer require ergebnis/json-printer".
This is working with composer 1, not working with composer 2 with following error:

[InvalidArgumentException]                                                                                                                                                         
  Could not find a version of package ergebnis/json-printer matching your minimum-stability (stable). Require it with an explicit version constraint allowing its desired stability

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.