• Home
  • Categories
  • Recent
  • Popular
  • Top
  • Tags
  • Users
  • Groups
  • Documentation
    • Home
    • Read API
    • Write API
    • Plugin Development
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
v3.5.2 Latest
Buy Hosting

0.6.0 Breaking Changes

Scheduled Pinned Locked Moved NodeBB Development
0.6.0breaking
25 Posts 7 Posters 14.0k Views
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • barisB Offline
    barisB Offline
    <baris> NodeBB
    wrote on last edited by baris
    #1

    Hook changes

    Static

    • static:app.load change see this thread

    Filter

    • filter:post.parse, filter:post.parseSignature see this thread
    • filter:uploadImage, filter:uploadFile see this thread
    • filter:category.get change see this commit
    • filter:register.build change see this commit
    • filter:register.check change see this commit
    • filter:register.complete change see this commit
    • filter:post.getFields change see this commit
    • filter:post.setFields change see this commit

    Action

    • action:topic.save, action:topic.edit, action.topic.restore see this thread
    • action:user.set change see this comit
    • action:user.verify change see this commit
    • action:post.purge and action:topic.purge see this commit

    Key renames

    • 'categories:' + cid + ':tid' renamed to 'cid:' + cid + ':tids'
    • 'cid:' + cid + ':uid:' + uid + ':tid' renamed to 'cid:' + cid + ':uid:' + uid + ':tids'
    • 'categories:recent_posts:cid:' + cid renamed to 'cid:' + cid + ':pids'

    Widgets

    • Recent Replies widget has been deprecated, it will no longer render anything please use the Recent Posts widget instead.

    config.json

    • Please see this thread and this thread
    • Please see this thread for websocketAddress change

    header.tpl

    • Please see this thread

    TBD 💔

    1 Reply Last reply
    3
  • A Offline
    A Offline
    a_5mith
    wrote on last edited by
    #2

    @Technowix To be declared. Usually.

    1 Reply Last reply
    0
  • barisB Offline
    barisB Offline
    <baris> NodeBB
    wrote on last edited by
    #3

    Haha yeah we will put all the breaking changes that will happen in 0.6.0 as we commit them. There will be some changes to some plugin hooks.

    A 1 Reply Last reply
    0
  • A Offline
    A Offline
    a_5mith
    replied to <baris> on last edited by
    #4

    @baris As long as it's not the rel:nofollow fiasco again, I'll probably be ok with them. 😆

    1 Reply Last reply
    0
  • julianJ Offline
    julianJ Offline
    julian GNU/Linux
    wrote on last edited by
    #5

    @a_5mith Oh buddy, that's coming alright. But I'll try to let you know sooner 😛

    1 Reply Last reply
    0
  • barisB Offline
    barisB Offline
    <baris> NodeBB
    wrote on last edited by
    #6

    Updated with filter:post.parse and filter:post.parseSignature changes. Thread for reference https://community.nodebb.org/topic/3039/filter-post-parse-and-filter-post-parsesignature-changes

    1 Reply Last reply
    1
  • julianJ Offline
    julianJ Offline
    julian GNU/Linux
    wrote on last edited by julian
    #7

    @a_5mith ^ That change probably broke a lot of your plugins.

    If you are updating any of them, you should add a new section into package.json:

    {
      ...
      "nbbpm": {
        "compatibility": "^0.6.0"
      }
    }
    

    NodeBB doesn't read that value yet, but it will soon.

    1 Reply Last reply
    0
  • A Offline
    A Offline
    a_5mith
    wrote on last edited by a_5mith
    #8

    Yay. 😛 Will do. I noticed @baris offered a PR on one of my plugins, I'll take a look when I'm slightly more awake, had a 4 hour interview today including full competency exam. I'm knackered. 😆

    List of affected plugins will be marked as I've updated them in npm.

    Youtube Lite (Updated)
    Mixcloud (Updated)
    My Custom Soundcloud Plugin
    Vine
    Flipkart
    Codepen
    Beat.TV
    Beatport
    Embed.ly
    JotForm
    Twitch.TV
    Vexflow
    jsFiddle
    Spotify(PR)
    Slideshare
    HearThis.at

    Le sigh. Much plugins, very work.

    1 Reply Last reply
    0
  • barisB Offline
    barisB Offline
    <baris> NodeBB
    wrote on last edited by
    #9

    Updated with key renames, related issue https://github.com/NodeBB/NodeBB/issues/2356.

    @a_5mith you should also move the regular expressions out of the .parse function while you are updating.

    A 1 Reply Last reply
    0
  • A Offline
    A Offline
    a_5mith
    replied to <baris> on last edited by
    #10

    Thanks @baris, will be sure to check for that. 👍

    1 Reply Last reply
    0
  • barisB Offline
    barisB Offline
    <baris> NodeBB
    wrote on last edited by
    #11

    Updated with hook changes to action:topic.save, action:topic.restore and action:topic.edit.

    Related thread https://community.nodebb.org/topic/3153/action-topic-save-action-topic-restore-action-topic-edit-changes

    Related GH issue https://github.com/NodeBB/NodeBB/issues/2357

    1 Reply Last reply
    0
  • barisB Offline
    barisB Offline
    <baris> NodeBB
    wrote on last edited by
    #12

    filter:category.get parameters changed, related commit
    https://github.com/NodeBB/NodeBB/commit/db979d7a20acb93ed1961f2c3579e2ed660bf89e

    @trevor I know this affects one of the plugins that you use.

    1 Reply Last reply
    1
  • barisB Offline
    barisB Offline
    <baris> NodeBB
    wrote on last edited by
    #13

    Two new hooks action:post.purge and action:topic.purge. Relevant commit https://github.com/NodeBB/NodeBB/commit/f9f1cf63cf9f46dfc2c4a0d64139efbe09873638

    1 Reply Last reply
    0
  • SchamperS Offline
    SchamperS Offline
    Schamper Plugin & Theme Dev
    wrote on last edited by Schamper
    #14

    So with most (all?) multi-argument hooks being updated to use a single data object, what will become of the single argument hooks? Will they get the same treatment with in mind that more data can be added later?

    Sorry if this has been discussed before, must've missed it.

    1 Reply Last reply
    0
  • barisB Offline
    barisB Offline
    <baris> NodeBB
    wrote on last edited by
    #15

    Ideally we should change those to be objects as well so we don't have to do this amount of breaking changes in the future. Ie stuff like

    plugins.fireHook('action:post.delete', pid);

    Should be

    plugins.fireHook('action:post.delete', {pid: pid, uid:uid});

    There aren't alot of these as far as I know so I will make a list and let you all know about the changes here when they happen.

    1 Reply Last reply
    1
  • julianJ Offline
    julianJ Offline
    julian GNU/Linux
    wrote on last edited by
    #16

    @baris I thought we were leaving the single-argument hooks as-is for now? I don't mind changing it, though... may as well get it all over in one go.

    frissdiegurkeF 1 Reply Last reply
    0
  • frissdiegurkeF Offline
    frissdiegurkeF Offline
    frissdiegurke Plugin & Theme Dev
    replied to julian on last edited by
    #17

    @julian said:

    @baris I thought we were leaving the single-argument hooks as-is for now? I don't mind changing it, though...

    👎

    may as well get it all over in one go.

    👍

    1 Reply Last reply
    0
  • barisB Offline
    barisB Offline
    <baris> NodeBB
    wrote on last edited by
    #18

    Recent Replies widget is deprecated please switch over to Recent Posts widget if you were using it. It has the same functionality.

    1 Reply Last reply
    0
  • barisB Offline
    barisB Offline
    <baris> NodeBB
    wrote on last edited by
    #19

    Updated with link to config changes. https://community.nodebb.org/topic/3392/config-json-updated-base_url-and-relative_path-no-longer-exist

    1 Reply Last reply
    0
  • agarcia17A Offline
    agarcia17A Offline
    agarcia17
    wrote on last edited by agarcia17
    #20

    I'm confused, are all hooks being updated to use a single data object? in particular
    plugins.fireHook('action:topic.delete', tid); ?

    PS. is there a set date you guys are aiming for the 0.6.0 release?

    1 Reply Last reply
    0

Copyright © 2023 NodeBB | Contributors
  • Login

  • Don't have an account? Register

  • Login or register to search.
Powered by NodeBB Contributors
  • First post
    Last post
0
  • Home
  • Categories
  • Recent
  • Popular
  • Top
  • Tags
  • Users
  • Groups
  • Documentation
    • Home
    • Read API
    • Write API
    • Plugin Development