Skip to content

Conversation

@sodic
Copy link
Contributor

@sodic sodic commented Oct 10, 2025

No description provided.

@sodic sodic changed the base branch from main to update-ghc-to-902 October 10, 2025 16:04
@@ -1,5 +1,5 @@
name: strong-path
version: 1.1.4.0
version: 1.2.0.0
Copy link
Contributor Author

@sodic sodic Oct 29, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We're updating the lower bounds for some libraries, so this is a breaking change. We're dropping support for GHC 8.10.7, which was a big one.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This file is autogenerated.

@sodic sodic changed the base branch from update-ghc-to-902 to main October 29, 2025 09:54
package.yaml Outdated
- tasty-quickcheck >=0.10 && <0.11
- tasty-discover >=4.2 && <4.3
- hspec >=2.7 && <2.10
- hashable
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hashable is already covered in the library target.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok! What did we say about possibly wanting to be explicit about version numbers though? Not yet/here?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like the convention is to specify common dependencies in the top-level dependencies section. So that's what I did in the end.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh nice! Good to know.

@sodic sodic changed the title Update GHC to range from 9.4.5 to latest Support GHC range from 9.4.5 to 9.12.2 Oct 29, 2025
@sodic sodic changed the title Support GHC range from 9.4.5 to 9.12.2 Support GHC range from 9.0.2 to 9.12.2 Oct 29, 2025
# Also, make sure to adjust tested-with field in package.yaml so that it contains
# corresponding GHC version.
stack-resolver: lts-18.21
stack-resolver: lts-19.33
Copy link
Contributor Author

@sodic sodic Oct 29, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lower bound for testing, corresponds to GHC 9.0.2., three years old.

This ensures that there are no GHC versions that don't have an appropriate StrongPath version.

In other words, there's no "gap" in supported GHC versions. Whichever version of GHC you are using, there's a Strong Path version for you:

  • Up to 9.0.1 - Strong Path 1.1.4.0
  • After 9.0.2 - Strong path 1.2.0.0

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn't quite get the second part of the message (everything beyond first sentence), could you explain in simpler way?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The sentence was non-sensical due to edits, so no wonder you couldn't understand it.

Edited :)

package.yaml Outdated
Comment on lines 37 to 39
- filepath >=1.4 && <1.6
- template-haskell >=2.17 && <2.24
- hashable >=1.3 && < 1.6
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For all dependencies:

  • Lower bounds match GHC 9.0.2 (Stack's LTS 19.33). I matched only the first two digits, ignoring minors. That's how we've done it so far.
  • Upper bounds match GHC 9.12.2 (Stack's nightly-2025-10-29). I set the exclusive upper limit to the next breaking change version.

For example:

  • LTS 19.33 has the version of filepath set to 1.4.2.2
  • nighly-2025-10-29 says has a version of filepath set to 1.5.4.0
  • Strong path requires filepath >=1.4 && <1.6

I went through the breaking changes version of all libraries I bumped and didn't see antyhing that should affect us. CI tests should confirm this.

Previous discussion here: #53 (comment)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great! Would it make sense to document this, either here in package.yaml, or in README.md, for future updates?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I added it to the note in 6d63f23.

Copy link
Member

@Martinsos Martinsos left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@sodic looking good! I left some comments but nothing major, resolve them as you wish and merge when happy.

# Also, make sure to adjust tested-with field in package.yaml so that it contains
# corresponding GHC version.
stack-resolver: lts-18.21
stack-resolver: lts-19.33
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn't quite get the second part of the message (everything beyond first sentence), could you explain in simpler way?

package.yaml Outdated
Comment on lines 37 to 39
- filepath >=1.4 && <1.6
- template-haskell >=2.17 && <2.24
- hashable >=1.3 && < 1.6
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great! Would it make sense to document this, either here in package.yaml, or in README.md, for future updates?

package.yaml Outdated
- tasty-quickcheck >=0.10 && <0.11
- tasty-discover >=4.2 && <4.3
- hspec >=2.7 && <2.10
- hashable
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok! What did we say about possibly wanting to be explicit about version numbers though? Not yet/here?

Comment on lines 22 to 27
convertPosixPath :: FilePath -> Char -> FilePath -> FilePath
convertPosixPath rootReplacement separator posixFp =
case posixFp of
"" -> ""
'/' : rest -> rootReplacement ++ map convertSeparator rest
_ -> map convertSeparator posixFp
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
convertPosixPath :: FilePath -> Char -> FilePath -> FilePath
convertPosixPath rootReplacement separator posixFp =
case posixFp of
"" -> ""
'/' : rest -> rootReplacement ++ map convertSeparator rest
_ -> map convertSeparator posixFp
convertPosixFp :: FilePath -> Char -> FilePath -> FilePath
convertPosixFp newRoot newSeparator posixFp =
case posixFp of
"" -> error "Empty string is not a valid posix path."
'/' : restOfAbsPosixFp -> newRoot ++ map convertSeparator restOfAbsPosixFp
relPosixFp -> map convertSeparator relPosixFp
where convertSeparator c = if c == '/' then newSeparator else c
  1. Renaming to convertPosixFp -> Fp makes it aligned with how we name other functions. I was also tempted to name it more similar to posixToSystemFp and posixToWindowsFp, somethig like posixToSomeFp or posixToSpecificFp, but wasn't convinced enough.
  2. I renamed separator to conceptually bind it to rootReplacement, they are both replacements, so that shoudl be clear. I did also rename replacement to new in the process as I think it is at least equally clear but simpler.
  3. I named variables, including _, a bit richer, so it is clearer what the intention was.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good suggestions, I applied all of them.

@sodic sodic merged commit 02182c6 into main Oct 31, 2025
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants