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

schedule.xml lacks talk slug #430

Closed
rixx opened this issue May 9, 2018 · 6 comments
Closed

schedule.xml lacks talk slug #430

rixx opened this issue May 9, 2018 · 6 comments

Comments

@rixx
Copy link
Member

@rixx rixx commented May 9, 2018

Due to requests from VOC, pretalx has started to follow frab's slug scheme (event-id-title) instead of exposing a talk's code (the alphanumerical ID). Now, the schedule.xml export contains no reference to the talk's slug at all anymore, so that dependent apps can't link to a talk's page.

I'm currently not really sure how to solve this without breaking compatibility at some point. frab uses numerical ids and puts them in the id field, but the id field is validated (by our tests, and the VOC tests, etc) to be numerical, so we can't use that.

@raphaelm
Copy link
Member

@raphaelm raphaelm commented May 10, 2018

Could we have a view like /event/talk/by-slug/event-id-title/ that redirects to the actual talk view?

@rixx
Copy link
Member Author

@rixx rixx commented May 10, 2018

Sure, but for that to have a non-horrible performance, we'd need to save the slug in the db, so we'll also have to update it with every save, etc. A redirect view would work for the numeric IDs though.

I'd much prefer to find a way to put the pretalx ID somewhere in that export – I'm not sure my dedication to frab compatibility is large enough to justify an extra db field and additional views.

@raphaelm
Copy link
Member

@raphaelm raphaelm commented May 10, 2018

Sure, but for that to have a non-horrible performance, we'd need to save the slug in the db, so we'll also have to update it with every save, etc. A redirect view would work for the numeric IDs though.

Doesn't the slug always contain the submission ID between the first and the second dash? That should be enough to find the talk, no need to save the full slug to the DB. Or did I misunderstand how the slug is built?

@rixx
Copy link
Member Author

@rixx rixx commented May 10, 2018

Oh, yeah, you're right, we could parse out the ID and look it up. shudder This feels really hacky though. Maybe we should just move all of frab compatibility in a plugin, including the export(s) and all, so that core pretalx won't have to deal with this nonsense.

johnjohndoe referenced this issue in johnjohndoe/CampFahrplan May 11, 2018
+ Event part is not available in schedule.xml to compose individual URLs.
@johnjohndoe
Copy link

@johnjohndoe johnjohndoe commented May 11, 2018

I noticed that a few conferences use the <links></links> node of the schedule.xml to link out the corresponding website of the event. As far as I know this is a manual process. Therefore, I have little trust in this workaround.
In EventFahrplan I used to deduce the link from the <event id='5397'> or in rate cases from the <slug>C7WRZV</slug> node.

@saerdnaer
Copy link

@saerdnaer saerdnaer commented May 12, 2018

dependent apps can't link to a talk's page.

Actually, frab's schedule xml introduced a new property for that url, c.f. frab/frab#361

<event guid="dda720ca-f11b-5ef5-beeb-5e33d2ed3e53" id="1">
  <date>2018-05-10T16:00:00+02:00</date>
  <start>16:00</start>
  <duration>01:00</duration>
  <room>ZKM_Media Theater</room>
  <slug>gpn18-1-what-to-hack</slug>
  <url>https://pretalx.entropia.de/gpn18/talk/QUHMNF/</url>
  <recording>
    <license/>
    <optout>false</optout>
  </recording>
  <title>What to hack</title>
  <subtitle/>
  <track/>
  <type>Talk</type>
  <language>de</language>
  <abstract>What to hack: die Eröffnung der GPN18</abstract>
  <description/>
  <persons>
    <person id="1">obelix</person>
  </persons>
  <links/>
</event>
@rixx rixx closed this in c528fa1 Jun 19, 2018
saerdnaer referenced this issue in pretalx/pretalx-media-ccc-de Mar 14, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
4 participants