Commit Graph

3082 Commits

Author SHA1 Message Date
UnderratedDev
dd2b64ef65 updated 2 files for allowing multiple client ids (#6523)
* updated 2 files for allowing multiple client ids

* updated tests that fail due to user inputting data in code, added todo comment to them stating what we need to do to fix them
2020-03-21 19:04:10 -05:00
greenkeeper[bot]
76f0edc922 Update prettier to the latest version 🚀 (#6524)
* chore(package): update prettier to version 2.0.0

* chore(package): update lockfile package-lock.json

Co-authored-by: greenkeeper[bot] <23040076+greenkeeper[bot]@users.noreply.github.com>
2020-03-21 23:06:51 +00:00
greenkeeper[bot]
a5977f3816 Update babel7 to the latest version 🚀 (#6520)
* chore(package): update @babel/core to version 7.9.0

* chore(package): update @babel/plugin-proposal-object-rest-spread to version 7.9.0

* chore(package): update @babel/plugin-transform-flow-strip-types to version 7.9.0

* chore(package): update @babel/preset-env to version 7.9.0

* chore(package): update lockfile package-lock.json

Co-authored-by: greenkeeper[bot] <23040076+greenkeeper[bot]@users.noreply.github.com>
2020-03-20 17:06:22 +00:00
Corey
352eeb217e Travis: Separating Postgres & Mongo scripts (#6505)
* Attempting to fix Postgres issue

* Attempting to fix Postgres issue

trying to stop loop

* Attempting to fix Postgres

isolating postgres calls

* Attempting to fix Postgres issue

Separating jobs

* Attempting to fix postgres

* Attempting to fix postgres

* Attempting to fix postgres

Separating builds again

* Attempting to fix postgres

* Attempting to fix postgres

* Attempting to fix postgres

Just added back version 10, just in case it gets called

* Attempting to fix postgres

* Attempting to fix postgres

* Attempting to fix postgres

* Attempting to fix postgres

* Attempting to fix postgres

* Attempting to fix postgres

* Attempting to fix postgres

* Attempting to fix postgres

* Attempting to fix postgres

* Attempting to fix postgres

* Update .travis.yml

* Attempting to fix postgres

Removed postgres installs from unneeded test cases. Added the ability to test Postgres 10 and 11

* Attempting to fix postgres

* Attempting to fix postgres

* Attempting to fix postgres

* Attempting to fix postgres

Added test for postgres 12 that's allowed to fail

* Attempting to fix postgres

* Attempting to fix postgres 

Second round to see if it fails eventually

* Attempting to fix postgres

Round 3

* Attempting to fix postgres

Allowing all postgres to fail since it seems to occur randomly

* Temporary fix: separated mongo and postgres in travis

Now the mongo and postgres scripts are independent of each other to prevent the `ERROR:  could not access file "$libdir/postgis-2.4": No such file or directory` of showing up in the rest of the builds.

In addition, a test for postgres-12 has been added for future compatibility. Both the postgres-11 and postgres-12 have been added to `allow_failures` because the aforementioned error still creeps up. Important note is that the error has nothing to do with compatibility with postgres, but rather seems to be an error of how postgres (or really postgis) is being referenced in the respective travis distribution. Lastly, this error, if truly random should appear less than before as the postgres scripts aren't being run for every build as it previously was running.

* Allowing all postgres to fail

* Allowing multiple names to fail

* Removing preinstalled versions of postgres from list

Seeing if this gets rid of the random error

* Use postgres made for dist

* Second round

* Round 3

* Round 4

* Round 5

* Fixed issue with random postgres fail

Removing the native postgres builds at the right time seems to have fixed the random error from before.

The postgres tests are now not allowed to fail.

* Added back postgres 11 and 12 to allow_failures

The actual problem is fixed, but it seems there are some instability with some of the test cases for postgres that need to be addressed at another time.

The issues that pop up are: 
- Postgres-11
```Failures:
1) Cloud Code cloud jobs should set the message / success on the job
  Message:
    Expected undefined to equal 'hello'.
  Stack:
    Error: Expected undefined to equal 'hello'.
        at <Jasmine>
        at req.message.then.then.jobStatus (/home/travis/build/parse-community/parse-server/spec/CloudCode.spec.js:1571:46)
        at process._tickCallback (internal/process/next_tick.js:68:7)
```

- Postgres-12
``` 
Failures:
1) Cloud Code cloud jobs should set the message / success on the job
  Message:
    Expected undefined to equal 'hello'.
  Stack:
    Error: Expected undefined to equal 'hello'.
        at <Jasmine>
        at req.message.then.then.jobStatus (/home/travis/build/parse-community/parse-server/spec/CloudCode.spec.js:1571:46)
        at process._tickCallback (internal/process/next_tick.js:68:7)
  Message:
    Expected 'running' to equal 'succeeded'.
  Stack:
    Error: Expected 'running' to equal 'succeeded'.
        at <Jasmine>
        at promise.then.then.jobStatus (/home/travis/build/parse-community/parse-server/spec/CloudCode.spec.js:1580:45)
        at process._tickCallback (internal/process/next_tick.js:68:7)
```

* added travis scripts for postgres

* Setting up before_install and before_script

This should shrink the footprint of the file and and reduce the redundancy of calls for postgres.

Added support for testing of Postgres 9 and 10 in the scripts, not adding the tests though

* make scripts executable

* Update .travis.yml

* add sourcing in script

* trying to fix source

* fixing env var in script

* fixed ; near then

* Cleaning up travis file

removed old lines

* Finishing clean up

* Fixing allow_failures since "name" was removed

* Update .travis.yml

* Removed Postgres 11 from allow_failures

* I think using travis default postgres port of 5433 will allow us to not have to remove anything from the image

* Switching travis to postgres port 5433

* modifying script for test

* modifying script for test

* modifying script for test

* reverting back to working way with removing postgres from image

* Reverted back to removing postgres from image

* removing postgres 12

* removed postgres-12 from allow_failures
2020-03-19 17:29:50 -05:00
greenkeeper[bot]
2c10d9e87f Update commander to the latest version 🚀 (#6504)
* fix(package): update commander to version 5.0.0

* chore(package): update lockfile package-lock.json

Co-authored-by: greenkeeper[bot] <23040076+greenkeeper[bot]@users.noreply.github.com>
2020-03-14 04:21:51 +00:00
Snyk bot
1c2391f44d fix: upgrade graphql-tools from 4.0.6 to 4.0.7 (#6502)
Snyk has created this PR to upgrade graphql-tools from 4.0.6 to 4.0.7.

See this package in NPM:
https://www.npmjs.com/package/graphql-tools

See this project in Snyk:
https://app.snyk.io/org/acinader/project/8c1a9edb-c8f5-4dc1-b221-4d6030a323eb?utm_source=github&utm_medium=upgrade-pr
2020-03-13 15:43:49 -07:00
dependabot[bot]
ed38624028 Bump acorn from 7.1.0 to 7.1.1 (#6503)
Bumps [acorn](https://github.com/acornjs/acorn) from 7.1.0 to 7.1.1.
- [Release notes](https://github.com/acornjs/acorn/releases)
- [Commits](https://github.com/acornjs/acorn/compare/7.1.0...7.1.1)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-03-13 15:43:31 -07:00
greenkeeper[bot]
e8bbde4cf9 Update mongodb to the latest version 🚀 (#6497)
* fix(package): update mongodb to version 3.5.5

* chore(package): update lockfile package-lock.json

Co-authored-by: greenkeeper[bot] <23040076+greenkeeper[bot]@users.noreply.github.com>
2020-03-12 01:20:48 +00:00
Andy
8e0e485de1 use token and algo from jwt header (#6416)
* use token and algo from jwt header

* change node-rsa out for jwks-rsa, reflect change in tests and add one test for coverage

* remove superfluous cache, allow jwks cache parameters to be passed to validateAuthData

* remove package lock

* regenerate package lock

* try fixing package-lock with copy from master

* manual changes for merge conflict

* whitespace

* pass options as object

* fix inconsistent variable name
2020-03-11 15:29:20 -05:00
Antoine Cormouls
16a974a04a Fix Unknow type merge bug on overloaded types (#6494)
* Fix Unknow type bug on overloaded types

* check args too
2020-03-11 12:59:18 -07:00
Snyk bot
35d76b8ff5 fix: upgrade uuid from 3.3.3 to 3.4.0 (#6491)
Snyk has created this PR to upgrade uuid from 3.3.3 to 3.4.0.

See this package in NPM:
https://www.npmjs.com/package/uuid

See this project in Snyk:
https://app.snyk.io/org/acinader/project/8c1a9edb-c8f5-4dc1-b221-4d6030a323eb?utm_source=github&utm_medium=upgrade-pr
2020-03-11 07:21:53 -07:00
Corey
555ae21f8d Attempt to make tests more reliable: travis should only install postgres once
Update .travis.yml (#6490)

* Update .travis.yml

testing error to see what happens...

* Update .travis.yml

Attempting to resolve postgres in CL by installing postgis via sudo instead of through apt/packages

* Update .travis.yml

* Update .travis.yml

* Update .travis.yml

Removed extra lines of postgres that were under "services" and "addons". I believe the "postgresql" line under "services" was installing the default of 9.6 and "addons" was installing postgres 11. My guess is the fail was occurring due to 9.6 being called sometimes and it never had postgis installed. If this is true, the solution is to only install one version of postgres, which is version 11 with postgis 2.5.
2020-03-10 21:12:54 -07:00
Snyk bot
3d4a2c232b fix: upgrade redis from 3.0.0 to 3.0.2 (#6488)
Snyk has created this PR to upgrade redis from 3.0.0 to 3.0.2.

See this package in NPM:
https://www.npmjs.com/package/redis

See this project in Snyk:
https://app.snyk.io/org/acinader/project/8c1a9edb-c8f5-4dc1-b221-4d6030a323eb?utm_source=github&utm_medium=upgrade-pr
2020-03-10 10:36:35 -07:00
Snyk bot
ecc2d11cbd fix: upgrade follow-redirects from 1.9.1 to 1.10.0 (#6489)
Snyk has created this PR to upgrade follow-redirects from 1.9.1 to 1.10.0.

See this package in NPM:
https://www.npmjs.com/package/follow-redirects

See this project in Snyk:
https://app.snyk.io/org/acinader/project/8c1a9edb-c8f5-4dc1-b221-4d6030a323eb?utm_source=github&utm_medium=upgrade-pr
2020-03-10 09:51:01 -07:00
Snyk bot
3068f13e0d fix: upgrade winston-daily-rotate-file from 4.4.0 to 4.4.2 (#6487)
Snyk has created this PR to upgrade winston-daily-rotate-file from 4.4.0 to 4.4.2.

See this package in NPM:
https://www.npmjs.com/package/winston-daily-rotate-file

See this project in Snyk:
https://app.snyk.io/org/acinader/project/8c1a9edb-c8f5-4dc1-b221-4d6030a323eb?utm_source=github&utm_medium=upgrade-pr
2020-03-10 09:50:33 -07:00
greenkeeper[bot]
3c821ba128 Update ws to the latest version 🚀 (#6485)
* fix(package): update ws to version 7.2.3

* chore(package): update lockfile package-lock.json

Co-authored-by: greenkeeper[bot] <23040076+greenkeeper[bot]@users.noreply.github.com>
2020-03-09 19:27:41 +00:00
Siddharth Ramesh
ef17dc4382 Group aggregation supports multiple columns for postgres (#6483)
* Group aggregation supports multiple columns for postgres

* Group aggregation supports multiple columns for postgres

* Group aggregation supports multiple columns for postgres

* Group aggregation supports multiple columns for postgres
2020-03-09 09:18:39 -07:00
greenkeeper[bot]
f69545939b Update ws to the latest version 🚀 (#6478)
* fix(package): update ws to version 7.2.2

* chore(package): update lockfile package-lock.json

Co-authored-by: greenkeeper[bot] <23040076+greenkeeper[bot]@users.noreply.github.com>
2020-03-09 04:21:47 +00:00
Tom Fox
b1f1454c87 Add warning in changelog regarding upgrade to 4.0 and index creation (#6469)
* bump version

* add the special note

* remove new version & add note about indexes to 4.0.2 & 4.0.0

* Update package-lock.json

* Update package.json

* add line break

* remove double space

Co-authored-by: Tom Fox <13188249+TomWFox@users.noreply.github.com>
2020-03-05 21:42:45 +00:00
peril-parse-community[bot]
0407ee45c1 Update cross-env to the latest version 🚀 (#6471)
* chore(package): update cross-env to version 7.0.2

* chore(package): update lockfile package-lock.json
2020-03-05 21:21:51 +00:00
peril-parse-community[bot]
8f4f7d97db Update babel7 to the latest version 🚀 (#6466)
* chore(package): update @babel/core to version 7.8.7

* chore(package): update @babel/preset-env to version 7.8.7

* chore(package): update lockfile package-lock.json
2020-03-05 04:41:18 +00:00
greenkeeper[bot]
209d6f7744 Update apollo-server to the latest version 🚀 (#6460)
* fix(package): update apollo-server-express to version 2.11.0

* chore(package): update lockfile package-lock.json
2020-03-03 22:41:01 +00:00
greenkeeper[bot]
9f1af72363 Update cross-env to the latest version 🚀 (#6461)
* chore(package): update cross-env to version 7.0.1

* chore(package): update lockfile package-lock.json
2020-03-03 22:22:57 +00:00
Arthur Cinader
b9742b6fb9 Prep 4.1 (#6462)
* increment version in prep for 4.1

* changelog for 4.1

* fix security doc link

Co-authored-by: Tom Fox <13188249+TomWFox@users.noreply.github.com>
2020-03-03 11:41:24 -08:00
Arthur Cinader
3a3a5eee5f Merge pull request from GHSA-h4mf-75hf-67w4
* Fix session token issue

* verify email problem

* Fix password reset problem

* Change test file name

* Split tests

* Refetch user

* Replaces lets to consts

* Refactor unit test

What you have is just finee, but wanted
to show you what I meant with my comment

Use jasmine's this to set stuff in beforeEach's

Not that all functions need to be `function ()` instead of
`() =>` so `this` is preserved.

see: https://jasmine.github.io/tutorials/your_first_suite#section-The_%3Ccode%3Ethis%3C/code%3E_keyword

Co-authored-by: Antonio Davi Macedo Coelho de Castro <adavimacedo@gmail.com>
2020-03-02 15:46:01 -08:00
Arthur Cinader
bde8ab6d55 Attempt to get Travis to deploy to npmjs (#6457)
* Use deprecated skip_cleanup
as cleanup: false doesn't
appear to be working

* prepare release

* revert change to branch
2020-03-02 10:46:07 -08:00
greenkeeper[bot]
cfb0327c19 Update bcrypt to the latest version 🚀 (#6456)
* chore(package): update bcrypt to version 4.0.1

* chore(package): update lockfile package-lock.json
2020-03-02 16:49:23 +00:00
Arthur Cinader
cd06a02fe8 skip cleanup so we don't erase babel and stuff (#6452)
* skip cleanup so we don't erase babel and stuff

* skip cleanup the right way!

* Add change log and bump version

* include one more commit

* remove breaking change from non breaking change.

Co-authored-by: Diamond Lewis <findlewis@gmail.com>
2020-02-28 17:34:19 -08:00
greenkeeper[bot]
2a5c306aa8 Update flow-bin to the latest version 🚀 (#6448)
* chore(package): update flow-bin to version 0.119.1

* chore(package): update lockfile package-lock.json
2020-02-29 00:13:48 +00:00
greenkeeper[bot]
c973356a22 Update lint-staged to the latest version 🚀 (#6446)
* chore(package): update lint-staged to version 10.0.8

* chore(package): update lockfile package-lock.json
2020-02-29 00:12:47 +00:00
Old Grandpa
6b0efaeffd Do not allow to protect default fields (#6439)
* consider default columns

* disallow protecting default fields
2020-02-28 15:52:48 -08:00
Arthur Cinader
4291f2b22a Prepare for 4.0 Release (#6412)
* Preparee for 3.11.0 Release

* Little fixes

* add in newly merge pr's into the changelog.

* Remove inconsistent full stops

* bump version to 4.0

* update changelog for v 4.0

* a touch of wordmsithery.

* Nits

Co-authored-by: Tom Fox <13188249+TomWFox@users.noreply.github.com>
2020-02-28 15:22:38 -08:00
greenkeeper[bot]
5947fc33e4 Update babel7 to the latest version 🚀 (#6450)
* chore(package): update @babel/core to version 7.8.6

* chore(package): update @babel/preset-env to version 7.8.6

* chore(package): update lockfile package-lock.json
2020-02-28 22:30:56 +00:00
greenkeeper[bot]
8487d2376f Update babel-eslint to the latest version 🚀 (#6449)
* chore(package): update babel-eslint to version 10.1.0

* chore(package): update lockfile package-lock.json
2020-02-28 22:30:12 +00:00
Arthur Cinader
5c7918980c Set min mongodb to 3.6 in prep for parse-server 4.0 (#6445)
* Set min mongodb to 3.6 in prep for parse-server 4.0

fixes: 6444

* don't use anonymous functions when we can just
pass the function.

Also remove the boolean argument in tests that no longer exists.

* generate the correct lock file.  ooops.
2020-02-27 10:56:14 -08:00
greenkeeper[bot]
9d7da58129 Update flow-bin to the latest version 🚀 (#6438)
* chore(package): update flow-bin to version 0.119.0

* chore(package): update lockfile package-lock.json
2020-02-25 03:52:39 +00:00
Antoine Cormouls
c7f96c92cd GraphQL: Allow true GraphQL Schema Customization (#6360)
* Allow real GraphQL Schema via ParseServer.start

* wip

* working

* tests ok

* add tests about enum/input use case

* Add async function based merge

* Better naming

* remove useless condition
2020-02-21 15:12:49 -08:00
greenkeeper[bot]
d4690ca425 Update bcrypt to the latest version 🚀 (#6433)
* chore(package): update bcrypt to version 4.0.0

* chore(package): update lockfile package-lock.json
2020-02-21 23:10:07 +00:00
Antoine Cormouls
cbef90d66c fix (#6431) 2020-02-21 14:58:51 -08:00
greenkeeper[bot]
259d119374 Update pg-promise to the latest version 🚀 (#6434)
* fix(package): update pg-promise to version 10.4.4

* chore(package): update lockfile package-lock.json
2020-02-21 22:17:45 +00:00
Old Grandpa
292bdb713a Allow protectedFields for Authenticated users and Public. Fix userField with keys/excludedKeys (#6415)
* fix error message and test it

* protected fields fixes

* clean

* remove duplicate test, add some comments

* no need for 'requiresAuthentication'
2020-02-19 01:34:08 -08:00
Diamond Lewis
ca1ae336c9 Websocket: unhandle rejection (#6418)
* Websocket: unhandle rejection

Closes: https://github.com/parse-community/parse-server/issues/6413, https://github.com/parse-community/parse-server/issues/6173
Prevent crashing on websocket error.

Bonus points to anybody who can post a specific payload that the client sends that returns an error.

* log the socket

* fix tests

* fix payload reference link
2020-02-19 01:30:23 -08:00
Diamond Lewis
84b0878d43 Support Travis CI V2 (#6414)
* Support Travis CI V2

[Deployment V2 Docs](https://docs.travis-ci.com/user/deployment-v2)

[Travis Build Validator](https://config.travis-ci.com/explore)

Fixes release build

* try setting variables

* reduce the build matrix

* remove extra test stage
2020-02-16 19:40:41 -08:00
Arthur Cinader
fd0b535159 Case insensitive signup (#5634)
* Always delete data after each, even for mongo.

* Add failing simple case test

* run all tests

* 1. when validating username be case insensitive

2. add _auth_data_anonymous to specialQueryKeys...whatever that is!

* More case sensitivity

1. also make email validation case insensitive
2. update comments to reflect what this change does

* wordsmithery and grammar

* first pass at a preformant case insensitive query.  mongo only so far.

* change name of parameter from insensitive to
caseInsensitive

* Postgres support

* properly handle auth data null

* wip

* use 'caseInsensitive' instead of 'insensitive' in all places.

* update commenet to reclect current plan

* skip the mystery test for now

* create case insensitive indecies for
mongo to support case insensitive
checks for email and username

* remove unneeded specialKey

* pull collation out to a function.

* not sure what i planned
to do with this test.
removing.

* remove typo

* remove another unused flag

* maintain order

* maintain order of params

* boil the ocean on param sequence
i like having explain last cause it seems
like something you would
change/remove after getting what you want
from the explain?

* add test to verify creation
and use of caseInsensitive index

* add no op func to prostgress

* get collation object from mongocollection
make flow lint happy by declaring things Object.

* fix typo

* add changelog

* kick travis

* properly reference static method

* add a test to confirm that anonymous users with
unique username that do collide when compared
insensitively can still be created.

* minot doc nits

* add a few tests to make sure our spy is working as expected
wordsmith the changelog

Co-authored-by: Diamond Lewis <findlewis@gmail.com>
2020-02-14 09:44:51 -08:00
greenkeeper[bot]
1ea3f864a8 Update apollo-server to the latest version 🚀 (#6409)
* fix(package): update apollo-server-express to version 2.10.1

* chore(package): update lockfile package-lock.json
2020-02-14 14:27:37 +00:00
greenkeeper[bot]
46209266c7 Update husky to the latest version 🚀 (#6406)
* chore(package): update husky to version 4.2.3

* chore(package): update lockfile package-lock.json
2020-02-13 04:07:18 +00:00
greenkeeper[bot]
8074dfd27d Update mongodb to the latest version 🚀 (#6404)
* fix(package): update mongodb to version 3.5.3

* chore(package): update lockfile package-lock.json
2020-02-12 13:04:37 +00:00
greenkeeper[bot]
8f6e897491 Update husky to the latest version 🚀 (#6402)
* chore(package): update husky to version 4.2.2

* chore(package): update lockfile package-lock.json
2020-02-12 06:22:23 +00:00
greenkeeper[bot]
ea59f12ac2 Update semver to the latest version 🚀 (#6401)
* fix(package): update semver to version 7.1.3

* chore(package): update lockfile package-lock.json
2020-02-12 00:03:19 +00:00
David Corona
09a1dca5e3 Add new afterLogin cloud code hook (#6387)
* add new afterLogin cloud code hook

* include user on req.user for afterLogin hook
2020-02-11 17:38:14 -06:00