Ok I added those test cases and made a new package release now. Please be aware that if you just use # in a path in the browser URL bar, without encoding it, the browser will treat this as a URL hash, not as part of the filepath.
eg. foo/bar#baz.txt will end up as foo/bar only.