Closed MariusVolkhart closed 6 months ago
@MariusVolkhart can you have a look at the failing tests? I believe they need to be adjusted to fit the improved code style?
I don't know what to make of these test failures. The lines they point to are comments, and the error message they give isn't helping me - Collectors
is definitely imported. test
target runs locally, and I know "CI don't lie 😃 )", but this one is new for me 😅
That's really weird, it compiles locally here as well.
@marcospereira could this be an issue with the CI caching introduced recently?
@marcospereira could this be an issue with the CI caching introduced recently?
It is possible since jte build publishes artifacts locally, and I guess those are being included in the cache. I will do some investigation tomorrow, but a way to validate if the caches are screwing the builds here is to delete all of them (using gh cli), and trigger a new build manually (for this pr).
I'm unsure if cache was the culprit here, or if this was just a CI fluke. Still, I created #316 since it would be good hygiene.
@casid, can you trigger another build, and if it fails, delete the caches, and trigger another one? It would at least give us some confirmation if the failure is related to caching artifacts.
@marcospereira I re-ran the ubuntu build yesterday and it still failed. https://github.com/casid/jte/actions/runs/7470236001/job/20359418271?pr=310
will try to figure out how to clear the cache.
will try to figure out how to clear the cache.
I made a comment about it in #316. If you have GH CLI installed, you only need to run gh cache delete --repo casid/jte --all
.
Thanks! I just cleared the cache via gh cli and reran the tests this morning, but the problem remains (https://github.com/casid/jte/actions/runs/7470236001/job/20372467503?pr=310). So this is not a cache problem.
There is a mismatch between your branch and the PR changes. A possible fix is to amend your last commit, force push, and see if this fixes the issue:
git commit --amend --no-edit
git push --force-with-lease
🤞🏼
test
target runs locally, and I know "CI don't lie 😃 )", but this one is new for me 😅
We got tricked by this. CI is not running test
target, but instead install
. I was able to reproduce the issue locally after checking out your branch, and running the same command CI runs:
gh pr checkout 310
./mvnw clean install --file pom.xml
The lines they point to are comments, and the error message they give isn't helping me - Collectors is definitely imported
Well, it is not. 🙈
This is the main branch right now:
And your PR IS NOT adding an import for Collectors
:
See? No imports there! 👆🏼
Now, here is the WTH part of this. When I navigate to your branch, the import is there:
Permalink:
I guess that you run into some weird sync issues between your branch and the PR state? Maybe something related to this:
Okay, I got what is happening now.
This is where the import for Collectors
was removed: https://github.com/casid/jte/pull/311.
But your branch is not up to date with that change. You need to rebase it on top of casid/jte
main branch, solve the issues in the code, and then push-force here.
@casid, it may be a good idea to enable this configuration:
It will be clear when the PR branch is outdated, and help to fix confusions like this.
Thanks for the investigation @marcospereira!
@casid, it may be a good idea to enable this configuration:
It will be clear when the PR branch is outdated, and help to fix confusions like this.
This setting makes a lot of sense, I've enabled it and will give the button a try :-).
This setting makes a lot of sense, I've enabled it and will give the button a try :-).
Thanks!
So, the build is still failing because, now that the branch is rebased on top of the main, it does not include the import, and it should be failing locally the same way CI fails (since the Collectors
import is missing everywhere now).
Hey @casid @MariusVolkhart,
I would love to see a new release containing https://github.com/casid/jte/pull/319, and I think the changes here can be part of it since this PR is virtually done.
@MariusVolkhart, if you don't have the time, I can create a separate pull request with your commits (keeping proper attribution, of course) and fix the small issue blocking progress here.
Let me know if you are okay with that.
@marcospereira Awesome! Thanks for the investigation! Like I said, CI don't lie 😛
And thanks for the bump on this. Looking at it now.
All modified and coverable lines are covered by tests :white_check_mark:
Comparison is base (
d4f82bf
) 91.23% compared to head (3aa393e
) 91.23%.
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
Thank you guys! :-)
Thanks, @MariusVolkhart!
@casid, it would be great to have a 3.1.7 release if you have the time. :-)
@marcospereira I just published 3.1.7 to maven central.
Thanks, @casid!
I tried it and... there is a bug in the model extension.
The change here:
It should use template.fullyQualifiedClassName()
as it was before because you can have a template in a subfolder that will then generate a subpackage that is not added to the imports (which I think is the right thing to do).
I'm working on a quick fix and how to test for that.
Also, the changes in #310 are actually adding a number of unused imports in the model-extension facades. 🤔
/cc @MariusVolkhart.
Quickly documenting my findings. :-)
There is no Gradle test that combines:
I'm working on a quick fix and how to test for that.
:( I’m sorry for that. Breaking things and adding more work for the maintainers. @marcospereira thanks for fixing it and adding new tests.
@MariusVolkhart no worries! We have a saying in German, which goes like "those who do nothing, break nothing". I'm really proud that the detection and fix went so quickly and smooth. It's an incredible little community in this project.
We have a saying in German, which goes like "those who do nothing, break nothing".
Love this. Making and problems go together. It is how you react that matters. Keep the PRs coming, @MariusVolkhart.
It's an incredible little community in this project.
It is a small community, but the experience of contributing here is very welcoming. Thanks for always been so responsive, @casid.