#285 Fix bug where text is shown under Event key
Closed by yashn. Opened by yashn.
fix_event_key_bug  into  master

Download 285.patch

So I tried ./freshmaker-cli --redhat --qe and under Event key, a string was shown instead of an integer for the ones having their state as 'complete'. Hence, I added a check to see if the Event key we are extracting is an int. If not, I am using the State reason attribute to extract the Event key

Can someone please run the command mentioned in the description and confirm. I hope I am not missing something. Thank you

The fix should be probably in FreshmakerManualRebuildEvent and define

    @property
    def search_key(self):
        return self.errata_id

@cqi: That won't help, because the freshmaker-cli queries frontend and it returns data from database using models.Event.json. We store search key as string in database, which is expected, because search_key is a key which should identify the rebuild trigger source for given event type.

So for ErrataAdvisoryRPMsSignedEvent event type, it is errata advisory ID, which is integer, but for FreshmakerManualRebuildEvent, it is ID if UMB message triggering the manual rebuild, which is string.

@yashn: What is the real issue you are trying to solve here?

@jkaluza : As I mentioned in the description, for some freshmaker events, Event key(actually search_key) is printed as a random string whereas it should be an integer. Especially for the one's whose state is complete. You can regenerate what I am talking about by running this (./freshmaker-cli --redhat --qe) command

It turns out I had a misunderstanding. Sorry about that. this bug is non-existent :)

Pull-Request has been closed by yashn

Metadata