Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(api): Regression on Data Export API + side effects between API tests #418

Merged
merged 21 commits into from
Dec 19, 2020

Conversation

adrienjoly
Copy link
Member

@adrienjoly adrienjoly commented Dec 19, 2020

What does this PR do / solve?

openwhyd-pl-dl does not work anymore because the $PROFILE_URL/playlists?format=list route returns an HTML page instead of the list of playlists for that user. that's actually ok

Related observation: Problem: https://openwhyd.org/adrien/playlist/1?format=json return {"errorCode":"USER_NOT_FOUND","error":"User not found..."}, while https://openwhyd.org/u/4d94501d1f78ac091dbc9b4d/playlist/1?format=json returns the tracklist as expected.

@adrienjoly adrienjoly self-assigned this Dec 19, 2020
@adrienjoly adrienjoly added the bug label Dec 19, 2020
@adrienjoly adrienjoly changed the title local optim: run docker:seed just once fix(api): Regression on Data Export API Dec 19, 2020
@adrienjoly adrienjoly marked this pull request as ready for review December 19, 2020 17:42
@adrienjoly adrienjoly changed the title fix(api): Regression on Data Export API fix(api): Regression on Data Export API + side effects between API tests Dec 19, 2020
@adrienjoly adrienjoly merged commit f4f1466 into master Dec 19, 2020
@adrienjoly adrienjoly deleted the fix/export-data-api-regression branch December 19, 2020 17:56
adrienjoly pushed a commit that referenced this pull request Dec 19, 2020
## [1.44.9](v1.44.8...v1.44.9) (2020-12-19)

### Bug Fixes

* **api:** Regression on Data Export API + side effects between API tests ([#418](#418)) ([f4f1466](f4f1466))
adrienjoly added a commit that referenced this pull request Dec 19, 2020
adrienjoly pushed a commit that referenced this pull request Dec 19, 2020
## [1.44.10](v1.44.9...v1.44.10) (2020-12-19)

### Reverts

* Revert "fix(api): Regression on Data Export API + side effects between API tests (#418)" ([679cbd7](679cbd7)), closes [#418](#418)
adrienjoly added a commit that referenced this pull request Dec 19, 2020
…sts (#418)

* local optim: run docker:seed just once

* test: "data export api provides profile tracks of given user id"

* Revert "local optim: run docker:seed just once"

This reverts commit 93d9f65.

* test: "provides profile tracks of given user id, as a list of links"

* add same tests by username instead of user_id

* new tests: "provides playlist tracks of given user id"

* same, with username => error because "admin" user handle conflicts with admin routes

* => use DUMMY_USER to prevent conflict between handle and admin routes => "User not found..." error

* fix: don't let the presence of a playlistId preempt the retrieval of user by their handle

* add links to API docs

* fix: use DUMMY_USER instead of ADMIN_USER in post.api.tests.js

* extract data.api.tests.js from user.api.tests.js

* ❌ new test: "provides list of playlists"

* fix: make the /playlists handler return the actual list of playlists

* /playlists route now works in JSON format

* fix tests

* fix test expectation

* normalize formatting conditions

* make "bareFormats" ('json' / 'links') easier to find

* clean up playlist processing logic

(cherry picked from commit f4f1466)
adrienjoly added a commit that referenced this pull request Dec 19, 2020
…n API tests (#419)

Re-apply PR #418 with hotfix.

Problem: error when trying to open https://openwhyd.org/adrien/playlist:
- error while calling "_id.getTimestamp()", at `  var when = post._id ? post._id.getTimestamp().getTime() : undefined;` (`app/templates/posts.js`)
adrienjoly pushed a commit that referenced this pull request Dec 19, 2020
## [1.44.11](v1.44.10...v1.44.11) (2020-12-19)

### Bug Fixes

* **api:** [retry] Regression on Data Export API + side effects between API tests ([#419](#419)) ([35e05a1](35e05a1)), closes [#418](#418)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant