Projects without security mirrors can result in errors being raised when obtaining security paths
In ReleaseTools::BaseProject.extract_path_from_remotes
we raise if a remote name can't be found. This creates a problem: when using to_s
, security_path
, or methods that call these methods, an error is raised during a security release. For example:
release-tools $ env FEATURE_INSTANCE_URL='hunter2' FEATURE_INSTANCE_ID='hunter2' bundle exec pry --gem
[1] pry(main)> ReleaseTools::SharedStatus.as_security_release { ReleaseTools::Project::HelmGitlab.to_s }
RuntimeError: Invalid remote for gitlab-org/charts/gitlab: security
from /home/yorickpeterse/Projects/gitlab/release-tools/lib/release_tools/project/base_project.rb:88:in `block in extract_path_from_remote'
I think we need a way of falling back to the public project path if a security path can't be found.
Edited by Yorick Peterse