Skip to content
This repository has been archived by the owner on Jan 15, 2025. It is now read-only.

bf luis:cross-train creates invalid config internally #998

Closed
tomlm opened this issue Sep 30, 2020 · 2 comments
Closed

bf luis:cross-train creates invalid config internally #998

tomlm opened this issue Sep 30, 2020 · 2 comments
Assignees

Comments

@tomlm
Copy link
Contributor

tomlm commented Sep 30, 2020

Versions

4.10.1

Describe the bug

The code which generates a config by inspecting the file system doesn't generate the same data structure that the library that consumes is expecting.
in

in confighelp.js line 87

          result[key].triggers[trigger.intent] = relativePath

in crosstrain.js line 38

const {rootIds, triggerRules, intentName, verbose} = crossTrainConfig

You will see that the confighelper is creating a property called "triggers" while the library is expecting "triggerRules"

THIS LIBRARY SHOULD HAVE BEEN TYPESCRIPT, this bug could have happened if the config had an interface definition. There is a reason typescript exists and THIS IS IT.

[bug]

@feich-ms
Copy link
Contributor

feich-ms commented Oct 9, 2020

I have a PR here #990 to refactor the interface of crosstrain core lib. After the optimizations, the config will be aligned between composer and cli.

@feich-ms
Copy link
Contributor

Closed by #1024, there is no config discovery and --config is required in cli now.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants