bazelbuild / bazelbuild/bazel-skylib

`paths.relativize()` does not handle the case where `path == start`

Open
#616 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Starlark
Stars
444
Forks
202
PR merge metrics
No merged PRs in 30d

Description

`paths.relativize("/foo/bar/baz", "/foo/bar/baz")` returns `"/foo/bar/baz"` when I would naively expect it to return an empty string.

Contributor guide

Open the contributing guide

Research direction

Locate paths.relativize() in the skylib source and inspect any existing tests for path utilities. Reproduce the equal-path example, then add coverage for the expected empty-string result and run the relevant test target.

Written by the indexing model from the issue text.

Assessment

Domain
build-system
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
55/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.