Skip to content
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

Evaluation plugin #57

Closed
wants to merge 25 commits into from
Closed

Conversation

tatianacv
Copy link
Member

@tatianacv tatianacv commented Sep 13, 2022

In reference to #31

Copy link
Member

@khatchad khatchad left a comment

Choose a reason for hiding this comment

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

Lots of stuff here not seeming to do with the evaluation plug-in. Also, uploading JARs is not really necessary if we are using Maven. Eclipse may even have its own dependencies for some of these.

@@ -0,0 +1,3 @@
eclipse.preferences.version=1
Copy link
Member

Choose a reason for hiding this comment

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

Mylyn no longer exists in Eclipse. So, we're not going to need this.

@@ -0,0 +1,3 @@
# Properties file for edu.cuny.hunter.hybridize.ui
Bundle-Vendor = Hunter College, City University of New York
Copy link
Member

Choose a reason for hiding this comment

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

Since you are doing this one, it's coming from the GC (not Hunter).

while (parentNode instanceof ClassDef || parentNode instanceof FunctionDef) {

if (parentNode instanceof ClassDef)
isMethod = true;
Copy link
Member

Choose a reason for hiding this comment

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

It still may not be a method.

@@ -283,6 +283,10 @@ public boolean hasReduceRetracingParam() {
*/
private IPythonNature nature;

private boolean isMethod;

private boolean isEmbedded;
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 incorporate these into #263. Feel free to open a new PR if needed.

// Counters for aggregate information
int countfunctionsPerNode = 0;
int countHybridPerProject = 0;
int slocTotal = 0;
Copy link
Member

Choose a reason for hiding this comment

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

We don't need this count in this plug-in. AFAIK, the metrics plug-in used to get the Java count doesn't work for Python, and I doubt there is a comparable Eclipse plug-in for Python. We can use something like sloccount instead. It ignores comments. It can be used later, not while the plug-in is running, and it doesn't need to be integrated. The metrics plug-in is nice, but I think it only works for Java.

countfunctionsPerNode++;
}
if (document != null)
slocTotal += document.getNumberOfLines();;
Copy link
Member

Choose a reason for hiding this comment

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

Sounds like LOC not SLOC.

resultsPrinter.print(slocTotal);

// Printing number of classes per project
resultsPrinter.print(classesTotal.size());
Copy link
Member

Choose a reason for hiding this comment

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

I also didn't include this in #263.

@@ -25,7 +25,7 @@ private static IFile getActualFile(PythonNode pythonNode) {
return pythonFile.getActualObject();
}

static IDocument getDocument(PythonNode pythonNode) throws CoreException, IOException {
public static IDocument getDocument(PythonNode pythonNode) throws CoreException, IOException {
Copy link
Member

Choose a reason for hiding this comment

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

These were moved to the core plug-in in #263.

@khatchad
Copy link
Member

khatchad commented Oct 6, 2023

Superseded by #263.

@khatchad khatchad closed this Oct 6, 2023
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.

2 participants