#2497 getLastHostUpdate returns time only as a string
Closed: Fixed 2 years ago by tkopecek. Opened 3 years ago by mikem.

In general, Koji hub calls return times as both a text field and an integer field. The text field does not have a strictly defined format and has changed over time (e.g. the issue in #2423, caused by the changes from #2160).

I generally recommend that clients that need to process times beyond just displaying the returned string use the integer fields (typically ending in _ts). However this call only returns the string.

Since the return here is single valued. I think the best way to address this without breaking the api is to add a flag to the call to request a timestamp instead.

If we make this change, we might also want to use that option in the cli and web interfaces where we use this call.


Metadata Update from @tkopecek:
- Custom field Size adjusted to None
- Issue set to the milestone: 1.24

3 years ago

Metadata Update from @tkopecek:
- Issue set to the milestone: 1.25 (was: 1.24)

3 years ago

Metadata Update from @tkopecek:
- Issue untagged with: discussion
- Issue tagged with: testing-ready

3 years ago

Looks like check for invalid host_id input is missing:

[ERROR] koji: Fault: <Fault 1: "<class 'AttributeError'>: 'NoneType' object has no attribute 'timestamp'">

Metadata Update from @jobrauer:
- Issue tagged with: testing-done

3 years ago

Metadata Update from @tkopecek:
- Issue status updated to: Open (was: Closed)

3 years ago

Doesn't work against older hub (e.g. list-hosts will fail)

Metadata Update from @tkopecek:
- Issue untagged with: testing-done

3 years ago

Commit 5006625 relates to this ticket

Metadata Update from @mfilip:
- Issue tagged with: testing-done

3 years ago

Metadata Update from @jcupova:
- Issue status updated to: Open (was: Closed)

2 years ago

Login to comment on this ticket.

Metadata
Related Pull Requests
  • #2857 Merged 2 years ago
  • #2810 Merged 3 years ago
  • #2798 Merged 3 years ago
  • #2766 Merged 3 years ago