Skip to content

API: /competitions/{id}/results does not work #1437

Closed

Description

@johann-petrak

When trying to use that URL, using an auth token of my user which is definitely the user that created that competition (johannpetrak):

curl -X GET "https://www.codabench.org/api/competitions/2744/results/" -H  "accept: application/json" -H  "Token: [TOKEN]"

I get the response: {"detail":"You are not a competition admin or superuser"}

Trying the same from python I just get a server error code 500 response.

Using the token works for other protected API calls e.g. downloading the submissions.

However other API calls also do not work as expected e.g. /api/competitions/2744/get_files/ which returns: {"detail":"You don't have access to the competition files"}

Activity

  1. ihsaan-ullah commented on Jul 13, 2024

    @ihsaan-ullah
    Collaborator

    get_files api is working on my side
    https://www.codabench.org/api/competitions/2744/get_files/

    From the code: super user and competition admins can access files

    Screenshot 2024-07-13 at 9 19 09 PM
  2. ihsaan-ullah commented on Jul 13, 2024

    @ihsaan-ullah
    Collaborator

    https://www.codabench.org/api/competitions/2744/results/ gives 500 error which needs to be checked but the error You are not a competition admin or superuser is correct. Only admins can access this

  3. self-assigned this
    on Feb 20, 2025
  4. linked a pull request that will close this issueCompetition results api fixed #1757on Feb 20, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions