{% extends "devilry_detektor/admin/base.django.html" %} {% load i18n %} {% load url from future %} {% block breadcrumbtail %}
  • {% trans "Similarity checks" %}
  • {% endblock breadcrumbtail %} {% block belowheading %}

    {% trans "In this view, you can run similarity checks for all deliveries on this assignment. It only works for Java and Python code for now." %}

    This is a beta feature, please contact us via devilry.org if you encounter any problems, if you want to help (provide feedback, request or submit support for more languages, etc.)

    {% endblock belowheading %} {% block content %} {% if DEVILRY_ENABLE_CELERY %}
    {% if detektorassignment.status == "running" %}
    {% blocktrans with user=detektorassignment.processing_started_by.username email=detektorassignment.processing_started_by.email started_time=detektorassignment.processing_started_datetime %}Similarity check processing was started by {{ user }} {{ started_time }}. An email will be sent to {{ email }} when the task is completed.{% endblocktrans %}
    {% else %}
    {% csrf_token %}

    {% if detektorassignment.status == "finished" %}
    {% blocktrans with user=detektorassignment.processing_started_by started_time=detektorassignment.processing_started_datetime %}Similarity check processing was last run by {{ user }} {{ started_time }}. You can browse the results in the table below.{% endblocktrans %} {% trans "The points in the first column indicates how similar the programs are. The more points, the more similarities where found between the programs. The last column provides a summary of all the reasons why the programs are considered similar." %}
    {% endif %} {% if cachelanguages %}
    {% for comparetwo in comparetwo_cacheitems %} {% for parseresult in comparetwo.get_parseresults_as_tuple %} {% endfor %} {% endfor %}
    {% trans "Points" %} {% trans "Delivery 1" %} {% trans "Delivery 2" %} {% trans "Similarities" %}
    {{ comparetwo.scaled_points }}

    {% if parseresult.delivery.assignment_group.name %} {{ parseresult.delivery.assignment_group.name }}
    {% endif %} {% for candidate in parseresult.delivery.assignment_group.candidates.all %} {{ candidate.student.get_full_name }}{% if not forloop.last %}, {% endif %} {% endfor %}
    {% trans "delivery" %}#{{ parseresult.delivery.number }}

    {% trans "Show" %} {% trans "Download" %}

    {{ comparetwo.get_summary_descriptions_as_string }}
    {% endif %} {% endif %}
    {% else %}
    {% trans "This feature is disabled for your Devilry install." %}
    {% endif %} {% endblock content %}