Skip to content
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

ASP.NET fails to generate CSS files in Electronize /watch mode #844

Open
pawl0wski opened this issue Apr 18, 2024 · 0 comments
Open

ASP.NET fails to generate CSS files in Electronize /watch mode #844

pawl0wski opened this issue Apr 18, 2024 · 0 comments
Labels

Comments

@pawl0wski
Copy link

pawl0wski commented Apr 18, 2024

  • Version: Electronize: 23.6.2, .NET Core 8.0, Node.js v21.7.3
  • Target: linux

When I use /watch, ASP.NET doesn't generate CSS files from *.razor.css files. This also happens when I don't use /watch, but it's occasional.

During a regular electronize start, it seems to happen very randomly. Sometimes when I add a random line of code, it suddenly fixes itself.

First scenario. When i use electronize start /watch

image

image

Start Electron Desktop Application...
Arguments: 
	watch = 
node_modules missing in: /tmp/b/obj/Host/node_modules
Start npm install...
npm install
npm WARN deprecated tslint@6.1.3: TSLint has been deprecated in favor of ESLint. Please see https://github.com/palantir/tslint/issues/4534 for more information.

added 159 packages, and audited 160 packages in 4s

26 packages are looking for funding
  run `npm fund` for details

1 moderate severity vulnerability

To address all issues (including breaking changes), run:
  npm audit fix --force

Run `npm audit` for details.


ElectronHostHook handling started...
Invoke electron - in dir: /tmp/b/obj/Host/node_modules/.bin
./electron "../../main.js"  --watch=true
Electron Socket IO Port: 8000
Electron Socket started on port 8000 at ::1
ASP.NET Core Watch Port: 8001
stdout: dotnet watch 🔥 Hot reload enabled. For a list of supported edits, see https://aka.ms/dotnet/hot-reload.
  💡 Press "Ctrl + R" to restart.

stdout: dotnet watch 🔧 Building...

stdout:   Determining projects to restore...

stdout:   Restored /tmp/b/b.csproj (in 326 ms).

stdout:   b -> /tmp/b/bin/Debug/net8.0/b.dll

stdout: dotnet watch 🚀 Started

stdout: Use Electron Port: 8000

stdout: info: Microsoft.Hosting.Lifetime[14]
      Now listening on: http://localhost:8001

stdout: ASP.NET Core host has fully started.

stdout: info: Microsoft.Hosting.Lifetime[0]
      Application started. Press Ctrl+C to shut down.

stdout: info: Microsoft.Hosting.Lifetime[0]
      Hosting environment: Production
info: Microsoft.Hosting.Lifetime[0]
      Content root path: /tmp/b

ASP.NET Core Application connected... global.electronsocket Y7WWNO_O4GcYde1mAAAC 2024-04-18T23:05:00.263Z
stdout: BridgeConnector connected!

stdout: Called Event BrowserWindowCreated - data 1

[82604:0419/010501.271869:ERROR:cert_verify_proc_builtin.cc(677)] CertVerifyProcBuiltin for localhost failed:
----- Certificate i=0 (CN=localhost) -----
ERROR: No matching issuer found


[82639:0419/010501.272261:ERROR:ssl_client_socket_impl.cc(985)] handshake failed; returned -1, SSL error code 1, net_error -202

Second scenario. When i create new / move razor file.

image
image

It's very difficult to reproduce this on a new project because it happens 'randomly'. I've simulated how it looks in my main project. Basically, ASP.NET seems to not recognize the .css file when I run electronize start. However, if I open the project using dotnet run, the CSS is loaded.

If I gather more information about the second issue, I will edit it immediately.

Steps to Reproduce first scenario:

  1. Create new Blazor project dotnet new blazor
  2. Electronize it
  3. Run electronize start /watch
@pawl0wski pawl0wski added the bug label Apr 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant