Inlyne-Project / inlyne

Introducing Inlyne, a GPU powered yet browserless tool to help you quickly view markdown files in the blink of an eye.
MIT License
1.09k stars 27 forks source link

Crash when clicking on a web URL #373

Open FeignMan opened 2 weeks ago

FeignMan commented 2 weeks ago

While viewing a markdown file, clicking on a web URL caused the application to crash. Crash reports are attached.

crash_reports.zip

Note: The reports mention the host OS as Ubuntu 22.4.0, but it might be worth mentioning that it was in WSL2 on a Windows 10 machine.

CosmicHorrorDev commented 1 week ago

Fortunately it looks like that error was already relaxed from crashing to logging a message on the main branch

https://github.com/Inlyne-Project/inlyne/blob/6f9ac5ed1126364d187afe4bd3431ae72be36cc6/src/main.rs#L505-L507

but that doesn't resolve it failing to begin with of course. It looks like it's getting a 512 exit status from trying to run

$ gio open "https://gitlab-ncsa.ubisoft.org/motherbrain/client/neo-client-sdk/"

Running that locally works for me (as does opening links through inlyne, but apparently it's failing for you

CosmicHorrorDev commented 1 week ago

This looks relevant although our version of open should already include that PR

FeignMan commented 1 week ago

@CosmicHorrorDev "Running that locally works for me (as does opening links through inlyne, but apparently it's failing for you" - 512 is a DNS issue, and that makes total sense because I'm trying to reach a website hosted inside the company network. The DNS resolution needs to go through my VPN connection.

  1. You may try reproducing this issue by purposely using a URL which would cause a DNS error. DNS error or not, the application should never crash.
  2. My VPN was connected when I got this issue - does Inlyne not respect proxy environment variables (HTTP_PROXY, HTTPS_PROXY, NO_PROXY, etc)? That might be an additional issue here.
CosmicHorrorDev commented 1 week ago

1) is already resolved. For 2) I won't have spare time to dig into things anytime soon, but this is enough to reproduce the behavior you're seeing with inlyne

[package]
name = "repro"
version = "0.1.0"
edition = "2021"

[dependencies]
open = "=5.0.0"
fn main() {
    open::that("https://example.com").unwrap();
}