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

Periods not being stripped from names; breaks file extensions #89

Open
lfracalossiFA opened this issue Nov 6, 2020 · 2 comments
Open

Comments

@lfracalossiFA
Copy link

lfracalossiFA commented Nov 6, 2020

I am trying to generate a number of pages for a list of event speakers. I am having issues when the speaker wishes their degree, i.e. "Ph.D." added as part of their name. The periods are not being stripped, and the result is that in writing the filename, the generator reaches the file extension prematurely, causing havoc in the filesystem. The rendered result is something like this:

Screen Shot 2020-11-06 at 1 46 41 PM

FWIW, I'm not having issues when the "." is in the middle of the name (i.e. "Taylor A. Murphy" becoming "taylor-a.-murphy.html")

I could write my own name_expr, but then I'd give up all the sanitizing stuff you're already doing.

Is this by design, i.e. do we ever need "."s to appear in names? Or is this something that should be fixed?

@avillafiorita
Copy link
Owner

Hi, thanks for the report ...
... and this is odd (which bug isn't?)

I had a look at the code: the extension is appended and not the result of a string replacement which might have caused the issue.

Could you send me or post your configuration, so that I can trace the bug?

thanks

@avillafiorita avillafiorita added the feedback waiting for feedback on the issue label Nov 7, 2020
@lfracalossiFA
Copy link
Author

Hi @avillafiorita,
I'm not sure how much info you need, but here are the datapage_gen-related parts of my config.yml file:

plugins:
  - jekyll-datapage-generator

page_gen-dirs: false 

page_gen:
  - data: 'coalesce-sessions-2020'
    template: 'coalesce-agenda-item'
    name: 'title'
    dir: 'coalesce/agenda'
  - data: 'coalesce-speakers-2020'
    template: 'coalesce-speaker'
    name: 'fullName'
    dir: coalesce/speakers

And here are two of the problem items (in a YAML file in _data) that datapage_gen is trying to read:

- fullName: "Taylor A. Murphy, Ph.D."
  firstName: "Taylor"
  lastName: "Murphy"
  title: "Staff Data Engineer"
  company: "GitLab"
  pronouns: "He, him, his"
  twitterHandle: "tayloramurphy"
  location: Tennessee, US
  bio: "Taylor is a data geek who loves increasing efficiency, transparency, and value with data. His background is in Chemical and Biomolecular Engineering, but he learned he loves computers and data more while working as a Data Scientist. When not munging or analyzing data, he enjoys being outdoors with his wife and sons, reading, writing, playing ultimate frisbee, playing with his dogs, and learning about anything related to space."
- fullName: Colleen Tartow, Ph.D.
  firstName: Colleen
  lastName: Tartow
  title: Director of Engineering
  company: Starburst Data
  pronouns: She, her, hers
  twitterHandle: ctartow
  location: Boston, US
  bio: Colleen is the Director of Engineering at Starburst Data, has a PhD in astrophysics, and has been obsessed with data for her entire life. She is determined to make engineering organizations better for both humans and business through mentoring, leadership, and streamlining processes. Her work on data, engineering, analytics, and diversity issues has led to her speaking and mentoring in a variety of venues in Boston and beyond.

I can send along more upon request.

Thanks,
Lise

@avillafiorita avillafiorita added bug enhancement and removed feedback waiting for feedback on the issue labels Feb 9, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants