-
Notifications
You must be signed in to change notification settings - Fork 1.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
FINERACT-1188: README and other files are not covered by Spotless #1396
Conversation
@ptuomola FYI: I even got the Eclipse launcher configuration fixed; when you import the project into your workspace it immediately starts a build. Bonus: the symbolic link to gradlew is also not necessary anymore (removed it). |
ed33901
to
a038227
Compare
@vidakovic looks like the integration tests are failing... did they work for you locally? |
@vidakovic unfortunately this has broken Eclipse for me again - we are back at not finding Gradle: Errors occurred during the build. If this works for you, are you setting up your Eclipse workspace based on the instructions in the README ie section "Instructions to run and debug in Eclipse IDE"? Or are you doing something else? |
@ptuomola I have non of the errors you describe. Just to show you below a couple of screenshots from my Eclipse workspace: ... the error log shows one error entry, but related to the language server plugin; I think not related to anything we do: ... and this is the console output from the build that immediately starts after importing the project: ... the package explorer view looks also clean (no error indicators): |
... (continued): I didn't run the integration tests locally (was a bit late already); what I did do is build the Docker image and run it; no problems there. I will checkout what happens with the integration tests; I see still no reason why they should fail. I was not aware of a specific Eclipse setup; will try to recreate your environment according to README instructions... maybe I find the issue like that. Will keep you posted. Update: @ptuomola concerning Eclipse: I know now what's going on... I didn't execute "./gradlew cleanEclipse eclipse", because this is actually not necessary. If you import the project like this: ... then everything works perfectly well. From what I see we could get rid of the Eclipse Gradle plugin; even the Open JPA launcher configuration is automatically included in the project without any additional "./gradlew cleanEclipse eclipse". Unless there is another reason for this? Please let me know... I'll update the README if we can drop it. |
Ok... one step ahead: finally have a candidate for the failing integration tests. I did an experiment with a locally running Fineract Docker container that had all database details setup correctly. I've disabled Carge in build.gradle temporarily and ran the tests again... voila it worked. I think what happens with Cargo: it doesn't find the deployable WAR file; it doesn't seem that Fineract is started with Cargo at all. |
a038227
to
5a5cf71
Compare
@ptuomola yup, it was the Cargo plugin. The problem was that for some reason it didn't detect the WAR file anymore... so I added a deployable section. Just ran the integration tests locally, no failures. Let's see how the Travis build goes to confirm. If it's successful would be great if you could have another look at this. Please let me know if my notes on Eclipse are OK for you; the "new" instructions are actually shorter than the current README and from what I see works at least as well as before. |
@vidakovic Ah I see - you're importing this as an Gradle project rather than Eclipse project. But if you do that, do you get any of the benefits of Eclipse - e.g. debugging, hot code replace, automatic incremental recompile etc? |
@ptuomola as far as I can see all the same |
@vidakovic cool - just tried this and yes, it seems to work equally well. So no issue from Eclipse perspective. But the build still seems to be failing? Think there's some problem with the deployment to Cargo:
|
@ptuomola this Cargo plugin is a gift that just keeps giving... let me see |
5a5cf71
to
65e67a3
Compare
Problem was the use of "." right after a variable in a Groovy string; fixed |
65e67a3
to
0bf3973
Compare
... of course there's something else... but it's something in the Travis configuration... all the tests etc. went through without a problem. Looking into this. |
0bf3973
to
4ac019f
Compare
4ac019f
to
e97d509
Compare
@ptuomola please see my replies; I removed the Eclipse Gradle plugin references and updated the README |
9ddd884
to
5864763
Compare
@ptuomola Spotless complains a format issue in README line 200, but when I run locally it doesn't. Any ideas? Cannot reproduce. Could this be coming from another commit upstream? Update: I've merged the upstream changes. The interesting part was only the new ActiveMQ section in the README... which had a forbidden space at the end of the title. |
51b1f38
to
54d4b54
Compare
@vorburger @ptuomola wow... please let's merge before something else happens upstream ;-) |
@vidakovic Whoa! Nice. I'll review ASAP, but 1 quick minor practical feedback already: If you change the usual merge drop-down (above) to the Rebase and merge which we typically prefer using (see https://github.com/apache/fineract#merge-strategy), you'll see that GitHub shows This branch cannot be rebased due to conflicts. That means we would HAVE to merge your 2 commits here with Create a merge commit, which is possible, but always a bit "ugly" and we try to avoid, or with Squash and merge and that creates weird author/ownership metadata (check out e.g. latest e57b7da). If you don't mind, just do a |
2. Import the fineract-provider project into your Eclipse workspace (File->Import->General->Existing Projects into Workspace, choose root directory fineract/fineract-provider) | ||
3. Do a clean build of the project in Eclipse (Project->Clean...) | ||
1. Import the fineract-provider project into your Eclipse workspace (File->Import->Gradle->Existing Gradle Project into Workspace, choose root directory fineract/fineract-provider) | ||
2. Do a clean build of the project in Eclipse (Project->Clean...) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@vidakovic thanks for this updae, @ptuomola FYI this is actually how I use it as well (without ./gradlew cleanEclipse eclipse
)
gradle clean bootRun''' | ||
|
||
project.ext.jerseyVersion = '1.19.4' | ||
ext['groovy.version'] = '3.0.6' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
FTR, the ext['groovy.version']
in fineract-provider/build.gradle
used to be 3.0.3, and this upgrades it to 3.0.6
. I'm sure that's perfectly fine, so more as a general comment, when we move things around like this, it's best to move "as is", and then make changes (upgrades, here) separately subsequently (or before, if required). I'm not suggesting that you change it here anymore, just commenting in general, for future refactorings (of build or code, same).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ok
apply plugin: "org.nosphere.apache.rat" | ||
apply plugin: 'rebel' | ||
apply plugin: 'com.github.hierynomus.license' | ||
apply plugin: 'war' | ||
apply plugin: 'org.springframework.boot' | ||
apply plugin: 'eclipse' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Right, we can ditch this.. makes sense, to me. Again, better separately in the future, but not suggesting to touch here anymore (sorry to keep being a pain about this).
eclipse | ||
{ | ||
project { | ||
buildCommand([ LaunchConfigHandle: "<project>/.externalToolBuilders/OpenJPA Enhance Builder.launch" ], 'org.eclipse.ui.externaltools.ExternalToolBuilder') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
so this gets entirely ditch, not just moved.. why? @ptuomola does this LGTY? (I have NOT pulled it myself yet, to actually test.)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
trimTrailingWhitespace() | ||
} | ||
|
||
if (plugins.hasPlugin('java')) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice!!
} | ||
} | ||
|
||
if (project.hasProperty("automatedBuild")) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This seems to be moving from another section? More out of curiosity, what is this for? /Cc @thesmallstar (FYI we are doing a massive "move", see FINERACT-1188 and FINERACT-1171 for more background)
@vorburger could you give me the instructions again to solve that issue you mentioned with the rebase? I tried the steps you suggested, but just get weird feedback on the console. E. g. should I do "git rebase develop" in the PR branch? My repos develop and the PR branch are already in sync. |
@@ -1 +0,0 @@ | |||
../gradlew |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
FTR: It took me a sec to understand that you are removing the symlink here.. doesn't work? But probably a good idea anyway, for Windoze consistency.. I noticed that currently on develop we have a fineract-provider/gradlew (symlink), but no fineract-provider/gradlew.bat - that would probably create confusion, so +1 to rm this.
do you want to share the git error message / feedback?
Yeah.
How do you mean? This PR makes it look like you are working on |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! I even pulled and "tested" it, and indeed, lo and behold, if I add a space at the end of a line in README.md and run ./gradlew spotlessCheck
, it chokes on it... works as advertised (i.e. implements FINERACT-1188 as described). I'll let @ptuomola review and Approve this as well. If any other committers are reading along here, feel free to Approve or Comment as well, of course.
If you can sort out the rebase
so this has no merge commit, it would be neat. I'll help you, if required.
@vorburger I think I get an idea what happened here with the rebase... I first tried to solve this in the browser, but somehow lost my changes... and then "fixed" the conflict by merging the PR branch into my vidakovic/fineract develop branch (which was suggested by Github... don't remember where I read)... and that lead to the current PR branch. So, I'll try to bring my develop branch again to the same level as upstream - without my additional conflict fix merge. And then your instructions should work. Will let you know here... thanks again. Update: sweet... that worked... learned again something useful! |
1a258ad
to
5a9e643
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Thanks for persevering with this.
I can merge this - unless someone else wants to review first?
Thanks again for the patience |
Description
This is a replacement for #1381 for FINERACT-1188
Checklist
Please make sure these boxes are checked before submitting your pull request - thanks!
Write the commit message as per https://github.com/apache/fineract/#pull-requests
Acknowledge that we will not review PRs that are not passing the build ("green") - it is your responsibility to get a proposed PR to pass the build, not primarily the project's maintainers.
Create/update unit or integration tests for verifying the changes made.
Follow coding conventions at https://cwiki.apache.org/confluence/display/FINERACT/Coding+Conventions.
Add required Swagger annotation and update API documentation at fineract-provider/src/main/resources/static/api-docs/apiLive.htm with details of any API changes
Submission is not a "code dump". (Large changes can be made "in repository" via a branch. Ask on the developer mailing list for guidance, if required.)