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

Feature request: generate html as result #1934

Open
davbeek opened this issue Aug 25, 2024 · 7 comments
Open

Feature request: generate html as result #1934

davbeek opened this issue Aug 25, 2024 · 7 comments
Labels
enhancement Issue/PR that involves features, improvements and other changes minor Minor issue/feature/contribution/change report-viewer PR / Issue deals (partly) with the report viewer and thus involves web-dev technologies

Comments

@davbeek
Copy link

davbeek commented Aug 25, 2024

Would it be possible to generate an html file, perhaps via an option, including somehow all json file information, CSS and Javascript, so that the html file itself can be opened and viewed without the use of a separate viewer? If possible, it would improve the end user experience, eleminate any compatibility problems beween generated results and viewer, and it would make it possible to send the html file to an examination committee for inspection in the case of fraud.

@tsaglam tsaglam added the question A question, so neither a bug nor a enhancement proposal. label Aug 29, 2024
@tsaglam
Copy link
Member

tsaglam commented Aug 29, 2024

@davbeek we moved away from the legacy HTML report on purpose. However, the separate views in a report are printable. This means you can export the overview, and also the comparison views you want to share via print > save as pdf. Of course, you need to do that for all views you want to share. If you want to share the whole report, then you need to send the zip file and use a viewer. There are currently no plans to go back to a pure HTML version.

The version issue will be resolved with the next release, where we move away from the hosted report viewer. Instead, JPlag will launch the web report locally. You can test this even in the latest released version with the --mode option, e.g. --mode RUN_AND_VIEW.

@davbeek
Copy link
Author

davbeek commented Aug 30, 2024

Thank you for your comments. I did have a look at the print functionality but did not see how it could be of any help. When you want to compare sections for plagiarism, you need the sections to line up. What I do in the viewer, is click on the section so that it lines up with the original, take a screenshot, paste it in the document for the exam committee and repeat this for all relevant plagiarised sections.

I also looked at the --mode RUN_AND_VIEW option, but got a "Failed to open page" error in Safari on my MacBook:
image

On Windows, I get a similar error for localhost: 1996: "The connection was reset" with a Try Again button that shows the same page.

I like the decision to separate the viewer from the analyser. I only thought that it would perhaps be possible to have an option to integrate the viewer in html, but I can understand that could be far from trivial.

Launching the viewer locally is definitely a big improvement, but I do not see how it would solve the version issue. If I have results from last year from a previous JPLAG version and the interface with the viewer changes, then I would not be able to view the old results with the new JPLAG version, or am I missing something?

Finally, it would help if the resulting files would have a special file extension, such as .jplg instead of .zip, so that executing (by double click or Open file) the file would automatically launch the viewer.

@tsaglam tsaglam added enhancement Issue/PR that involves features, improvements and other changes minor Minor issue/feature/contribution/change report-viewer PR / Issue deals (partly) with the report viewer and thus involves web-dev technologies and removed question A question, so neither a bug nor a enhancement proposal. labels Sep 2, 2024
@tsaglam
Copy link
Member

tsaglam commented Sep 2, 2024

Thanks for your feedback!

  • Regarding your issues with the local mode: Which version of JPlag did you use? I just tested it with the release 5.1.0 under Sonoma, works for me with Safari and Firefox. If we can reproduce the issue we will fix it.
  • Regarding version compatibility: Yes, you are right. If you are using old reports from an older major version, it might not fully work. In this case, you need the appropriate version of JPlag. However, this is only the case when we change the report format significantly between major versions. For the upcoming v6.0.0 release, this will be the case, as we are fixing some issues in the old format and making it more flexible. For pre-v6.0.0, where local mode was not default, we will still keep a hosted viewer. Finally, we currently do not expect breaking format changes between every major release, we aim to achieve stability as far as possible.
  • Regarding version issues: With increasing versions, it became more and more problematic for us to support opening any report version with the viewer, leading to a lot of added complexity. With the local mode changes, users do not need to rely on our hosted viewer and its ability to support older versions. They can just use the corresponding (older) version of JPlag to open it. A newer version will tell you when a report file is not supported and what version of JPlag supports it.

@davbeek
Copy link
Author

davbeek commented Sep 2, 2024

  • We use 5.1.0 extended by @Alberth289346 with our own language module, so I don't know if that extension could have anything to do with it. I do know that @Alberth289346 is currently very busy, as am I, so perhaps we can wait until version 6.0.0 and see how that goes. The fact that --mode RUN_AND_VIEW doesn't work for us doesn't bother me, as I simply use the JPlag online viewer.
  • Indeed, keeping an old version of JPlag for viewing old results would work.

@Kr0nox
Copy link
Member

Kr0nox commented Sep 12, 2024

@davbeek @Alberth289346 Is it possible that the jar is build without the report viewer?
The correct command for building the jar with the report viewer included is:
mvn -Pwith-report-viewer clean package assembly:single

@Alberth289346
Copy link
Contributor

@davbeek @Alberth289346 Is it possible that the jar is build without the report viewer? The correct command for building the jar with the report viewer included is: mvn -Pwith-report-viewer clean package assembly:single

It's built without report viewer.

I never found that 3rd option listed under "building from source". It got hidden in the wall of text of that 2nd point since I never realized I needed to (or even could) build a report viewer as well.

@tsaglam
Copy link
Member

tsaglam commented Sep 13, 2024

@Alberth289346 With the current release, this is more of a beta feature, and by default is that the local viewer will not be launched. That's why it is currently less strongly promoted and was easy to overlook. With the upcoming release, the local viewer will be the main way to do it. We are still working on updating the documentation for this (upcoming) release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Issue/PR that involves features, improvements and other changes minor Minor issue/feature/contribution/change report-viewer PR / Issue deals (partly) with the report viewer and thus involves web-dev technologies
Projects
None yet
Development

No branches or pull requests

4 participants