Giter VIP home page Giter VIP logo

Comments (13)

vmihalko avatar vmihalko commented on June 17, 2024 1

image
@lzaoral asked me to illustrate this issue.

from openscanhub.

lzaoral avatar lzaoral commented on June 17, 2024 1

@psimovec has volunteered to handle the necessary kobo updates. (BTW, that kobo version also brings in the correct inheritance of task priorities.)

from openscanhub.

kdudka avatar kdudka commented on June 17, 2024

I am afraid you need to provide more details if you expect anybody else to take this. If you noted it for yourself to eventually get back to this, so be it.

from openscanhub.

lzaoral avatar lzaoral commented on June 17, 2024

The code that is responsible for updating of the subtask count field is the following method in kobo:
https://github.com/release-engineering/kobo/blob/986f2a305f9c675dbb54e34c91f09e443e328af3/kobo/hub/models.py#L598-L605

from openscanhub.

lzaoral avatar lzaoral commented on June 17, 2024

I believe it is quite clear that that number corresponds to the id of the task (red text added by me) because the newest value corresponds to the actual count of all tasks:

image

But I'm not sure why that happens, the code from kobo is quite explicit about using the correct value of the subtask_count property:

    def save(self, *args, **kwargs):
        # save to db to precalculate subtask counts and obtain an ID (on insert) for stdout and traceback
        super(self.__class__, self).save()
        self.subtask_count = self.subtasks().count()
        super(self.__class__, self).save()
        self.logs.save()
        if self.parent:
            self.parent.save(*args, **kwargs)

from openscanhub.

lzaoral avatar lzaoral commented on June 17, 2024

I've analysed tasks on the staging instance and the wrong values began appearing just when we migrated to RHEL 8 and Python 3.

from openscanhub.

lzaoral avatar lzaoral commented on June 17, 2024

I could not reproduce this locally until @kdudka suggested to use the same version of kobo as we use on the staging instance (Thanks a lot!). Something was fixed between master and the kobo-0.25.0 tag.

from openscanhub.

lzaoral avatar lzaoral commented on June 17, 2024

The issue was fixed in upstream kobo by release-engineering/kobo#185. Therefore, we should make sure to update kobo in EPEL to at least kobo-0.26.0. After that, I'll create a one-time migration to recompute subtask_count property for all tasks.

from openscanhub.

kdudka avatar kdudka commented on June 17, 2024

Nice. Thank you for tracking it down!

from openscanhub.

lzaoral avatar lzaoral commented on June 17, 2024

EPEL 8 kobo Bodhi update: https://bodhi.fedoraproject.org/updates/FEDORA-EPEL-2023-1346547daa

from openscanhub.

lzaoral avatar lzaoral commented on June 17, 2024

@kdudka Is anything blocking this MR? It should not cause any disturbances unless the migration is executed.

from openscanhub.

kdudka avatar kdudka commented on June 17, 2024

@kdudka Is anything blocking this MR?

Nothing I know of. Did we test this on a staging instance?

It should not cause any disturbances unless the migration is executed.

True but migrations are executed automatically upon each update.

from openscanhub.

lzaoral avatar lzaoral commented on June 17, 2024

I've only tested this migration on my local instance with a restored database backup when I've originally created that MR.

from openscanhub.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.