Skip to content

[$80]Challenge Listings: clicking on #of registrants or submissions loads a blank page #4408

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

Closed
SathyaJayabal opened this issue May 25, 2020 · 31 comments

Comments

@SathyaJayabal
Copy link
Collaborator

SathyaJayabal commented May 25, 2020

Challenge Listings: Past Contests Bucket- clicking on #of registrants or submissions loads a blank page. This is related to #4381 . Clicking on # of registrants should open the challenge details page with the registrants tab selected. Clicking on # of submissions should open the challenge details page with the submissions tab selected. Since these tabs are not present on the challenge details page, a blank page is loaded.
https://test-community-app.topcoder-dev.com/challenges?bucket=past&tab=submissions
https://test-community-app.topcoder-dev.com/challenges?
user: dan_developer/appirio123

regis.mov.zip
subs.mov.zip

@sushilshinde sushilshinde removed their assignment May 25, 2020
@SathyaJayabal SathyaJayabal changed the title Challenge Listings: Past Contests Bucket- clicking on #of registrants or submissions loads a blank page Challenge Listings: clicking on #of registrants or submissions loads a blank page May 25, 2020
@SathyaJayabal SathyaJayabal added the Test Env Environment label May 26, 2020
@sushilshinde sushilshinde changed the title Challenge Listings: clicking on #of registrants or submissions loads a blank page [$50]Challenge Listings: clicking on #of registrants or submissions loads a blank page May 26, 2020
@crazyk07
Copy link

Contest https://www.topcoder.com/challenges/30126691 has been created for this ticket.

This is an automated message for crazyk via Topcoder X

@crazyk07
Copy link

Contest https://www.topcoder.com/challenges/30126691 has been updated - it has been assigned to luizrrodrigues.

This is an automated message for crazyk via Topcoder X

@mtwomey
Copy link
Contributor

mtwomey commented May 27, 2020

@luizrrodrigues Do you have an ETA on this one?

@luizrrodrigues
Copy link
Collaborator

@mtwomey Working on this right now, plan to complete today.

@luizrrodrigues
Copy link
Collaborator

UPDATE: Currently we have an issue to get registrants from the challenge. Tracking the request here: #4381 (comment)

@luizrrodrigues
Copy link
Collaborator

luizrrodrigues commented Jun 4, 2020

The main problem here is about missing registrants and submissions from API V5 return.

Fixes done in Draft PR:

  • Fixed SSR flow to get new UUID from challenge
  • Added support to receive lagacyId and UUID in routes
  • Update getChallengeRegistrants():
    • Execute only in SSR
    • Get roleId via getResourceRoleId()
    • Call /resources with m2mToken
  • That validation if received challenge tag before call recommendedChallenges()
  • Updated vars to match with V5 return

Blockers:

cc @sushilshinde @Oanh-and-only-Oanh

@rootelement
Copy link
Contributor

  • Submissions will have to come from the Submissions api.
  • Resources API now returns Rating on the resource object. The color will have to be computed on the frontend.
  • Filter by Role ID is now working.

@luizrrodrigues
Copy link
Collaborator

Thanks @rootelement, one more question about registrants return:

  • Not include registrants.submissionDate, so I need to get from submissions_api and merge in the frontend, right?

@rootelement
Copy link
Contributor

rootelement commented Jun 5, 2020 via email

@sushilshinde
Copy link
Collaborator

@luizrrodrigues even on current production submissions are coming from v5 submission API

@SathyaJayabal
Copy link
Collaborator Author

@sushilshinde in V4 we get an array of submitters and their submissions from the challenge api. The actual submission from the submission id is got submissions api. In V5 this initial information is not present.

Screenshot 2020-06-05 at 6 23 06 PM

@luizrrodrigues
Copy link
Collaborator

luizrrodrigues commented Jun 5, 2020

@rootelement Thanks.

fyi: submissions_api not allow new challenge UUID. (I'm using legacyId for now.)
image

topcoder-platform/submissions-api#179

@luizrrodrigues
Copy link
Collaborator

@sushilshinde : @SathyaJayabal is right, I'll need additional work to merge submission initial data in challenge details return and also to update new vars/params return from v5 API in Submissions Page.

@luizrrodrigues
Copy link
Collaborator

The main problem here is about missing registrants and submissions from API V5 return.

Fixes done in PR:

  • Fixed SSR flow to get new UUID from challenge
  • Added support to receive lagacyId and UUID in routes
  • Update getChallengeRegistrants():
    • Execute call via tc proxy
    • Get roleId via getResourceRoleId()
    • Call /resources via tc proxy
  • Added getChallengeSubmissions():
    • Call /submissions via tc proxy
  • That validation if received challenge tag before call recommendedChallenges()
  • Updated vars to match with V5 return
  • registrants.rating was add to API return (thanks @rootelement)
  • registrants.submissionDate merged this data from submission call

Remain:

  • registrans.colorStyle: As @rootelement said, we need to add this via frontend, before this was provided by API. I'm tried to find how this was calculated in topcoder-api-challenges but looks like this coming from DB. @rootelement thoughts?
    • So for now, all member will show with black color
  • /submissions - Like @SathyaJayabal said above, the V5 submissions_api is different, I was to binding data, but the structure is different too, I'll post here all data missing and not possible bing with what V5 provides now.

@sushilshinde @Oanh-and-only-Oanh I think we can move this to a new issue and merge the PR's. (include fixes to #4380 and #4381)

@SathyaJayabal SathyaJayabal added QA Fail QA verification on Dev has failed. Assignee to redo the fix. and removed Ready for QA labels Jun 8, 2020
@SathyaJayabal
Copy link
Collaborator Author

@luizrrodrigues @sushilshinde , challenge details page is throwing an error
Screenshot 2020-06-08 at 5 42 28 PM

@luizrrodrigues
Copy link
Collaborator

@SathyaJayabal can you attach a screenshot of error in console?

@rootelement looks like we getting error “internal server error” when try get registrants from some projects.

@rootelement
Copy link
Contributor

Debugging this now

@rootelement
Copy link
Contributor

I need IDs to confirm and if this is in dev or prod please as well @SathyaJayabal

@rootelement
Copy link
Contributor

Again, this returns data from the API:
http://api.topcoder-dev.com/v5/challenges/d741f46c-fb1b-4ead-8112-4c2a674b3c7f

In the resource api, i'm seeing these errors:

[31merror�[39m: Error happened in ResourceRoleController#getResourceRoles
�[31merror�[39m: ErrorCtor [ForbiddenError]: You are not allowed to perform this action!

What is calling GET v5/resource-roles? That should be from a system with an m2m, not a frontend. @luizrrodrigues Can you please provide the API calls that you're making so I can confirm?

@SathyaJayabal
Copy link
Collaborator Author

@rootelement , this happens in both dev and prod and foe all challenges. This is the same issue documented here
#4493

here are a few examples:
https://test-community-app.topcoder-dev.com/challenges/d741f46c-fb1b-4ead-8112-4c2a674b3c7f
https://beta-community-app.topcoder.com/challenges/e4b154cc-4430-453c-ba76-3cf47d05dedc

@rootelement
Copy link
Contributor

Pushing an update to resources to increase logging

@rootelement
Copy link
Contributor

I was able to view this challenge details, and register for the challenge in dev.
Screen Shot 2020-06-08 at 6 56 04 PM

I'm still seeing an issue with the submissions page. I just get a white page.

@mtwomey
Copy link
Contributor

mtwomey commented Jun 14, 2020

@luizrrodrigues I'm curious about what going on with this one - are we wanting on any changes from anyone else or is this one progressing?

@luizrrodrigues
Copy link
Collaborator

@mtwomey
Copy link
Contributor

mtwomey commented Jun 14, 2020

OK thank you @luizrrodrigues

@rootelement
Copy link
Contributor

@sushilshinde why is this changing now? There are no unauthed endpoints on the resources API. Can we do this as it's been done up until now and we can reevaluate after V5 1.0 release?

@sushilshinde
Copy link
Collaborator

@luizrrodrigues we will split these tickets into two and will assign you separately

@crazyk07
Copy link

This ticket was not processed for payment. If you would like to process it for payment, please reopen it, add the tcx_FixAccepted label, and then close it again

This is an automated message for crazyk via Topcoder X

@SathyaJayabal SathyaJayabal added QA Pass and removed QA Fail QA verification on Dev has failed. Assignee to redo the fix. labels Jun 15, 2020
@sushilshinde
Copy link
Collaborator

sushilshinde commented Jun 15, 2020

New tickets

#4536
#4537

@SathyaJayabal
Copy link
Collaborator Author

Fixed along with
#4521
#4517

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

8 participants