Project

General

Profile

action #80492

[easy] API help document says "Deletes …" for routes like "test_suites/:id" PUT and POST and looks inconsistent

Added by okurz about 2 months ago. Updated about 2 months ago.

Status:
Resolved
Priority:
Normal
Assignee:
Category:
Feature requests
Target version:
Start date:
2020-11-27
Due date:
2020-12-12
% Done:

0%

Estimated time:
Difficulty:
easy

Description

Observation

On https://openqa.opensuse.org/not_found one sees

+/test_suites/:id       PUT     test_suitesid   Deletes a table …

Problems

  • It says "delete" for the PUT method, also POST
  • there is no "apiv1_…" in the route name
  • Looks like the same text is put on all methods here
  • Maybe same problem appears for other routes

Suggestions

  • Find the route definitions in https://github.com/os-autoinst/openQA/blob/master/lib/OpenQA/WebAPI.pm#L389
  • Crosscheck and correct the "name" parameter
  • Correct the comment that is defined in lib/OpenQA/WebAPI/Controller/API/V1/Table.pm and either incorrectly read out or needs to be updated. likely the method "_verify_table_usage" has just in the middle between the correct comment for "update" and the method definition it self

History

#1 Updated by okurz about 2 months ago

  • Subject changed from API help document says "Deletes …" for routes like "test_suites/:id" PUT and POST and looks inconsistent to [easy] API help document says "Deletes …" for routes like "test_suites/:id" PUT and POST and looks inconsistent
  • Difficulty set to easy

#2 Updated by okurz about 2 months ago

  • Description updated (diff)

#3 Updated by mkittler about 2 months ago

  • Assignee set to mkittler

#4 Updated by mkittler about 2 months ago

  • Status changed from Workable to In Progress

#5 Updated by okurz about 2 months ago

  • Due date set to 2020-12-12

Setting due date based on mean cycle time of SUSE QE Tools

#6 Updated by okurz about 2 months ago

I see that +/test_suites/:id PUT "apiv1_put_test_suite" is on https://openqa.opensuse.org/foo_bar but also +/test_suites POST test_suites . same for "machines", Shouldn't this be "apiv1_post_test_suites" and "apiv1_post_machines"?

#7 Updated by mkittler about 2 months ago

  • Status changed from In Progress to Feedback

PR has been merged. I see apiv1_post_test_suite and apiv1_post_machine on the 404 page. Not sure what you mean.

#8 Updated by mkittler about 2 months ago

  • Status changed from Feedback to Resolved

The problem this ticket is about is solved. I created another PR for improving the 404 page a little bit more: https://github.com/os-autoinst/openQA/pull/3617

Also available in: Atom PDF