codeeu / coding-events

A Django app for adding EU Code Week events and showing them on a map.
http://events.codeweek.eu
MIT License
17 stars 36 forks source link

Modifying pyploma.py in order to take the year of the event from command line. #446

Open misshu93 opened 7 years ago

mitio commented 7 years ago

@misshu93 thanks for the suggested contribution!

Can you explain in a bit more detail what are you changing and why?

The current way you're proposing the change will break the automatic certificate generation and we can't merge it as is.

misshu93 commented 7 years ago

Oh, you're right... Alessandro asked me to modify this script in order to take the year from command line but I think he say me the wrong repo... Anyway, I tried to run your script but it seems not generate anything. Is this script finished?

mitio commented 7 years ago

The code uses this file to generate the certificates. It is finished and works properly.

It was originally derived from the pyploma.py script, but has since then been heavily modified. You've replaced the new file with the old pyploma.py script and that would not work. You've also added a few old files which are no longer used. You've probably done that by mistake.

The new code is called by the events website when an event organizer reports the details from his or her event. We then automatically generate the certificate for organizing an event.

There's also the option to invoke the certificate generation from the command line, using Django's commands, see here.

I'm not sure why @alessandrobogliolo wants a year to be passed on the command line, as the year is taken from the event's date, but if it needs to be passed anyway, the change should probably be done in the command.

alessandrobogliolo commented 7 years ago

I think there is some misunderstanding. I asked to take the year from the starting date of the event the certificate is associated to. I think this is exactly what Dimitar has done. Hence, I think no other actions are required for certificates of recognition.

Other certificates will be discussed afterwards.

Thanks

A Il 17/Ott/2016 10:33 "Dimitar Dimitrov" notifications@github.com ha scritto:

The code uses this file to generate the certificates https://github.com/codeeu/coding-events/blob/fe65e1b5f1aa071629173f7282c25bbb5763881c/certificates/generator.py. It is finished and works properly.

It was originally derived from the pyploma.py script, but has since then been heavily modified. You've replaced the new file with the old pyploma.py script and that would not work. You've also added a few old files which are no longer used. You've probably done that by mistake.

The new code is called by the events website when an event organizer reports the details from his or her event. We then automatically generate the certificate for organizing an event.

There's also the option to invoke the certificate generation from the command line, using Django's commands, see here https://github.com/codeeu/coding-events/blob/fe65e1b5f1aa071629173f7282c25bbb5763881c/api/management/commands/generate_certificate.py .

I'm not sure why @alessandrobogliolo https://github.com/alessandrobogliolo wants a year to be passed on the command line, as the year is taken from the event's date, but if it needs to be passed anyway, the change should probably be done in the command.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/codeeu/coding-events/pull/446#issuecomment-254145678, or mute the thread https://github.com/notifications/unsubscribe-auth/AIPCH8C-hVZOe07n9Fz92iWA7DpblHh7ks5q0zLUgaJpZM4KYFT3 .