Conversation
|
In general, I'm open to this change. But I would like to get some more feedback from
Also @soenkehahn any comments? |
|
@liskin Also, regarding the build failure, apparently the |
|
The build failure seems to be this: haskell/directory#44 (comment) |
|
@liskin |
|
@liskin I'm happy to merge this if you can address the following points:
|
1a29e70 to
f8dccaa
Compare
|
I pushed a workaround for the failing tests, but it's (unsuprisingly) a bit ugly. Maybe I should submit it to the yaml package instead. @snoyberg what do you think? |
|
I think it makes sense for yaml. |
|
Okay, I'll prepare a pull req there later this evening. :-) |
|
So, here you go: snoyberg/yaml#104 @sol But I guess we still want the workaround here as well, right? Anyway, I'll write the docs and changelog tomorrow. |
|
@liskin If we can fix this in I'm willing to accept that the exception behavior will be different with older versions of |
|
Okay, yaml 0.8.21.2 is on hackage so I dropped the ugly commit, added documentation, enhanced the changelog and added an entry for this. |
|
Finally, green build checks! :-) |
test/Hpack/ConfigSpec.hs
Outdated
| - A2 | ||
| |] | ||
| ) | ||
| (packageAuthor >>> (`shouldBe` ["A1", "A2"])) |
There was a problem hiding this comment.
This two things are united tested in the yaml library. I vote for removing them here.
There was a problem hiding this comment.
Oh, I considered it part of "hpack specification" and naturally wrote a hspec test for that. :-)
There was a problem hiding this comment.
I don't fully agree with @jbrains, but for completeness: http://blog.thecodewhisperer.com/permalink/integrated-tests-are-a-scam
There was a problem hiding this comment.
"Interesting" article. Too bad it offers no alternatives. Not having integration tests at all and just having it blow up in production is, in my humble opinion, not a better alternative. :-)
But I can agree that slow tests are really bad, but I think that's a technical problem, not a fundamental one. For a long time I wanted qemu to support superfast copy on write snapshots via forking (with readonly file/disk-backed storage, obviously) which I think could help a lot, but never had enough time/budget to implement that.
Anyway, I dropped the two tests.
|
|
||
| import Data.Yaml | ||
| import Data.Yaml hiding (decodeFile, decodeFileEither) | ||
| import Data.Yaml.Include |
| source-dirs: test | ||
| main: hlint.hs | ||
| dependencies: [hlint] | ||
| ``` |
CHANGELOG.md
Outdated
| All notable changes to this project will be documented in this file. | ||
|
|
||
| The format is based on [Keep a Changelog](http://keepachangelog.com/) | ||
| and this project adheres to [Haskell Package Versioning Policy](https://pvp.haskell.org/). |
There was a problem hiding this comment.
I agree with the PVP for my code. But the current version of the PVP also contains this wording:
Note that modifying imports or depending on a newer version of another package may cause extra orphan instances to be exported and thus force a major version change.
Some people interpret this as: In theory one of your dependencies (e.g. directory) could add an orphan instance at some point in the future, for that reason following the PVP means you have to specify upper bounds for all your dependencies.
Even though this reasoning is sound in theory, I'm still not going to do that. I simply don't have the bandwidth to deal with version bumps of all the dependencies of all my projects all the time. My experience is that upper bounds cause more pain than they help anything. In the rare case that things actually break, I rather invest my time to fix things.
| [#67](https://github.com/sol/hpack/issues/67) | ||
|
|
||
| [Unreleased]: https://github.com/sol/hpack/compare/0.16.0...HEAD | ||
| [0.16.0]: https://github.com/sol/hpack/compare/0.15.0...0.16.0 |
There was a problem hiding this comment.
I'm on the fence with the hyperlinks in the change log. I agree that it looks nice, but I may not have the bandwidth to keep up with doing it like this in the future. Let's keep it that way for now and see.
| ## [0.16.0] - 2017-01-11 | ||
| ### Added | ||
| - Warn when `name` is missing [#109](https://github.com/sol/hpack/issues/109) | ||
| - Support globs in `c-sources` |
There was a problem hiding this comment.
I think this change never made it into the README. Extra points if you can fix that ;)
There was a problem hiding this comment.
Basically we want this "Accepts glob patterns" comments, same to what we have for other fields
|
@liskin Hey, thanks for taking care of this and all the other issues that spawned from it. I think this is a pretty awesome change. If you can address my bikeshedding, it's good for merge. |
There seems to be little reason not to allow this. Security can hardly be argued here as cabal custom setups and template haskell are far more powerful in this regard. See the changes in `README.md` for examples of usage.
|
And now the Windows build blows up when building happy. That can't be my fault, can it? |
This should fix the remaining CI failures.
|
Pushed again, everything's green again. |
|
@liskin Thanks a lot! In general, my bandwidth is limited for medical reasons. I try to keep up with important stuff, but I'm grateful for any help. If you want to further help with things, then go ahead and bump the version. Also what is your Hackage account name? |
|
I'm |
There seems to be little reason not to allow this. Security can hardly be argued here as cabal custom setups and template haskell are far more powerful in this regard.
So anyway, here's an example of usage:
package.yaml:
hlint.yaml:
Also, due to how Data.Yaml works, this can be abused to provide entire libraries of snippets:
package.yaml:
lib.yaml: