After adding this in the dependency for cargo.toml file piston_window = "*"
and I ran this in the console cargo build I get this error.
Updating registry `https://github.com/rust-lang/crates.io-index`
Downloading piston_window v0.105.0
error: unable to get packages from source
Caused by:
[35] SSL connect error (schannel: next InitializeSecurityContext failed: Unknown error (0x80092013) - The revocation function was unable to check revocation because the revocation server was offline.)
The error isn't your fault: Someone has a server that cargo uses to verify the security of your connection, but that server was down. It will likely disappear on its own later.
Thanks for the report! This is a transient error that sometimes shows up on Windows. You can set http.check-revoke = false in config (or CARGO_HTTP_CHECK_REVOKE=false in env) to ignore the error as well.
Which config file or env file is this person referring to?
Did you check if you still have the problem? The server may not still be down.
That said, I would recommend setting it temporarily by running the SET command in your console before running the cargo command. This way you don't disable the security features forever.
If you do want to set the property permanently, it should go in system variables together with Path, and the name should be CARGO_HTTP_CHECK_REVOKE while the value should be false.
When you set it there should be some other field in the dialog where you can put the value. I don't use windows myself, so I can't give a screenshot. Try looking up how to change path, since it should be the same process.
Note that you will likely have to restart the terminal you ran the command from to make it notice the change. You may even need to log out and back in. Again, I don't know the exact details.
There is literally no other field to put additional information in.
All good.
I have rebooted my entire PC. Issues are still the same.
SET CARGO_HTTP_CHECK_REVOKE=false I ran this command on cmd with no errors, but same problem when I run cargo build, same issue.
I have tried to do this on GNU/Linux on my VM and it works perfectly fine so it is not a server issue at all, I don't know why on Windows I am having such issues.
Ok so I went to the %userprofile%\.cargo directory and I added a file inside that directory called config. Inside that file I have added these lines.
[http]
check-revoke = false
So now when I run cargo build it seems to be now connecting but then I get this new error.
Downloading piston_window v0.105.0
Downloading gfx_device_gl v0.16.2
Downloading pistoncore-glutin_window v0.63.0
Downloading shader_version v0.6.0
Downloading piston2d-graphics v0.35.0
Downloading piston2d-gfx_graphics v0.66.0
Downloading piston v0.49.0
Downloading gfx v0.18.2
Downloading piston-texture v0.8.0
Downloading log v0.4.8
Downloading gfx_gl v0.6.0
Downloading gfx_core v0.9.2
Downloading cfg-if v0.1.10
error: unable to get packages from source
Caused by:
failed to parse manifest at `C:\Users\Joe\.cargo\registry\src\github.com-1ecc6299db9ec823\cfg-if-0.1.10\Cargo.toml`
Caused by:
editions are unstable
Caused by:
feature `edition` is required
this Cargo does not support nightly features, but if you
switch to nightly channel you can add
`cargo-features = ["edition"]` to enable this feature
I don't want to switch to cargo nightly. Is there another way around this situation?
By the way, it's entirely possible the you can revert the config changes after update. If this is really the case, I'd try to bisect the problem (i.e. find the first version that works) and check if there is an issue on Rust repo, but if you don't want to do this, the check should be enabled when possible.