1.0.0 Beta 10 can have members register through XenForo's own registration service, so another add-on's reaction to a registration happens for them.
Nothing from Beta 9 has changed its name or its behaviour, and there is no upgrade step: upload the files and upgrade as usual.
New
- Registration through XenForo's service.
seeder:run User -p registered=1, orUserFactory::registered(), saves each member through XenForo's registration service, so an add-on that extends it - to record the browser or the country a member signed up from, say - does so for seeded members as well. XenForo itself mails and alerts nobody: its mail, welcome message and trophies are off for the save. The forum's registration setup decides whether a member is valid or awaiting confirmation or approval, unlessmoderated()orunconfirmed()says which, and a member the forum's options ask a date of birth or a location of is given one.- The request a registration arrives on.
registered(['REMOTE_ADDR' => '203.0.113.7', 'HTTP_CF_IPCOUNTRY' => 'AU'])sets the address and headers XenForo's request carries during the save.Context::withRequest()does the same for any code of your own, and puts the real request back afterwards, even when that code throws.
Worth knowing
registered=1runs whatever other add-ons do on a registration, which can include sending the member's details out of the forum. The seeder says so before it starts.- It is not in
seeder:validate's sample, for that reason.- XenForo's spam check is not run: the registration form runs it, not the service.
- The approval queue shows the address from the member's registration in the IP log, which is where a registered member's address goes.
- Beta 9 given
registered=1makes the members the ordinary way, lists the parameter as ignored and exits with 1. The README marks both additions since 1.0.0b10.
1.0.0 Beta 9 seeds profile posts, and can have every member given to a poll vote in it.
Nothing from Beta 8 has changed its name or its behaviour, and there is no upgrade step: upload the files and upgrade as usual.
New
- Profile posts.
seeder:run ProfilePost, orProfilePostFactoryandProfilePostCommentFactory, write messages one member leaves on another's profile, status updates, and comments on both. They go through XenForo's own profile post and comment creators, so comment counts, dates and latest comments are as a forum leaves them, and each appears in the news feed. Nobody is alerted - not the profile's owner, not the author, not anyone mentioned - and no address is logged.- A poll every member votes in.
ThreadFactory::votedByAll()has every member given torecycle()vote once, rather than a random number of them, for a check that needs to know exactly who voted:->recycle($voters)->withPoll(4)->votedByAll().
Worth knowing
- A profile post is by someone other than the profile's owner unless
status()says otherwise.- Profile posts are in
seeder:validate's sample. The default seeder does not make them; runProfilePostafter it.ProfilePostgiven to Beta 8 is refused as an unknown seeder. The README marks both additions since 1.0.0b9.
1.0.0 Beta 8 seeds the job queue: weeks of failed jobs, and jobs waiting that will never run.
Nothing from Beta 7 has changed its name or its behaviour, and there is no upgrade step: upload the files and upgrade as usual.
New
- Failed jobs.
seeder:run Job, orFailedJobFactory, writes the history XenForo 2.3 keeps when a job throws: a few faults that recur and many one-offs, thrown from XenForo's code and the libraries it ships, from an add-on and the libraries it ships, from outside the forum, and with no file at all. A fault inside the forum names a real file where there is one. Some messages quote a credential, every one made up and markedSECRETorexample.com, for testing whatever displays these to remove them. None is dated within a day of now.- Jobs in the queue, with
JobFactory: some to be run by hand, some tried and waiting to try again. None will ever run. Each is due five to ten years from now and names a job class that does not exist, so a seeded queue has nothing due or stalled.
Worth knowing
- Neither is in
seeder:validate's sample or the default seeder, like the error log.- XenForo has no entity for either table, so
seeder:listnames themxf_failed_jobandxf_job.Jobgiven to Beta 7 is refused as an unknown seeder. The README marks it since 1.0.0b8.
1.0.0 Beta 7 can offer seeded user upgrades for sale, and says so when a factory is used where nothing records what it makes.
Nothing from Beta 6 has changed its name or its behaviour, and there is no upgrade step: upload the files and upgrade as usual.
New
- User upgrades offered for sale.
UserUpgradeFactory::new()->purchasable(), or-p purchasable=Non theUserUpgradeseeder, lists an upgrade among those members can buy, with its purchase button. It still cannot be bought: the payment profile it names is switched off, and XenForo refuses a purchase through it before writing anything. The seeder says so before it starts.- A warning for a factory used outside
seeder:run. Called from a script or a shell, a factory records nothing, so what it makes is in no batch andseeder:cleancannot remove it. The first thing a process makes that way is now named in the server error log and on standard error. Inside a database transaction - a test that rolls its work back - nothing is said. On XenForo 2.3.0 only standard error carries it: XenForo's own error logging cannot write from a script there.
Worth knowing
- The README said a seeded upgrade could not be bought because
can_purchasewas off. It is the switched-off payment profile that stops a purchase;can_purchaseonly decides whether the upgrade is offered.- XenForo shows a guest every upgrade as available, whatever
can_purchasesays, and a command-line script that sets no visitor is a guest. Check the list as a member.- A parameter from this release given to Beta 6 is named as ignored and the run exits 1. The README marks each new one since 1.0.0b7.
1.0.0 Beta 6 adds categories and forums inside forums, so a run can build a whole forum tree.
Nothing from Beta 5 has changed its name or its behaviour, and there is no upgrade step: upload the files and upgrade as usual.
New
- Categories.
CategoryFactorymakes a category, and every forum factory now hasin($parent):ForumFactory::new()->in($category), or->in($forum)for a sub-forum. It takes a node, or the category or forum behind one.- A forum tree from a seeder.
categorieson theDefaultseeder puts the forums inside that many categories, andsubforumsgives each forum one or more forums inside it. Threads go into every forum, sub-forums included:
seeder:run Default -p categories=3 -p forums=6 -p subforums=2
Fixed
- A forum given a parent made earlier in the same run was refused with "Please select a valid parent". XenForo works out where a node sits in the tree at the end of a request; Seeder now has it do that as each node is saved, so a run can make a category and the forums inside it one after another.
Worth knowing
- Cleaning removes a tree deepest first. A forum you made yourself inside a seeded category is moved up to the category's parent when the category goes, as XenForo does when a category is deleted.
- Through
Default,permission_groupsputs every member it makes in a group, not only the authors: every memberDefaultmakes is an author.- A parameter from this release given to Beta 5 is named as ignored and the run exits 1. The README marks each new one since 1.0.0b6.
1.0.0 Beta 5 adds permissions on a forum, so seeded members can fall into several permission combinations.
Nothing from Beta 4 has changed its name or its behaviour, and there is no upgrade step: upload the files and upgrade as usual.
New
- Permissions on a forum.
UserGroupFactory::new()->grantingOn($forum, ['forum' => ['viewOthers' => 'deny']])gives a user group its own permissions on one forum or other node, as the control panel's node permissions do:content_allow,resetordenyfor a flag, a number for a limit. A permission a node cannot have is refused.- Members in several permission combinations.
permission_groupson theThreadandDefaultseeders makes that many groups, each denying its members other members' threads in one of the run's forums, and spreads the authors across them. Code that filters content per member - a digest, a feed, a search - needs members who see different things, and until now every seeded member saw the same.
Fixed
- A
forumparameter naming something that is not a forum made theThreadseeder's authors before refusing. It now refuses before making anything, and says what the node is.
Worth knowing
- A seeded member's preferences are the forum's default registration values. XenForo ships receive admin email off there, so code that selects members by it finds no seeded member until one is set with
state(['Option.receive_admin_email' => true]). The README now says so.- Deleting a user group empties the forum's cached CSS, so cleaning a batch with permission groups does too, as with the user groups in Beta 3.
- A parameter from this release given to Beta 4 is named as ignored and the run exits 1. The README marks each new one since 1.0.0b5.
1.0.0 Beta 4 adds IP logs, members' histories - the change log, username changes and rejected registrations - and the moderator log.
Nothing from Beta 3 has changed its name, and there is no upgrade step: upload the files and upgrade as usual. One thing behaves differently: see Worth knowing.
New
- IP logs.
ips=1on theUserseeder gives every member an IP log, as XenForo writes one while a member uses the forum: a row for registering, logins up to their last activity (some through a "stay logged in" cookie), logins to the admin control panel for an administrator, and a few changes to the account. On theThreadseeder it also logs the address of every thread and reply, against the post as XenForo does. In a factory:UserFactory::new()->withIpLog(), andwithIp()onThreadFactoryandPostFactory.- Addresses that cannot be real. Every seeded address is from the ranges set aside for documentation (
192.0.2.0/24,198.51.100.0/24,203.0.113.0/24,2001:db8::/32). Each member has one to three for a run, and some members share one, so an address can lead to several members. Faker hasdocumentationIp()for your own.- The change log.
changeson theUserseeder, orwithChanges(), makes members who have changed their account since registering - time zone, location, website, signature, email address, privacy and mail preferences - and some changes made by an administrator, so XenForo's own change log records both kinds of editor.- Username changes.
renamedon theUserseeder, orrenamed(), gives members earlier names, recorded as approved changes.withUsernameRequest()adds one awaiting approval, in the approval queue, or one rejected by a moderator. The member is not renamed, so nothing they posted has to be rewritten.- Rejected registrations.
rejectedon theUserseeder, orrejected(), with XenForo's rejection record: by its spam check at registration, or by a moderator after it.- The moderator log. The
ModeratorLogseeder writes a moderator log about members' threads, replies and accounts, in XenForo's own words, andModeratorLogFactorywrites one about content you already have. The history agrees with the content as it is now: an open thread was locked and then unlocked. No entry is dated in the last two hours.
Worth knowing
- Moderator log entries are written straight into the table. Add-ons that act on a moderator action as it is taken - extending XenForo's logger, or watching each entry as it is saved - send it to a chat channel or a log. They do not see these, and
seeder:runnames any such add-on it finds active. The seeder is not in the sampleseeder:validateuses, so validating never writes one.withLogin()now logs in from the member's own address, from the documentation ranges, where Beta 3 used198.18.0.0/15.- A parameter from this release given to Beta 3 is named as ignored and the run exits 1. The README marks each new one since 1.0.0b4.
1.0.0 Beta 3 adds administrators, the admin log, members who hold permissions, and crawler user agents.
Nothing from Beta 2 has changed its name or its behaviour, and there is no upgrade step: upload the files and upgrade as usual.
New
- Administrators.
adminson theUserseeder makes members who are administrators, with the administrator record XenForo keeps. In a factory:UserFactory::new()->administrator(), oradministrator('user', 'option')with the administrator permissions named.- The admin log. The
AdminLogseeder writes an admin log with history: a few administrators, the ordinary actions repeated and the unusual ones once.AdminLogFactoryhasby(),action()andfrom(). As with the server error log, no entry is dated in the last two hours, so nothing that reports new entries picks a seeded one up.- Members who hold permissions.
permittedandpermissionson theUserseeder --p permitted=5 -p permissions=general.bypassFloodCheck,conversation.maxRecipients:50- orUserFactory::new()->withPermissions([...]). Each member is put in an extra user group made to grant them, so they stay in Registered, and members given the same permissions share one group. A permission the forum does not have is refused, and so is a value it would not take. Another add-on's permissions work too.- User groups.
UserGroupFactory::new()->granting([...])makes a group with the permissions it grants, written as the admin control panel writes them.- Crawler and browser user agents. Seeders and factories now have
crawlerUserAgent()(a real crawler this forum takes for a robot, the commonest most often, or one for a robot you name),browserUserAgent()(one this forum does not take for a robot) androbotFor($userAgent)on$this->context()->faker. Which agents are robots is the forum's own robot list, as other add-ons have extended it.
Worth knowing
- Cleaning a batch with a user group in it empties the cached CSS. Deleting a user group makes XenForo mark every style as changed, as an HTML widget does, so
seeder:validatemakes no group. Creating one does not.- XenForo tidies up after a deleted group, forum-wide. Once the group is gone its own job removes every permission combination no member has any more - not only the ones seeded members had.
- A parameter from this release given to Beta 2 is named as ignored and the run exits 1. The README marks each new one since 1.0.0b3.
1.0.0 Beta 2 adds forum types, search forums, polls, sticky threads, resource discussion threads, media comments and widgets.
Nothing in Beta 1 has changed its name or its behaviour, and there is no upgrade step: upload the files and upgrade as usual.
New
- Forums of any type.
forum_typeon theThreadseeder makes an article, question or suggestion forum with threads of that type, andforum_types=1onDefaultmakes one of each. In a factory:ForumFactory::new()->article(),question(),suggestion()ortype($id).- Search forums. The
SearchForumseeder andSearchForumFactorymake search forums that list the threads of the forums they are given.- Polls.
pollson theThreadseeder, orThreadFactory::new()->withPoll($choices, $votes), makes poll threads with votes from the run's members. A new XenForo forum takes no poll threads, soForumFactory::new()->allowing('poll')says which other thread types a forum takes. Forums the seeders make opt in when polls are asked for.- Sticky threads.
stickyon theThreadseeder.- Resource discussion threads.
discussions=1on theResourceseeder gives each resource its discussion thread, in a forum made for them or one you name withforum.- Media comments.
commentson theMediaseeder, andMediaCommentFactory.- Widgets. The
Widgetseeder andWidgetFactoryput widgets with a title in any widget position. Cleaning one also deletes the compiled file XenForo leaves behind when a widget is deleted.
For your own seeders and factories
- The README now shows how to keep an attribute that is not a column between
newEntity()andstore(), and says thatstore()may hand the entity to a service of your own.seeder:validatecounts rows, not files. A factory whose entities have files should delete them inremove(), and you should count the files before seeding and after cleaning.
Worth knowing
seeder:validateis not a read-only check. Where seeding is switched on it creates content and removes it again.seeder:validate --unattendedandseeder:configwrite nothing.- An HTML widget has a template of its own. Saving or deleting one marks every style as changed and empties the cached CSS, as editing a template in the admin control panel does. So the seeder makes none unless asked with
html.- A parameter from this release given to Beta 1 is named as ignored and the run exits 1. The README marks each new one since 1.0.0b2.
We use essential cookies to make this site work, and optional cookies to enhance your experience.