-
Notifications
You must be signed in to change notification settings - Fork 278
Problem attachments #920
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
Problem attachments #920
Conversation
60921c2 to
d0213c2
Compare
|
Nice!
|
I think the latter requires something in the spec then, since that is not really a nice case. But if the samples contain stuff the team should not see then it is not a sample imho. Since you ship real samples in the zip anyway, wouldn’t marking the samples as non sample solve this? |
|
|
I wonder what the others think about the zip? Adding a “all attachments” button if there is >1 that creates a zip is trivial so we could do it |
|
How many attachments do we normally expect a problem to have? I can see why you'd want a zip file if they are many but it's already such a button fest on that page. If it's just one or two or three normally I don't see much value for the zip button. |
|
@RagnarGrootKoerkamp what do you think? Do you often have more than say 3? |
|
Since Kattis provides individual download links, let's go with that. See e.g. https://open.kattis.com/problems/testscheduling. As said before, we can always provide zip files in the attachments directory if needed. |
|
So can this be merged in current form? |
|
If others agree yes |
| * @return \Symfony\Component\HttpFoundation\Response | ||
| * @throws \Doctrine\ORM\NonUniqueResultException | ||
| */ | ||
| public function attachmentAction(int $probId, int $attachmentId) |
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.
Is this just duplicated code with above? Can you dedup it somewhere?
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.
I will try this
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.
I gave it a try and removed even more duplicated code. Can you check if you agree with the approach?
d0213c2 to
48fa25f
Compare
| { | ||
| public function getDescription() : string | ||
| { | ||
| return ''; |
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.
nit: add a description
The problem package format has the notion of attachments.
During the BAPC preliminaries we got the question whether we supported this, which we didn't yet.
So I came up with a simple implementation.
Some screenshots:
Jury interface:

Team / public problemset page:
