Project

General

Profile

Actions

Bug #3954

closed

Info commands must always use IDs instead of names in api calls

Added by Tomáš Strachota almost 11 years ago. Updated over 6 years ago.

Status:
Closed
Priority:
Normal
Category:
Hammer core
Target version:
Difficulty:
Triaged:
Team Backlog:
Fixed in Releases:
Found in Releases:
In Kanboard:

Description

Info commands allow to search resources by both --id and --name. API currently allows to search by either of them, which does not always work as expected. See #3876 for details.
When the --name is passed we need to perform search by name first and then use the found ID in the api show call.


Related issues 1 (0 open1 closed)

Related to Foreman - Bug #3876: API find_resource by name finds by ID instead when first character of name is a digitClosedJoseph Magen12/13/2013Actions
Actions #1

Updated by Tomáš Strachota almost 11 years ago

  • Subject changed from Info commands must always use IDs insteda of names in api calls to Info commands must always use IDs instead of names in api calls
Actions #2

Updated by Tomáš Strachota almost 11 years ago

  • Related to Bug #3876: API find_resource by name finds by ID instead when first character of name is a digit added
Actions #3

Updated by Tomáš Strachota almost 11 years ago

  • Status changed from New to Assigned
  • Assignee set to Tomáš Strachota
  • Target version set to 1.9.2
Actions #4

Updated by Tomáš Strachota almost 11 years ago

Waiting for http://projects.theforeman.org/issues/3897 as it will be much easier to fix with. I've got the fix ready in a branch, will create a PR once the mentioned issue gets merged.

Actions #6

Updated by Anonymous almost 11 years ago

  • Status changed from Ready For Testing to Closed
  • % Done changed from 0 to 100

Applied in changeset foreman:hammer-cli|commit:62845e9a20cc942d01f64be52b59b4227340fa04.

Actions

Also available in: Atom PDF