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

fix: Vs Code debugger does not use https protocol when starting dev server #1440

Open
Tusshu opened this issue Jul 5, 2024 · 2 comments
Open
Labels
bug Something isn't working as expected

Comments

@Tusshu
Copy link

Tusshu commented Jul 5, 2024

Description

  1. Created security context for method serve(handler, ip, port, securityContext: securityContext) as listed in the documentation.
  2. Ran the dev server using Dart Frog: Start and Debug Development server option in the Command Pallet of VS code.
  3. Specified port as 8443 when asked "which port number server should start on"
  4. Specified 8181 when asked "Which port number the Dart VM server should listen"
  5. Browser opens up and shows http://localhost:8443/ in the URL window and following message:
    6 This site can’t be reached. The webpage at https://localhost:8443/ might be temporarily down or it may have moved permanently to a new web address. ERR_FAILED

Expected Behavior

  1. Response returned in index.dart page is expected to be displayed.
  2. https protocol to be shown in URL when security context used in the serve() call in run() method.
@Tusshu Tusshu added the bug Something isn't working as expected label Jul 5, 2024
@alestiago
Copy link
Contributor

alestiago commented Jul 9, 2024

@Tusshu thanks for opening an issue!

I haven't tried to reproduce, but as far as I believe what you're stating is a valid request. The browser should open with https when a security context is specified. I believe there is no logic in place in the VS Code extension to cater for such use-case right now.

As far as I am concerned, the Dart Frog Daemon doesn't report the information on whether or not the Dart Frog project is using a Security Context or not. Hence, to land this change we would have to:

  • Update the Daemon to report if a Security Context is being specified
  • Update the VS Code extension to check with the Daemon if the current Dart Frog project is using a Security Context and open with HTTPS accordingly

I'm not sure if the team has bandwidth to prioritise this work right now (cc: @tomarra ), however, if you're interested in contributing to this effort we can definitely help you review and land the Pull Request.

@Tusshu
Copy link
Author

Tusshu commented Jul 10, 2024 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working as expected
Projects
Status: Needs Triage
Development

No branches or pull requests

2 participants