Skip to content

expandAdventures breaks packing occasionally #89

@MrVauxs

Description

@MrVauxs

Hey, I was greatly enjoying the newly added expandAdventures option when making adventure-heavy premium modules and I have come across an issue.

For some reason one of the adventures has the cli (programmatic, via compilePack) failing on

let [, collection] = doc._key.split("!");
// TypeError: Cannot read properties of undefined (reading 'split')

I confirmed the files do not have a _key in them, but neither do all other expandAdventures exports, and they are building without issue.
I don't know how to fix this exactly since I don't see that expandAdventures exports should have _key, and if they should I don't know what key it would be.

The adventure JSON exists so it should presumably be finding that one first and checking it for its contents. However, by the looks of it the compileClassicLevel doesn't enforce any ordering of the files, so a document belonging to an adventure can be read before the adventure doc.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions