Closed 0x53A closed 5 years ago
Hmm, interesting. I've got reports of issues in parallel builds and although, I wasn't able to reproduce consistently, I suspect it was because the stdout wasn't locked and sometimes a messages gets in between when sending a big JSON. I've tried to fix that in latest fable-compiler@next
. But in that case the error is something like "unexpected end of JSON input", which I don't see in your logs.
It's weird that you get non-consistent F# compilation errors. When compiling two F# projects in parallel with shared files sometimes Fable gets confused which project a file belongs to, but it shouldn't be your case because the second project is .js not F#.
The errors in the third log ("Error: Can't resolve 'cannon'", etc) shouldn't happen because fo Fable as they come from JS files. I know webpack has problems to locate modules from folders outside the directory where package.json
is (that's why now Fable caches sources from Nuget libraries in a .fable folder next to package.json). Not sure if that's your case as you have ./../Client.Worker/client.worker.js
.
But if you're using fable-splitter maybe this is relate to #1751 somehow. Anyways, I would try updating the Fable tools and see if the errors are still there: yarn add fable-compiler@next fable-splitter@latest fable-loader@latest
(note we use next
for Fable as fable-compiler 2.2 is still in beta, although I'll push the stable version soon).
Hope it helps!
Cannon etc are referenced from babylonjs itself (the js package, not my binding), and are just warnings. These are emitted from webpack and can be ignored.
Will try to update and post back, thank you.
I updated the packages locally and ran the build a few times without issues.
So let's see what our CI says over the next few days ...
Thank you!
When compiling two F# projects in parallel with shared files sometimes Fable gets confused which project a file belongs to, but it shouldn't be your case because the second project is .js not F#.
I DO share files between Client.fsproj and Client.Worker.fsproj. 14 shared files, only one file is unique to the worker.
client.worker.js
just references the main module from Client.Worker.fsproj:
import fsOnMessage from "./Module.fs";
console.log("[WORKER-JS] INIT");
self.onmessage = function (o) {
console.log("[WORKER-JS] received", o);
fsOnMessage(o);
}
with Module.fs
let workerAgent = MailboxProcessor.Start(fun inbox->
// ...
)
let private onMessage = fun (o:MessageEvent) ->
workerAgent.Post(o)
// https://github.com/fable-compiler/Fable/issues/1759
Fable.Core.JsInterop.exportDefault onMessage
(I could probably simplify this and eliminate the js file).
[...] Not sure if that's your case as you have ./../Client.Worker/client.worker.js
All files are below package.json
, but webpack.config.js
is next to Client.fsproj
.
Ok I got rid of client.worker.js
, now webpack directly references the fsproj, and I directly register the message handler:
main: resolve('./Client.fsproj'),
worker: resolve('./../Client.Worker/client.worker.fsproj')
Browser.console.log("[Worker] started")
self?onmessage <- fun (o:MessageEvent) ->
Browser.console.log("[Worker] received", o)
workerAgent.Post(o)
Not sure if that will help, but it shouldn't hurt
I got another random failure today morning:
This time it didn't find the reference from Client.fsproj
to Bindings/FlatPickr.fsproj
:
Also, after the update of the packages, hot-reload got much slower. It now does a dotnet restore with each incremental compilation.
Starting target 'BundleClientRelease'
C:\progress\gitlab-runner\builds\b62483ad\0\ProgressGroup\Projekte\ebos\ebosYC\src\Client> "C:\Program Files (x86)\Yarn\bin\yarn.cmd" webpack --config src/Client/webpack.config.js -p (In: false, Out: false, Err: false)
yarn run v1.12.3
$ C:\progress\gitlab-runner\builds\b62483ad\0\ProgressGroup\Projekte\ebos\ebosYC\node_modules\.bin\webpack --config src/Client/webpack.config.js -p
Bundling for production...
fable-compiler 2.2.0-beta-019
C:\progress\gitlab-runner\builds\b62483ad\0\ProgressGroup\Projekte\ebos\ebosYC\src\Client> dotnet restore Client.fsproj
Paket version 5.176.9
Paket version 5.176.9
The last restore is still up to date. Nothing left to do.
The last restore is still up to date. Nothing left to do.
Performance:
Performance:
- Runtime: 76 milliseconds
- Runtime: 87 milliseconds
Wiederherstellung in "41,44 ms" f�r "C:\progress\gitlab-runner\builds\b62483ad\0\ProgressGroup\Projekte\ebos\ebosYC\src\Bindings\Flatpickr\Flatpickr.fsproj" abgeschlossen.
Wiederherstellung in "41,44 ms" f�r "C:\progress\gitlab-runner\builds\b62483ad\0\ProgressGroup\Projekte\ebos\ebosYC\src\Client\Client.fsproj" abgeschlossen.
Wiederherstellung in "41,44 ms" f�r "C:\progress\gitlab-runner\builds\b62483ad\0\ProgressGroup\Projekte\ebos\ebosYC\src\Bindings\BabylonJS\BabylonJS.fsproj" abgeschlossen.
Parsing ./src/Client/Client.fsproj...
C:\progress\gitlab-runner\builds\b62483ad\0\ProgressGroup\Projekte\ebos\ebosYC\src\Client.Worker> dotnet restore client.worker.fsproj
Paket version 5.176.9
The last restore is still up to date. Nothing left to do.
Performance:
- Runtime: 74 milliseconds
Paket version 5.176.9
The last restore is still up to date. Nothing left to do.
Performance:
- Runtime: 75 milliseconds
Pakete f�r "C:\progress\gitlab-runner\builds\b62483ad\0\ProgressGroup\Projekte\ebos\ebosYC\src\Client.Worker\client.worker.fsproj" werden wiederhergestellt...
Wiederherstellung in "19,07 ms" f�r "C:\progress\gitlab-runner\builds\b62483ad\0\ProgressGroup\Projekte\ebos\ebosYC\src\Bindings\BabylonJS\BabylonJS.fsproj" abgeschlossen.
Die MSBuild-Datei "C:\progress\gitlab-runner\builds\b62483ad\0\ProgressGroup\Projekte\ebos\ebosYC\src\Client.Worker\obj\client.worker.fsproj.nuget.g.props" wird generiert.
Die MSBuild-Datei "C:\progress\gitlab-runner\builds\b62483ad\0\ProgressGroup\Projekte\ebos\ebosYC\src\Client.Worker\obj\client.worker.fsproj.nuget.g.targets" wird generiert.
Wiederherstellung in "484,34 ms" f�r "C:\progress\gitlab-runner\builds\b62483ad\0\ProgressGroup\Projekte\ebos\ebosYC\src\Client.Worker\client.worker.fsproj" abgeschlossen.
Parsing ./src/Client.Worker/client.worker.fsproj...
fable: Compiled src\Client\Client.fsproj
fable: Compiled src\Client.Worker\client.worker.fsproj
fable: Compiled src\Client.Worker\Module.fs
fable: Compiled src\Client\App.fs
fable: Compiled src\Shared\Domain\ElmishBridge.fs
fable: Compiled src\Shared\Worker\Common.fs
fable: Compiled src\Shared\FableRemoting.fs
fable: Compiled .fable\Fable.Elmish.2.0.3\cmd.fs
fable: Compiled .fable\Fable.Elmish.React.2.2.0\react.fs
fable: Compiled .fable\Fable.Elmish.Browser.2.1.0\navigation.fs
fable: Compiled .fable\Fable.Elmish.2.0.3\program.fs
fable: Compiled src\Client\Pages.fs
fable: Compiled src\Shared\Domain\3DModels.fs
fable: Compiled .fable\Elmish.Bridge.Client.2.0.1\Library.fs
fable: Compiled src\Client\Client.fs
fable: Compiled src\Shared\Domain\IFC.fs
fable: Compiled src\Shared\Domain\Transfer.fs
fable: Compiled .fable\Fable.Elmish.2.0.3\prelude.fs
fable: Compiled .fable\Fable.Elmish.React.2.2.0\common.fs
fable: Compiled .fable\Fable.Remoting.Client.4.5.6\Remoting.fs
fable: Compiled .fable\Fable.Elmish.Browser.2.1.0\parser.fs
You did not set any plugins, parser, or stringifier. Right now, PostCSS does nothing. Pick plugins for your case on https://www.postcss.parts/ and use them in postcss.config.js.
fable: Compiled src\Client\Replacements\System.Numerics.fs
fable: Compiled .fable\Thoth.Json.2.5.0\Encode.fs
fable: Compiled src\Shared\Domain\User.fs
fable: Compiled ..\..\a_DotNet40_Lib\R5dLib\RemotingContracts\RemotingContracts.ebosYC\WCFTransfer.fs
fable: Compiled src\Client\pages\Home.fs
fable: Compiled .fable\Fable.PowerPack.3.0.0\BrowserStorage.fs
fable: Compiled src\Client\views\Footer.fs
fable: Compiled src\Client\pages\GPA\GPAModel.fs
fable: Compiled .fable\Fable.PowerPack.3.0.0\Promise.fs
fable: Compiled src\Client\Utils.fs
fable: Compiled src\Client\pages\IFCViewer.fs
fable: Compiled src\Client\pages\Ebos3D.fs
fable: Compiled src\Client\views\Menu.fs
fable: Compiled src\Shared\Domain\CarouselState.fs
fable: Compiled .fable\Thoth.Json.2.5.0\Decode.fs
fable: Compiled .fable\Fable.Remoting.Client.4.5.6\Types.fs
fable: Compiled .fable\Fable.Remoting.Client.4.5.6\Proxy.fs
fable: Compiled .fable\Fable.SimpleJson.2.10.0\TypeInfo.Converter.fs
fable: Compiled .fable\Fable.Elmish.Browser.2.1.0\prelude.fs
fable: Compiled src\Client\pages\GPA\GPA.fs
fable: Compiled .fable\Fable.React.4.1.3\Fable.Helpers.Isomorphic.fs
fable: Compiled .fable\Fable.React.4.1.3\Fable.Helpers.React.fs
fable: Compiled src\Client\BabylonJS\SingleFileBabylonViewer.fs
fable: Compiled .fable\Fulma.1.1.0\Elements\Button.fs
fable: Compiled src\Client\views\BabylonOptions.fs
fable: Compiled src\Client\BabylonJS\IFCBabylonViewer.fs
fable: Compiled .fable\Fulma.1.1.0\Components\Navbar.fs
fable: Compiled .fable\Fulma.1.1.0\Common.fs
fable: Compiled .fable\Fable.SimpleJson.2.10.0\TypeInfo.fs
fable: Compiled .fable\Fable.Remoting.Client.4.5.6\Http.fs
fable: Compiled .fable\Fable.SimpleJson.2.10.0\SimpleJson.fs
fable: Compiled src\Client\Replacements\Stopwatch.fs
fable: Compiled src\Client\WorkerReference.fs
fable: Compiled src\Client\TypescriptComponents.fs
fable: Compiled src\Client\BabylonJS\Common.fs
fable: Compiled src\Client\pages\GPA\GPAControl.fs
fable: Compiled .fable\Fable.SimpleJson.2.10.0\Json.Converter.fs
fable: Compiled .fable\Fable.SimpleJson.2.10.0\Json.fs
fable: Compiled src\Client\BabylonJS\CarouselView3D.fs
fable: Compiled .fable\Fable.SimpleJson.2.10.0\TypeCheck.fs
fable: Compiled .fable\Fable.Parsimmon.3.2.0\Parsimmon.fs
fable: Compiled .fable\Fable.SimpleJson.2.10.0\Parser.fs
You did not set any plugins, parser, or stringifier. Right now, PostCSS does nothing. Pick plugins for your case on https://www.postcss.parts/ and use them in postcss.config.js.
fable: Compiled src\Client\pages\GPA\Timeline.fs
Hash: dae3c33a71c1b4b553a3
Version: webpack 4.25.1
Time: 76750ms
Built at: 2019-03-26 08:56:04
6 assets
Entrypoint main = main.dae3c33a71c1b4b553a3.ix.css main.b2a760d4732327b86e05.ix.js main.dae3c33a71c1b4b553a3.ix.css.map main.b2a760d4732327b86e05.ix.js.map
Entrypoint worker = worker.3215ed280fb02f03b2f8.ix.js worker.3215ed280fb02f03b2f8.ix.js.map
[/FrS] ./src/Shared/Domain/3DModels.fs 6.93 KiB {0} {1} [built]
[2fd2] ./.fable/fable-library.2.2.0-beta-019/String.js 16.5 KiB {0} {1} [built]
[5Qcp] ./src/Client/site.css 39 bytes {0} [built]
[5Uny] ./.fable/fable-library.2.2.0-beta-019/List.js 31.9 KiB {0} {1} [built]
[8ZKz] ./.fable/fable-library.2.2.0-beta-019/Option.js 3.18 KiB {0} {1} [built]
[9CN+] ./.fable/fable-library.2.2.0-beta-019/AsyncBuilder.js 7.53 KiB {0} {1} [built]
[BfOE] ./src/Shared/FableRemoting.fs + 4 modules 22.7 KiB {0} {1} [built]
| ./src/Shared/FableRemoting.fs 5.96 KiB [built]
| ./.fable/Fable.Remoting.Client.4.5.6/Remoting.fs 5.61 KiB [built]
| ./.fable/Fable.Remoting.Client.4.5.6/Types.fs 3.03 KiB [built]
| ./.fable/Fable.Remoting.Client.4.5.6/Proxy.fs 6.11 KiB [built]
| ./.fable/Fable.Remoting.Client.4.5.6/Http.fs 1.9 KiB [built]
[Hm3b] ./src/Client.Worker/client.worker.fsproj + 1 modules 8.19 KiB {1} [built]
| ./src/Client.Worker/client.worker.fsproj 28 bytes [built]
| ./src/Client.Worker/Module.fs 8.1 KiB [built]
[I/eN] ./.fable/fable-library.2.2.0-beta-019/Array.js 33.2 KiB {0} {1} [built]
[KfpW] ./src/Shared/Worker/Common.fs 1.41 KiB {0} {1} [built]
[LMsB] ./.fable/fable-library.2.2.0-beta-019/Types.js 7.56 KiB {0} {1} [built]
[OSQG] ./.fable/fable-library.2.2.0-beta-019/Seq.js 20.4 KiB {0} {1} [built]
[YBRt] ./.fable/fable-library.2.2.0-beta-019/MailboxProcessor.js 2.81 KiB {0} {1} [built]
[ZGE0] ./src/Client/Client.fsproj + 47 modules 548 KiB {0} [not cacheable] [built] [1 warning] [12 errors]
| ./src/Client/Client.fsproj 25 bytes [built]
| ./src/Client/App.fs 6.06 KiB [built]
| ./.fable/Fable.Elmish.2.0.3/cmd.fs 2.61 KiB [built]
| ./src/Client/Pages.fs 4.12 KiB [built]
| ./src/Shared/Domain/ElmishBridge.fs 1.26 KiB [built]
| ./.fable/Fable.Elmish.2.0.3/program.fs 5.56 KiB [built]
| ./.fable/Fable.Elmish.Browser.2.1.0/navigation.fs 4.8 KiB [built]
| ./.fable/Elmish.Bridge.Client.2.0.1/Library.fs 6.92 KiB [built]
| ./src/Client/Client.fs 26.7 KiB [built]
| ./.fable/Fable.Elmish.React.2.2.0/react.fs 2.57 KiB [built]
| ./src/Shared/Domain/User.fs 782 bytes [built]
| ./.fable/Thoth.Json.2.5.0/Decode.fs 55.2 KiB [built]
| ./.fable/Thoth.Json.2.5.0/Encode.fs 3.9 KiB [built]
| ./.fable/Fable.PowerPack.3.0.0/BrowserStorage.fs 1.41 KiB [built]
| ./.fable/Fable.PowerPack.3.0.0/Promise.fs 3.58 KiB [built]
| + 33 hidden modules
[jXvh] ./.fable/fable-library.2.2.0-beta-019/Util.js 20.6 KiB {0} {1} [built]
+ 356 hidden modules
WARNING in ./src/Client/BabylonJS/CarouselView3D.fs
Module Warning (from ./node_modules/fable-loader/index.js):
C:/progress/gitlab-runner/builds/b62483ad/0/ProgressGroup/Projekte/ebos/ebosYC/src/Client/BabylonJS/CarouselView3D.fs(1132,8): (1132,36) warning FABLE: Async.Start will behave as StartImmediate
@ ./src/Client/pages/GPA/GPA.fs 25:0-182 931:22-46 940:9-28
@ ./src/Client/Client.fs
@ ./src/Client/App.fs
@ ./src/Client/Client.fsproj
WARNING in ./node_modules/babylonjs/babylon.js
Module not found: Error: Can't resolve 'cannon' in 'C:\progress\gitlab-runner\builds\b62483ad\0\ProgressGroup\Projekte\ebos\ebosYC\node_modules\babylonjs'
@ ./node_modules/babylonjs/babylon.js
@ ./src/Client.Worker/Module.fs
@ ./src/Client.Worker/client.worker.fsproj
WARNING in ./node_modules/babylonjs/babylon.js
Module not found: Error: Can't resolve 'earcut' in 'C:\progress\gitlab-runner\builds\b62483ad\0\ProgressGroup\Projekte\ebos\ebosYC\node_modules\babylonjs'
@ ./node_modules/babylonjs/babylon.js
@ ./src/Client.Worker/Module.fs
@ ./src/Client.Worker/client.worker.fsproj
WARNING in ./node_modules/babylonjs/babylon.js
Module not found: Error: Can't resolve 'oimo' in 'C:\progress\gitlab-runner\builds\b62483ad\0\ProgressGroup\Projekte\ebos\ebosYC\node_modules\babylonjs'
@ ./node_modules/babylonjs/babylon.js
@ ./src/Client.Worker/Module.fs
@ ./src/Client.Worker/client.worker.fsproj
ERROR in ./src/Client/pages/GPA/GPAControl.fs
Module Error (from ./node_modules/fable-loader/index.js):
C:/progress/gitlab-runner/builds/b62483ad/0/ProgressGroup/Projekte/ebos/ebosYC/src/Client/pages/GPA/GPAControl.fs(118,32): (118,46) error FSHARP: The type 'FlatpickrReact' is not defined. (code 39)
@ ./src/Client/pages/GPA/GPA.fs 21:0-158 795:88-96 798:94-102 971:19-26
@ ./src/Client/Client.fs
@ ./src/Client/App.fs
@ ./src/Client/Client.fsproj
ERROR in ./src/Client/pages/GPA/GPAControl.fs
Module Error (from ./node_modules/fable-loader/index.js):
C:/progress/gitlab-runner/builds/b62483ad/0/ProgressGroup/Projekte/ebos/ebosYC/src/Client/pages/GPA/GPAControl.fs(154,19): (154,28) error FSHARP: The namespace or module 'FlatPickr' is not defined. (code 39)
@ ./src/Client/pages/GPA/GPA.fs 21:0-158 795:88-96 798:94-102 971:19-26
@ ./src/Client/Client.fs
@ ./src/Client/App.fs
@ ./src/Client/Client.fsproj
ERROR in ./src/Client/pages/GPA/GPAControl.fs
Module Error (from ./node_modules/fable-loader/index.js):
C:/progress/gitlab-runner/builds/b62483ad/0/ProgressGroup/Projekte/ebos/ebosYC/src/Client/pages/GPA/GPAControl.fs(155,8): (155,23) error FSHARP: Lookup on object of indeterminate type based on information prior to this program point. A type annotation may be needed prior to this program point to constrain the type of the object. This may allow the lookup to be resolved. (code 72)
@ ./src/Client/pages/GPA/GPA.fs 21:0-158 795:88-96 798:94-102 971:19-26
@ ./src/Client/Client.fs
@ ./src/Client/App.fs
@ ./src/Client/Client.fsproj
ERROR in ./src/Client/pages/GPA/GPAControl.fs
Module Error (from ./node_modules/fable-loader/index.js):
C:/progress/gitlab-runner/builds/b62483ad/0/ProgressGroup/Projekte/ebos/ebosYC/src/Client/pages/GPA/GPAControl.fs(156,8): (156,22) error FSHARP: Lookup on object of indeterminate type based on information prior to this program point. A type annotation may be needed prior to this program point to constrain the type of the object. This may allow the lookup to be resolved. (code 72)
@ ./src/Client/pages/GPA/GPA.fs 21:0-158 795:88-96 798:94-102 971:19-26
@ ./src/Client/Client.fs
@ ./src/Client/App.fs
@ ./src/Client/Client.fsproj
ERROR in ./src/Client/pages/GPA/GPAControl.fs
Module Error (from ./node_modules/fable-loader/index.js):
C:/progress/gitlab-runner/builds/b62483ad/0/ProgressGroup/Projekte/ebos/ebosYC/src/Client/pages/GPA/GPAControl.fs(157,8): (157,26) error FSHARP: Lookup on object of indeterminate type based on information prior to this program point. A type annotation may be needed prior to this program point to constrain the type of the object. This may allow the lookup to be resolved. (code 72)
@ ./src/Client/pages/GPA/GPA.fs 21:0-158 795:88-96 798:94-102 971:19-26
@ ./src/Client/Client.fs
@ ./src/Client/App.fs
@ ./src/Client/Client.fsproj
ERROR in ./src/Client/pages/GPA/GPAControl.fs
Module Error (from ./node_modules/fable-loader/index.js):
C:/progress/gitlab-runner/builds/b62483ad/0/ProgressGroup/Projekte/ebos/ebosYC/src/Client/pages/GPA/GPAControl.fs(160,16): (160,29) error FSHARP: The field, constructor or member 'OnValueUpdate' is not defined. (code 39)
@ ./src/Client/pages/GPA/GPA.fs 21:0-158 795:88-96 798:94-102 971:19-26
@ ./src/Client/Client.fs
@ ./src/Client/App.fs
@ ./src/Client/Client.fsproj
ERROR in ./src/Client/pages/GPA/GPAControl.fs
Module Error (from ./node_modules/fable-loader/index.js):
C:/progress/gitlab-runner/builds/b62483ad/0/ProgressGroup/Projekte/ebos/ebosYC/src/Client/pages/GPA/GPAControl.fs(165,16): (165,24) error FSHARP: The field, constructor or member 'OnChange' is not defined. (code 39)
@ ./src/Client/pages/GPA/GPA.fs 21:0-158 795:88-96 798:94-102 971:19-26
@ ./src/Client/Client.fs
@ ./src/Client/App.fs
@ ./src/Client/Client.fsproj
ERROR in ./src/Client/pages/GPA/GPAControl.fs
Module Error (from ./node_modules/fable-loader/index.js):
C:/progress/gitlab-runner/builds/b62483ad/0/ProgressGroup/Projekte/ebos/ebosYC/src/Client/pages/GPA/GPAControl.fs(170,16): (170,22) error FSHARP: The field, constructor or member 'OnOpen' is not defined. (code 39)
@ ./src/Client/pages/GPA/GPA.fs 21:0-158 795:88-96 798:94-102 971:19-26
@ ./src/Client/Client.fs
@ ./src/Client/App.fs
@ ./src/Client/Client.fsproj
ERROR in ./src/Client/pages/GPA/GPAControl.fs
Module Error (from ./node_modules/fable-loader/index.js):
C:/progress/gitlab-runner/builds/b62483ad/0/ProgressGroup/Projekte/ebos/ebosYC/src/Client/pages/GPA/GPAControl.fs(174,16): (174,23) error FSHARP: The field, constructor or member 'OnClose' is not defined. (code 39)
@ ./src/Client/pages/GPA/GPA.fs 21:0-158 795:88-96 798:94-102 971:19-26
@ ./src/Client/Client.fs
@ ./src/Client/App.fs
@ ./src/Client/Client.fsproj
ERROR in ./src/Client/pages/GPA/GPAControl.fs
Module Error (from ./node_modules/fable-loader/index.js):
C:/progress/gitlab-runner/builds/b62483ad/0/ProgressGroup/Projekte/ebos/ebosYC/src/Client/pages/GPA/GPAControl.fs(179,16): (179,21) error FSHARP: The field, constructor or member 'Value' is not defined. (code 39)
@ ./src/Client/pages/GPA/GPA.fs 21:0-158 795:88-96 798:94-102 971:19-26
@ ./src/Client/Client.fs
@ ./src/Client/App.fs
@ ./src/Client/Client.fsproj
ERROR in ./src/Client/pages/GPA/GPAControl.fs
Module Error (from ./node_modules/fable-loader/index.js):
C:/progress/gitlab-runner/builds/b62483ad/0/ProgressGroup/Projekte/ebos/ebosYC/src/Client/pages/GPA/GPAControl.fs(181,16): (181,23) error FSHARP: The field, constructor or member 'Options' is not defined. (code 39)
@ ./src/Client/pages/GPA/GPA.fs 21:0-158 795:88-96 798:94-102 971:19-26
@ ./src/Client/Client.fs
@ ./src/Client/App.fs
@ ./src/Client/Client.fsproj
ERROR in ./src/Client/pages/GPA/GPAControl.fs
Module Error (from ./node_modules/fable-loader/index.js):
C:/progress/gitlab-runner/builds/b62483ad/0/ProgressGroup/Projekte/ebos/ebosYC/src/Client/pages/GPA/GPAControl.fs(183,21): (183,35) error FSHARP: The value, constructor, namespace or type 'FlatpickrReact' is not defined. (code 39)
@ ./src/Client/pages/GPA/GPA.fs 21:0-158 795:88-96 798:94-102 971:19-26
@ ./src/Client/Client.fs
@ ./src/Client/App.fs
@ ./src/Client/Client.fsproj
Child mini-css-extract-plugin node_modules/css-loader/index.js!node_modules/flatpickr/dist/themes/material_blue.css:
Entrypoint mini-css-extract-plugin = *
2 modules
Child mini-css-extract-plugin node_modules/css-loader/index.js!node_modules/postcss-loader/src/index.js!node_modules/sass-loader/lib/loader.js!src/Client/bulma_ref.scss:
Entrypoint mini-css-extract-plugin = *
[o47n] ./node_modules/css-loader!./node_modules/postcss-loader/src!./node_modules/sass-loader/lib/loader.js!./src/Client/bulma_ref.scss 172 KiB {0} [built]
+ 1 hidden module
Child mini-css-extract-plugin node_modules/css-loader/index.js!node_modules/postcss-loader/src/index.js!node_modules/sass-loader/lib/loader.js!src/Client/site.scss:
Entrypoint mini-css-extract-plugin = *
[by+Z] ./node_modules/css-loader!./node_modules/postcss-loader/src!./node_modules/sass-loader/lib/loader.js!./src/Client/site.scss 1.43 KiB {0} [built]
+ 1 hidden module
Child mini-css-extract-plugin node_modules/css-loader/index.js!src/Client/site.css:
Entrypoint mini-css-extract-plugin = *
[hbf9] ./node_modules/css-loader!./src/Client/site.css 7.75 KiB {0} [built]
+ 1 hidden module
error Command failed with exit code 2.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
Finished (Failed) 'BundleClientRelease' in 00:01:22.4322406
---------------------------------------------------------------------
Build Time Report
---------------------------------------------------------------------
Target Duration
------ --------
Clean 00:00:00.0080881
RestoreClient 00:00:26.2189702
RestoreServer 00:00:15.4628846
RunClientTests_NetCore 00:00:23.4426252
RunClientTests_Fable 00:00:27.1498382
BundleClientRelease 00:01:22.4320468 ('C:\Program Files (x86)\Yarn\bin\yarn.cmd webpack --config src/Client/webpack.config.js -p' failed)
RunServerTests 00:00:00 (skipped)
BuildRelease 00:00:00 (skipped)
Total: 00:02:54.8085526
Status: Failure
---------------------------------------------------------------------
Oh well, the error rate is low enough that just restarting the failing builds is acceptable.
I'll try to create a reduced repro that I can post publically when I got some time (~2-3 weeks), until then, since I seem to be the only one with this issue, let's not waste too much time with blind remote-diagnostics.
Thanks @0x53A! Yes, unfortunately it's difficult to investigate these issues without a reproducible project because there are usually many factors into play.
It's weird that you get non-consistent F# compilation errors. When compiling two F# projects in parallel with shared files sometimes Fable gets confused which project a file belongs to, but it shouldn't be your case because the second project is .js not F#.
Hi @alfonsogarciacaro, we have a similar problem as @0x53A but with multiple F# projects being built. Your remark struck a chord. You're talking about files "linked" from another project right? Is there a way around this or to disable parallel compilation?
I don't have a standalone repo, and don't expect you to magically solve this issue, but do you have an idea what might be the issue, or can you give me a hint how to investigate?
I have a solution with a total of 5 Fable projects:
My webpack.config.js contains two entry points:
Every few builds I get errors that it can't find types from referenced projects. This occurs mostly on CI, but I've also seen it locally. Restarting the build fixes it most of the time.
I think this problem also existed before adding the second entry (worker), but I think it got much worse afterwards. Currently it fails maybe every third build.
At first I thought it was maybe because of parallel builds (CI server runs up to 3 builds in parallel), but I added a mutex to my Fake script to no avail.
It also shouldn't be a caching issue (unless Fable caches in %temp%), because gitlab-ci runs a
git clean
before each build.I just ran
paket update
andyarn upgrade --all
this morning, so everything should be up-to-date (no pre-release), and got a random failure with the next build after.Examples of the errors:
1) here it failed in tests/ClientTests. The things it mentions are defined in the Client project. The executor is fable-splitter.
2) here it also fails in tests/ClientTests, but this time it can't find the reference to babylonjs. The executor is fable-splitter.
3) here the tests executed successfully, and it failed in BundleClientRelease because it can't resolve the reference to babylonjs. The executor is fable-loader through webpack.
yarn.lock