Skip to content

Conversation

@Eomm
Copy link
Member

@Eomm Eomm commented Nov 24, 2019

I'm working on next

This is the rebase on master;

I would ask help to @Ethan-Arrowood because I have trouble running npm run test:typescript and I didn't find a fast solution

  0:0  error  Parsing error: "parserOptions.project" has been set for @typescript-eslint/parser.
The file does not match your project config: test\types\content-type-parser.test-d.ts.
The file must be included in at least one of the projects provided

(I have removed it from npm test to check the CI workflow)

Checklist

  • run npm run test and npm run benchmark
  • tests and/or benchmarks are included
  • documentation is changed or added
  • commit message and code follows Code of conduct

smartiniOnGitHub and others added 30 commits May 13, 2019 22:33
Windows + Yarn section name was `Windows_yarm`
* Catches onRoute hooks errors

* Fixes typo

* Removes unneeded test
* Add .git folder to NPM ignore

* Update .npmignore

Co-Authored-By: Manuel Spigolon <behemoth89@gmail.com>
…rue (fastify#1675)

* Removes double call to afterRouteAdded when ignoreTrailingSlash === true

* Adds explaining comment when adding a prefixed plugin
* Added case sensitive option to definition file.

* Added casSensitive Option to test
* add ability to get response time on reply

* feedback

* Update docs/Reply.md as per suggestion

Co-Authored-By: Manuel Spigolon <behemoth89@gmail.com>

* update type of FastifyReply

* add type test
* Improve support for Fluent Schema

* Updated test

* Updated docs

* Avoid code duplication
delvedor and others added 22 commits October 26, 2019 12:11
* Added missing typescript types

* Added http2 server factory test
* Add fastify-errors-properties plugin

* Put plugin in the right order.
* update requirements to Node.js 8 LTS or later; update docs

add TODO for code updates/cleanup (check if do here or if in the other issue/PR)

Update README.md

Co-Authored-By: Matteo Collina <matteo.collina@gmail.com>

Update docs/Benchmarking.md

Co-Authored-By: Matteo Collina <matteo.collina@gmail.com>

Update package.json

Co-Authored-By: Matteo Collina <matteo.collina@gmail.com>

revert version

update getHeader to use hasHeader (available since Node.js 7.7.x) and remove fallback implementation

try yarn builds for Node.js 8 aligned with requirements in 'package.json', to check if it works with version range

align even npm azure pipelines to those of yarn (Node.js 8.x requirements)

update code to Node.js 8 as minimum version (remove TODO etc)

update code to Node.js 8 as minimum version (remove TODO etc)

update code to Node.js 8 as minimum version (remove TODO etc)

move getHeader implementation directly in Reply.prototype.getHeader

drop Node.js 11 from doc and from CI on Azure (yarn and npm)

(try to) simplify info on HTTP2 support

CI on Azure, specify version range in a way more aligned to npm syntax

* restore 'hooks-async.js' and set the '.test.js' extension to run it like others; remove its tests from 'hooks.test.js'

* remove direct reference to main fastify source from https tests, not really needed
…er) (fastify#1732)

explicit update all dependencies to latest; only Tap will be updated later

update 'joi' to the new package name ('@hapi/joi')

update tap and tap-mocha-reporter to latest; note that this currently breaks some tests

fix failing tests (since Tap 14.x) on cloned options; explicit set Tap version to latest

update test to not clone anymore object containing Buffer instances

remove boom from greenkeeper ignore list
* remove beforeHandler and related implementation and warnings if used (it's no more supported)

* remove basePath and related warnings (no more supported)

* remove genReqId and related warnings (no more supported)
…1766)

* chore: change async hooks warning to error

* test: change test case for 'change async hooks warning to error'
Add FastifyError.toString to display code in `console.log(error)`
* utilize conditional to control generic specifics

* Constrain and default generics

* change declaration name for testing. define overload factory func

* simplify to a single function declaration again

* completed route method type declarations

* split up types

* remove fastify2.d.ts file

* Add light-my-request and move logger to own file

* Add FastifyError type

* Utilize DRY RawBases and RawDefault logic

* Update logger types

* Fix generics in logger

* Update route do add shorthand with handler param

* Type register and plugin. Modify export structure

* Move instance to own file and fix imports

* Suppor esm and default import syntax

* modify exports and imports for instance and fix generics

* add import tests

* add addHook methods

* Add content-type-parser types

* Export all types. Ready for review 🚀

* fix route types (change to interfaces)

* Initial implementation of tsd tests. Modify types to interfaces

* delete old types

* More testing and updates

* added server factory and more tests

* update jsdocs, update tsd

* delete old type test

* update npm scripts, remove typescript linting

* fix npm script

* udpate schema type and doc

* try adding explicit azure-pipeline trigger

* revert 6e83a45

* fix strict log types

* Improve route generics

* fix serverFactory test

* Add abarre review

* Updated content-type-parser tests

* update logger types

* improve types for schema, context, routes, and register

* add context to other route based methods

* add import syntax comment

* add linting for typescript files

* fix export

* remove comment

* combine Raw(Req|Reply) Base and Default

* allow request headers to be mergable

* fix hooks

* add Symbol to decorate method

* fix file paths for windows
@Eomm Eomm added the v3.x Issue or pr related to Fastify v3 label Nov 24, 2019
@mcollina
Copy link
Member

mcollina commented Nov 24, 2019 via email

@Eomm
Copy link
Member Author

Eomm commented Nov 24, 2019

@fastify/core when the problem with typescript will be solved, should I --force push?

The test are green:

Suites:   79 passed, 79 of 79 completed
Asserts:  4209 passed, of 4209
Time:     2m
-----------------------------|----------|----------|----------|----------|-------------------|
File                         |  % Stmts | % Branch |  % Funcs |  % Lines | Uncovered Line #s |
-----------------------------|----------|----------|----------|----------|-------------------|
All files                    |    99.24 |    96.17 |    99.57 |     99.2 |                   |
 fastify_2                   |    98.51 |    95.05 |      100 |    98.45 |                   |
  fastify.js                 |    98.51 |    95.05 |      100 |    98.45 |         61,62,307 |
 fastify_2/lib               |    99.34 |    96.31 |    99.48 |    99.31 |                   |
  contentTypeParser.js       |      100 |      100 |      100 |      100 |                   |
  context.js                 |      100 |    91.67 |      100 |      100 |                33 |
  decorate.js                |      100 |      100 |      100 |      100 |                   |
  errors.js                  |      100 |      100 |      100 |      100 |                   |
  fourOhFour.js              |      100 |    96.67 |      100 |      100 |           159,170 |
  handleRequest.js           |      100 |      100 |      100 |      100 |                   |
  hooks.js                   |      100 |      100 |      100 |      100 |                   |
  initialConfigValidation.js |      100 |      100 |      100 |      100 |                   |
  logger.js                  |      100 |       90 |      100 |      100 |             40,89 |
  middleware.js              |      100 |      100 |      100 |      100 |                   |
  pluginUtils.js             |    98.15 |    91.67 |      100 |    97.67 |                22 |
  reply.js                   |    99.28 |    95.42 |    97.44 |    99.28 |           156,215 |
  reqIdGenFactory.js         |      100 |      100 |      100 |      100 |                   |
  request.js                 |      100 |      100 |      100 |      100 |                   |
  route.js                   |      100 |    99.24 |      100 |      100 |               309 |
  schemas.js                 |     98.8 |    95.89 |      100 |    98.73 |               157 |
  server.js                  |    96.43 |    84.62 |      100 |    96.34 |         52,53,118 |
  symbols.js                 |      100 |      100 |      100 |      100 |                   |
  validation.js              |    98.11 |     94.2 |      100 |    97.96 |             75,82 |
  wrapThenable.js            |      100 |      100 |      100 |      100 |                   |
-----------------------------|----------|----------|----------|----------|-------------------|

@Eomm Eomm mentioned this pull request Nov 24, 2019
4 tasks
@Eomm
Copy link
Member Author

Eomm commented Nov 24, 2019

a potentially less complicated way is to merge master in next.

Done #1954

@Eomm Eomm closed this Nov 24, 2019
@github-actions
Copy link

This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Feb 10, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

v3.x Issue or pr related to Fastify v3

Projects

None yet

Development

Successfully merging this pull request may close these issues.