RUST: Newbie woes: Spinning-Square Demo Crashes ???

Chat about just about anything else
Forum rules
Do not post support questions here. Before you post read the forum rules. Topics in this forum are automatically closed 30 days after creation.
Locked
User avatar
Webtest
Level 4
Level 4
Posts: 375
Joined: Sun Feb 21, 2010 4:45 pm
Location: Carlisle, Pennsylvania, USA

RUST: Newbie woes: Spinning-Square Demo Crashes ???

Post by Webtest »

Esteemed Forum Participants and Lurkers:
I'm just beginning to investigate "Rust", with a reasonable level of success ... until now.

I found a 'simple' graphics program using Piston graphics engine and presents a red spinning square in a green window: Piston Developers/Piston-Tutorials

It builds, but when I try to run it, it crashes with:
  • thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: "GL context creation failed"', libcore/result.rs:945:5
    note: Run with `RUST_BACKTRACE=1` for a backtrace.
I've spent over 2 hours trying to google all over rust, GitHub, and elsewhere for a solution, or even how to get the 'BACKTRACE' to do anything, but I have had ZERO success. I'm out of time today, but next week when I get the chance I'll try the rust-beginners IRC. I have used a couple of other chat groups, but this will be my first for Rust.

Thank you for any and all comments, suggestions, and assistance.
Blessings in abundance,
Art in Carlisle, PA USA
Last edited by LockBot on Wed Dec 07, 2022 4:01 am, edited 1 time in total.
Reason: Topic automatically closed 30 days after creation. New replies are no longer allowed.
BOAT - a hole in the water that you pour money into
LINUX - a hole in your life that you pour TIME into

HP dx2400 Core 2 Duo 8 GB. Mint 13/15/17.x/18.x Mate <on LOCKED SD cards, and Kanguru USB drives> No Hard Drive / No SSD
User avatar
xenopeek
Level 25
Level 25
Posts: 29614
Joined: Wed Jul 06, 2011 3:58 am

Re: RUST: Newbie woes: Spinning-Square Demo Crashes ???

Post by xenopeek »

Build a debug target. Then run it as:
RUST_BACKTRACE=1 cargo run
Or to make RUST_BACKTRACE=1 the default for your current terminal session, run this once:
export RUST_BACKTRACE=1
Then as long as you keep the terminal open Rust will do the backtrace for any Rust commands started from this terminal that panic.
Image
Locked

Return to “Open Chat”