-
Notifications
You must be signed in to change notification settings - Fork 37
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
Deprecation errors using categories and category #35
Comments
I have migrated from |
I managed to apply one of the pull requests changes to categories and tags to my own fork then use that in the gem file. I can finally see the errors im getting. Noticed this plugin does not function from a page that is generated from another generator.... |
Same for using the tag key: |
It's happening to us too, after applying pagination to blog posts with categorization. |
The same happens for me with github-pages. Neither Tags, nor Categories (or their singular) work. octopress-paginate is the only plugin I am using. I am building the site locally with Ruby and pushing the _site/ folder to github pages. In its current form, octopress-paginate cannot do more for me than the basic Jekyll functionality. I might try to use collections instead and report back whether or not that worked. |
Update: The deprecation issue does not seem to appear when using collections. However, while the locally generated site paginates collections, the live github version will simply not accept any collection pagination. The interaction between github pages and octopress-paginate is definitely a strange one. |
I just used this paginate plugin and I am encountering the same warning saying:
My code:
Any updates about this? |
Update: I just pushed my jekyll project on github, I think it was affected by the deprecation warning and now it doesn't show any post at all. In short, pagination does not work. It works on my local machine by the way. |
For those looking to paginate their posts based on category, I suggest using the collection for now while the pagination by category is still encountering the error. |
Running into this same deprecation warning on paginating tags. It does finish the build, it's just a lot of terminal spam. |
I had the same problem and seem to have fixed it. Here is my usage before that presented the same problem as others describe here ("Document#categories is now a key in the #data hash."). A sample collection item, before the fix: ---
index: 0
image_url: IMG_0045.jpg
description: "The drive to Big Bend."
thumbnail_url: IMG_0045-thumbnail.jpg
thumbnail_width: 150
date: October 24, 2017
album: 2017-10-24-big-bend-national-park
category: 2017-10-24-big-bend-national-park # <-- offending line
--- and after: ---
index: 0
image_url: IMG_0045.jpg
description: "The drive to Big Bend."
thumbnail_url: IMG_0045-thumbnail.jpg
thumbnail_width: 150
date: October 24, 2017
album: 2017-10-24-big-bend-national-park
# ↓ the proper usage
data:
category: 2017-10-24-big-bend-national-park
--- And the page that was paginating items of this collection, before: ---
paginate:
collection: photos
category: 2017-10-24-big-bend-national-park # <-- offending line
per_page: 1
limit: false
permalink: /:num/
--- and after: ---
paginate:
collection: photos
# ↓ start fix
data:
category: 201 2017-10-24-big-bend-national-park
# ↑ end fix
per_page: 1
limit: false
permalink: /:num/
--- |
Sorry, but what I just posted doesn't actually work. It just caused a silent failure. At least it didn't show the deprecation warnings ;P What I'd done prior to this is to separate out the deprecation warnings from console output to a file, which I checked in and then can at least see if there are changes in the deprecation messages if it gets dirtied in the git index: |
Every time I specify a category in paginate I run across this error during building.
document#categories is now a key in the #data hash
octopress-paginate.rb:148 in 'block in collection'
Using following settings:
After spending the last hour changing settings it seems to error out on both categories and category.
The text was updated successfully, but these errors were encountered: