Giter VIP home page Giter VIP logo

php-fetch's People

Contributors

mnavarrocarter avatar peter279k avatar sirdiego avatar szepeviktor avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

php-fetch's Issues

What feof() does

        if (feof($this->resource)) {
            return null;
        }
        $result = @fread($this->resource, $bytes);

What does feof on HTTP level? How can it tell that the stream is over?
As I understand fread fires a new HTTP request each time. Am I wrong?

Use temp. variables?

After Adam Wathan: https://youtu.be/crSUWtRYw-M?t=615 (item number #3)

                $status = Status::fromStatusLine($line);
                $headers = Headers::fromLines($lines);
                $partials[] = new HttpPartialResponse($status, $headers);

                // ๐Ÿ‘‡ 

                $partials[] = new HttpPartialResponse(Status::fromStatusLine($line), Headers::fromLines($lines));

What do you think?

Missing dep: symfony/process

If I go with only

        "phpunit/phpunit": "^9.4",
        "symfony/var-dumper": "^5.1",
        "amphp/http-server": "^2.1",
        "amphp/http-server-static-content": "^1.0",
        "mnavarrocarter/amp-http-router": "^0.1.0",

symfony/process will be missing.

Put errors in conditionals

and do not indent normal execution.

            if (strpos($line, 'HTTP') === 0) {
                $status = Status::fromStatusLine($line);
                $headers = Headers::fromLines($lines);
                $partials[] = new HttpPartialResponse($status, $headers);
            }

			// ๐Ÿ‘‡ 

            if (strpos($line, 'HTTP') !== 0) {
				continue;
            }

            $status = Status::fromStatusLine($line);
            $headers = Headers::fromLines($lines);
            $partials[] = new HttpPartialResponse($status, $headers);

How about that?

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.