Created on 5 January 2021, almost 4 years ago
Updated 9 June 2023, over 1 year ago

Problem/Motivation

We will need to migrate data from the old farm_mushroom module for farmOS 2.x to the new farm_fungi module for farmOS 2.x.

I have already created a basic Fungi asset type migration that will migrate substrate assets from 1.x to the new fungi asset type. However, this does not currently touch the "substrate type" or "quantity" fields on the old asset type. I'm thinking about moving these pieces of information to a new "Inoculation" log type: ✨ New log type: Inoculate Closed: won't fix

Remaining tasks

-
- ...

User interface changes

(tbd)

API changes

(tbd)

Data model changes

(tbd)

πŸ“Œ Task
Status

Fixed

Version

2.0

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States m.stenta

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • πŸ‡ΊπŸ‡ΈUnited States m.stenta

    I'm thinking about moving these pieces of information to a new "Inoculation" log type: ✨ New log type: Inoculate Closed: won't fix

    Updated thinking: "Substrate type" will stay on the Fungi asset (like it was in the 1.x farm_mushroom module)

    I may just migrate the quantity to the Notes field for 1.x data preservation, and moving forward users can take advantage of farmOS's inventory management to keep track of quantities. We don't need a separate inoculation log type for that. A simple Activity log will do. And in the future we can think about providing some quick forms in this module to standardize that.

  • πŸ‡ΊπŸ‡ΈUnited States m.stenta

    I may just migrate the quantity to the Notes field for 1.x data preservation

    Small problem with this: the quantity data is stored in a Quantity Field Collection in the 1.x database. The farmOS v2 migration automatically migrates all of these into Quantity entities... but this happens AFTER assets are migrated. So we'll need to query the 1.x quantity field collection database tables directly in order to get that information.

    This also means that the old quantity entities will be migrated, but will not be referenced by any assets/logs in the new database, so they will be orphaned. This probably won't break anything, but it leaves a bit of a mess, and ultimately it is this module's fault for using quantities on assets in the first place. Maybe we can add some kind of post-migration logic that runs after the quantity migration to delete the ones we know will be orphans?

  • πŸ‡ΊπŸ‡ΈUnited States m.stenta

    Maybe we can add some kind of post-migration logic that runs after the quantity migration to delete the ones we know will be orphans?

    Or... if this is difficult, maybe we just provide some cleanup instructions in the 2.0.0 release notes for anyone who is upgrading from v1. According to drupal.org there are only 2 installations - and I know I'm one of them. :-)

    https://www.drupal.org/project/usage/farm_mushroom β†’

  • Status changed to Fixed over 1 year ago
  • πŸ‡ΊπŸ‡ΈUnited States m.stenta
  • Automatically closed - issue fixed for 2 weeks with no activity.

Production build 0.71.5 2024