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

feat: allow anonymous user navigation in the project's collaboration tab #987

Merged
merged 3 commits into from
Jul 30, 2020

Conversation

lorenzo-cavazzi
Copy link
Member

@lorenzo-cavazzi lorenzo-cavazzi commented Jul 21, 2020

Issues APIs require authentication to get the full discussion. This PR uses an undocumented GitLab API to allow anonymous users to access the same content. It's the same API currently used in the GitLab UI. More details in this discussions https://gitlab.com/gitlab-org/gitlab/-/issues/217369
It requires SwissDataScienceCenter/renku-gateway#251

fix #905

Preview
https://lorenzotest.dev.renku.ch

How to test
Check issues on a public project as an anonymous users.
This is a sample project: https://lorenzotest.dev.renku.ch/projects/noemail/scratch-project/collaboration/issues/1/

Issues APIs require authentication to get the full discussion. This PR uses an  undocumented GitLab
API to allow anonymous users to access the same content. It's the same API currently used in the
GitLab UI. More details https://gitlab.com/gitlab-org/gitlab/-/issues/217369

fix #905
@lorenzo-cavazzi lorenzo-cavazzi requested a review from a team as a code owner July 21, 2020 09:56
@lorenzo-cavazzi lorenzo-cavazzi added this to the sprint-2020-07-09 milestone Jul 21, 2020
Copy link
Contributor

@ciyer ciyer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code looks good, but I see different things when I'm logged in vs. logged out.

Logged In

image

Logged Out

image

Shouldn't I see the discussion when not logged in as well?

@lorenzo-cavazzi
Copy link
Member Author

I see the same content 🤔 It's possible that the gateway pod was not up-to-date?
I deployed a preview to https://lorenzotest.dev.renku.ch/
Could you try again https://lorenzotest.dev.renku.ch/projects/noemail/scratch-project/collaboration/issues/1 ?

Screenshot_20200722_180444

Copy link
Contributor

@ciyer ciyer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍 Very nice! It looks like the problem was the gateway pod, as you wrote.

@lorenzo-cavazzi lorenzo-cavazzi merged commit a6fe6fe into master Jul 30, 2020
@lorenzo-cavazzi lorenzo-cavazzi deleted the 905-issues branch July 30, 2020 13:41
ciyer pushed a commit that referenced this pull request Sep 9, 2020
…tab (#987)

Use undocumented GitLab API to allow anonymous users to access public issues discussions. The API is currently used in the GitLab UI.
Reference: https://gitlab.com/gitlab-org/gitlab/-/issues/217369

fix #905

(cherry picked from commit a6fe6fe)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Logged-out users are redirected to the login page on the issue page
2 participants