GatorEducator / gatorgradle

:electric_plug: Gradle Plugin to Enable Running GatorGrader as a Gradle Task
https://gatoreducator.github.io/gatorgradle/
GNU General Public License v2.0
7 stars 7 forks source link

gradle build is hanging on specific Windows machines #59

Closed jjumadinova closed 2 years ago

jjumadinova commented 5 years ago

When students run gradle grade on certain Windows machines, the checking is getting stuck (hanging and not completing checks) at the ExecuteCommand --command "gradle build" line in the "gatorgrader.yml" file. Without this line in the "gatorgrader.yml" file, the gradle grade command is able to complete. This happened in two instances so far (others did not encounter this issue on the same repository), both Windows machines (configs attached), running Gradle 5.6 and Python 3.6.

windows_config1 windows_config2

Michionlion commented 5 years ago

What version of Docker is being used (e.g. Docker Desktop, Docker Toolbox)? Is it repeatable in those certain instances on specific hardware, and if so, can you run the following command, and then in the interactive terminal that appears, try to execute gradle grade again?

docker run -it --rm --name dockagator \
  -v "$(pwd)":/project \
  -v "dockagator":/root/.local/share \
  gatoreducator/dockagator /bin/bash
gkapfham commented 5 years ago

Thanks for asking these questions @Michionlion and thanks for raising the issue @jjumadinova!

@jjumadinova can you clarify whether this occurs when GatorGrader is run in a Docker container or if it is run when an individual has all of the programs installed locally on a laptop?

What happens when this individual runs gradle build in their terminal window?

Finally, is there a way that you can tag the individual in question so that we can ask them to try different commands and report back details? I think that this would help us to resolve the issue faster. Right now, I think that we need more information before we can diagnose the problem and decide if a fix is needed. @Michionlion can you think of anything else that we should be asking about?

jjumadinova commented 4 years ago

@Michionlion programs were being run on Docker Desktop. Replication across the exact same hardware is hard to do, all individuals with this issue were using slightly different machines but all are Windows OS machines using Docker Desktop. I am tagging @kailaniwoodard who was one of the students with this issue and she kindly agreed to assist in debugging.

gkapfham commented 4 years ago

Hello @kailaniwoodard thanks for agreeing to help us with the debugging of this issue. If you can reliably reproduce this problem, can you please explain all of the details about your setup (hardware and software, etc.) and then the specific of the assignment on which you were working, that would be very greatly appreciated! Thanks!

kailaniwoodard commented 4 years ago

You're welcome @gkapfham!

The problem occurs when calling the gradle grade command with any program. It hangs at the last check where it neither passes nor fails when trying to execute the gradle build command.

Terminal Output:

λ gradle grade
Starting a Gradle Daemon, 1 busy Daemon could not be reused, use --status for details

> Configure project :
Configured GatorGradle 0.4.4
![machine-specs](https://user-images.githubusercontent.com/54776489/67978029-8f36ce80-fbef-11e9-8ccc-decce156ee73.PNG)

> Task :grade
Updating GatorGrader...
Fetching origin
From https://github.com/GatorEducator/gatorgrader
   dd116b3..c89bb4d  documentation/new-features -> origin/documentation/new-features
Checking out to 'master'
Managing GatorGrader's Python dependencies...
Finished!

?  The reflection.md in writing has at least 3 of the 'code' tag
?  The reflection.md in writing has exactly 2 of the 'list' tag
?  The file AnalyzeText.java exists in the src/main\\java\\labsix directory
?  The AnalyzeText.java in src/main\\java\\labsix has at least 10 single-line Java comment(s)
?  The AnalyzeText.java in src/main\\java\\labsix has exactly 1 of the 'new Date()' fragment
?  The AnalyzeText.java in src/main\\java\\labsix has at least 1 of the '||' fragment
?  The AnalyzeText.java in src/main\\java\\labsix has at least 2 of the 'new Scanner' fragment
?  The reflection.md in writing has at least 300 word(s) in total
?  The AnalyzeText.java in src/main\\java\\labsix has at least 2 of the 'int' fragment
?  The AnalyzeText.java in src/main\\java\\labsix has at least 2 multiple-line Java comment(s)
?  The AnalyzeText.java in src/main\\java\\labsix has exactly 0 of the 'TODO' fragment
?  The AnalyzeText.java in src/main\\java\\labsix has at least 1 of the '.next' fragment
?  The AnalyzeText.java in src/main\\java\\labsix has at least 1 of the '.nextLine' fragment
?  The AnalyzeText.java in src/main\\java\\labsix has exactly 0 of the 'Add Your Name Here' fragment
?  The reflection.md in writing has exactly 0 of the 'Add Your Name Here' fragment
?  The AnalyzeText.java in src/main\\java\\labsix has at least 8 of the 'System.out.println' fragment ?  The AnalyzeText.java in src/main\\java\\labsix has at least 1 of the 'new File' fragment
?  The repository has at least 6 commit(s)
?  The AnalyzeText.java in src/main\\java\\labsix has at least 1 of the 'FileNotFoundException' fragment
?  The file reflection.md exists in the writing directory
?  The AnalyzeText.java in src/main\\java\\labsix has at least 1 of the 'if' fragment
?  The AnalyzeText.java in src/main\\java\\labsix has at least 2 of the 'while' fragment
?  The reflection.md in writing has exactly 1 of the 'code_block' tag
?  The AnalyzeText.java in src/main\\java\\labsix has exactly 1 of the 'import java.util.Date' fragment
?  The reflection.md in writing has exactly 6 of the 'heading' tag
?  The AnalyzeText.java in src/main\\java\\labsix has exactly 1 of the '@author' fragment
?  The AnalyzeText.java in src/main\\java\\labsix has at least 2 of the 'String' fragment
<-------------> 0% EXECUTING [3m 16s]s]
> :grade > Finished 27 / 28 checks  >  96% complete!

The process has run as long as 6 hours before timing out and once it does, it says that I failed the check in executing the gradle build command. This is particularly peculiar because my machine has no issues executing the gradle build command when manually typed into the terminal.

Below are the versions of Gradle and Python that I'm running:

------------------------------------------------------------
Gradle 5.6.2
------------------------------------------------------------

Build time:   2019-09-05 16:13:54 UTC
Revision:     55a5e53d855db8fc7b0e494412fc624051a8e781

Kotlin:       1.3.41
Groovy:       2.5.4
Ant:          Apache Ant(TM) version 1.9.14 compiled on March 12 2019
JVM:          1.8.0_221 (Oracle Corporation 25.221-b11)
OS:           Windows 10 10.0 amd64

Python 3.6.3

In addition to that, I've attached the hardware specs of my machine in a screenshot with this. Please let me know if you need anything else or have any further questions.

machine-specs

jjumadinova commented 4 years ago

Reference lab: https://github.com/allegheny-computer-science-100-01-f2019/lab06-starter Again, GatorGrader passes all checks on the same lab when run locally on the same machine but hangs on gradle build when run on docker. Same issue persists on all labs.

gkapfham commented 4 years ago

Hi @kailaniwoodard an @jjumadinova thanks for updating us about this issue. It is, in fact, possible that this is connected to GatorGrader's Python codebase and may not be related to the Gradle plugin. I'm going to ask @alexheinle to investigate this issue this week and see if we can determine a solution.

gkapfham commented 4 years ago

For reference, @alexheinle, here is the issue inside of the other repository:

https://github.com/GatorEducator/gatorgrader/issues/204

Michionlion commented 2 years ago

This was likely related to the bug fixed by 2874cb4be1cb35f34e7defaa8a885e2e24743a48; as this entire project is being deprecated in favor of GatorGrade, this issue either has already been fixed, or will not be.