New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"reboot" can't find collections #746

Open
adamwestman opened this Issue May 2, 2017 · 5 comments

Comments

Projects
None yet
2 participants
@adamwestman

adamwestman commented May 2, 2017

Expected behaviour

When I tell the system to reboot using my tests.collection it should reboot and run my tests, like it did in Editor1.

Actual behaviour

WARNING:RESOURCE: Resource not found: /tests/tests.collectionc

Steps to reproduce

Ensure you have a tests.collection in folder /tests/

-- reboot to run tests.
local arg1 = '--config=bootstrap.main_collection=/tests/tests.collectionc'
local arg2 = 'build/default/game.projectc'
msg.post("@system:", "reboot", {arg1 = arg1, arg2 = arg2})

Defold version1.2.103
Defold sha833462a6249bc9b0a58f57e706040b6bc3cd264f
Build time2017-05-02T10:11:48.998573
OS nameMac OS X
OS version10.12.4
OS archx86_64
Java version1.8.0_102-b14

@adamwestman adamwestman changed the title from "reboot" can't find collections to "reboot" can't find collections Blocker May 2, 2017

@RagnarSvenssonKing RagnarSvenssonKing changed the title from "reboot" can't find collections Blocker to "reboot" can't find collections May 3, 2017

@RagnarSvenssonKing RagnarSvenssonKing self-assigned this May 4, 2017

@RagnarSvenssonKing

This comment has been minimized.

Show comment
Hide comment
@RagnarSvenssonKing

RagnarSvenssonKing May 4, 2017

Contributor

There is a work-around for this issue: add tests.collection to a collection factory which you put somewhere in your game. You don't need to send any messages to it, it's enough for it to just be referenced.
The underlying issue is that we only build the files you are using. In this case tests.collection is not referenced anywhere and will consequently not be built (thereby giving you that error). There are a few alternatives how to fix this issue so I will give it some thought before proceeding.

Contributor

RagnarSvenssonKing commented May 4, 2017

There is a work-around for this issue: add tests.collection to a collection factory which you put somewhere in your game. You don't need to send any messages to it, it's enough for it to just be referenced.
The underlying issue is that we only build the files you are using. In this case tests.collection is not referenced anywhere and will consequently not be built (thereby giving you that error). There are a few alternatives how to fix this issue so I will give it some thought before proceeding.

@RagnarSvenssonKing

This comment has been minimized.

Show comment
Hide comment
@RagnarSvenssonKing

RagnarSvenssonKing May 4, 2017

Contributor

It seems like this requires a new feature where you would specify dependencies like these, i.e. files you expect to use but are not really a part of the game. Because of the easy work-around with collection factories, I'll remove the blocker-label and we will deal with this later.

Contributor

RagnarSvenssonKing commented May 4, 2017

It seems like this requires a new feature where you would specify dependencies like these, i.e. files you expect to use but are not really a part of the game. Because of the easy work-around with collection factories, I'll remove the blocker-label and we will deal with this later.

@adamwestman

This comment has been minimized.

Show comment
Hide comment
@adamwestman

adamwestman May 8, 2017

Unfortunately the proposed solution does not work in all circumstances. One of the collections in question has a collectionproxy pointing at the main-one, resulting in the following error from the circular dependancy:

java.lang.AssertionError: Assert failed: Cycle detected on node type editor.collection/CollectionNode and output :build-targets
(not (contains? (:in-production ctx) [node-id label]))

The purpose is to reboot with a different entry-point, responsible for attaching extra startup scripts and then proxy load our main collection to run our cucumber test-suit.

adamwestman commented May 8, 2017

Unfortunately the proposed solution does not work in all circumstances. One of the collections in question has a collectionproxy pointing at the main-one, resulting in the following error from the circular dependancy:

java.lang.AssertionError: Assert failed: Cycle detected on node type editor.collection/CollectionNode and output :build-targets
(not (contains? (:in-production ctx) [node-id label]))

The purpose is to reboot with a different entry-point, responsible for attaching extra startup scripts and then proxy load our main collection to run our cucumber test-suit.

@RagnarSvenssonKing

This comment has been minimized.

Show comment
Hide comment
@RagnarSvenssonKing

RagnarSvenssonKing May 11, 2017

Contributor

Ok, let's discuss this monday.

Contributor

RagnarSvenssonKing commented May 11, 2017

Ok, let's discuss this monday.

@RagnarSvenssonKing RagnarSvenssonKing added blocker and removed serious labels May 11, 2017

@RagnarSvenssonKing

This comment has been minimized.

Show comment
Hide comment
@RagnarSvenssonKing

RagnarSvenssonKing May 23, 2017

Contributor

Lowering to serious after discussion, let us know if a fix becomes more urgent.

Contributor

RagnarSvenssonKing commented May 23, 2017

Lowering to serious after discussion, let us know if a fix becomes more urgent.

@RagnarSvenssonKing RagnarSvenssonKing added serious and removed blocker labels May 23, 2017

@RagnarSvenssonKing RagnarSvenssonKing removed their assignment May 24, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment