Starting the worker on linux systems (NixOS) makes the worker start with unknown target, which breaks the vorpal builds as well.
On linux, the get_default_system function here returns ARCH: x86_64, OS: linux -> 'x86_64-linux', which is then passed to the get_package_system function here.
The get_package_system function contains let target = system.to_lowercase().replace("_", "-"); line here, which converts x86_64-linux to x86-64-linux, which doesn't match any of the PackageTargets.
This PR removes the let target = system.to_lowercase().replace("_", "-"); line since it is not needed, fixing the issue. Also adds tests for the PackageTarget.from_str function on the scheme/src/lib.rs file.
Starting the worker on linux systems (NixOS) makes the worker start with
unknown
target, which breaks the vorpal builds as well.On linux, the
get_default_system
function here returnsARCH: x86_64, OS: linux -> 'x86_64-linux'
, which is then passed to theget_package_system
function here.The
get_package_system
function containslet target = system.to_lowercase().replace("_", "-");
line here, which convertsx86_64-linux
tox86-64-linux
, which doesn't match any of thePackageTarget
s.This PR removes the
let target = system.to_lowercase().replace("_", "-");
line since it is not needed, fixing the issue. Also adds tests for thePackageTarget.from_str
function on thescheme/src/lib.rs
file.P.S.: Sorry for the late PR :sweat_smile: