Coder Social home page Coder Social logo

Comments (10)

jfhbrook avatar jfhbrook commented on June 12, 2024

Can you elaborate on "incompatible with connect master" ? There are a _lot_ of ways union could be incompatible.

from union.

pksunkara avatar pksunkara commented on June 12, 2024

All the following connect middlewares do not work with union v0.3.2 (they work with union v0.3.0)

  • bodyParser
  • json
  • multipart
  • urlencoded

from union.

jfhbrook avatar jfhbrook commented on June 12, 2024

Does union have tests for these? That would certainly help ensure a lack of breakage in the future.

from union.

pksunkara avatar pksunkara commented on June 12, 2024

http://github.com/pksunkara/connect-union, which is a fork of connect, replaces the connect server in their test suite with union, thus testing union compatibility with each and every connect middleware

from union.

jfhbrook avatar jfhbrook commented on June 12, 2024

So why isn't this part of our test suite?

from union.

pksunkara avatar pksunkara commented on June 12, 2024

Because maintaining it becomes a very difficult task, as it constantly needs to be updated from connect and union shim needs to be applied. me and @dscape discussed over it and decided to leave it in a seperate repository.

from union.

jfhbrook avatar jfhbrook commented on June 12, 2024

Okay, that makes sense, but what about running those tests as part of the test suite?

from union.

indexzero avatar indexzero commented on June 12, 2024

@pksunkara Can you provide empirical evidence for your claims? I'm seeing test/body-parser-test.js pass:

$ vows test/body-parser-test.js --spec

♢ union/body-parser

  When using union with connect bodyParser() a request to /
    ✓ should respond with a body-decoded object

✓ OK » 1 honored (0.016s)

Tested with [email protected]

from union.

pksunkara avatar pksunkara commented on June 12, 2024

After extensive testing by me, I finally found what the problem was. In my http://github.com/pksunkara/connect-union tests, I didn't provide buffer: false to the server. I assume some logic for that has changed between v0.3.0 and v0.3.2.

It should be documented that for union to be compatible with connect, we need to set buffer to false

from union.

pksunkara avatar pksunkara commented on June 12, 2024

But, if we are going to use connect with flatiron and [email protected], we will get errors because buffer is not set to false in http://github.com/flatiron/flatiron/blob/master/lib/flatiron/plugins/http.js#L74

from union.

Related Issues (20)

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.