Just opening up the conversation of porting this module to Drupal 8. Has there been any discussion or thoughts on the approach?

We'd be happy to help out. :-)

Kim

Comments

Dave Reid’s picture

We would need to get a planning session for update strategy. With a lot of the page rendering process changed, I am very worried about being able to output Metatags in the ways we expect to do so. As well as make sure to account for the newer D8 technologies like CMI.

anavarre’s picture

As Core is stabilizing a bit more nowadays, I wonder if it makes sense to start the discussion again?

DamienMcKenna’s picture

Category:Feature request» Task
Issue summary:View changes
Status:Active» Postponed

I don't recommend touching this until 8.0-beta1 is release, and I'm personally focusing on D7 for the foreseeable future.

If else anyone wants to work on this I'm happy to assist.

kim.pepper’s picture

OK great. I might set up a sandbox so we can start playing around with a port in there.

kim.pepper’s picture

Sandbox created here. https://drupal.org/sandbox/kimpepper/2175287

Let me know if you'd like write access.

ivanjaros’s picture

Any updates on this?

kim.pepper’s picture

No. I've not spent any time on this in the last 6 months.

Any objections to using Github for the initial conversion efforts? It's been very useful for porting token and pathauto so far.

Dave Reid’s picture

I would request this is work is postponed until 8.0-beta1 is out and this module has reached the 1.0 release.

ivanjaros’s picture

@dave - I think D8 has quite stable API already. Yes, sometimes minor changes are made but I haven't had a problem since december and I'm making a big distribution(and I have a big need for SEO module like this one).

anavarre’s picture

Status for D8 is 3 beta blockers left and Damien said earlier this week that 1.0 might soon be released (pending performance work in https://www.drupal.org/node/2307383 I guess)

It seems reasonable to wait just a big longer. We're talking about 1 month maybe.

rickmanelius’s picture

Dave mentioned in #8 that it would be useful to pause this until metatag-7.x-1.0 and drupal-8.0-beta1. Would this be an appropriate time to revisit this now that both milestones have been met?

DamienMcKenna’s picture

Title:Port metatag to Drupal 8» Port Metatag to Drupal 8
Status:Postponed» Active

Indeed it would. Anyone want to work on this?

kim.pepper’s picture

/me raises hand.

Are we happy to do an initial conversion to D8, then do conversions to plugins and config entities as followups?

DamienMcKenna’s picture

@kim.pepper: I'd be completely satisfied with that - v1 as a "get it working" port, v2 as a "this is how it should work" cleanup.

kim.pepper’s picture

Hmm. This is going to be quite tricky.

I had a go at running drupalmoduleupgrader across it to pick up anything automated. Had very limited luck, and ran into some fatals.

I've made attempts at some simple function conversions in the metatag.install and metatag.module files.

Pushing my code up here https://github.com/kimpepper/metatag

Let me know if you'd like write access.

Kim

rickmanelius’s picture

Hi @kim.pepper. From the looks of it, the https://www.drupal.org/project/drupalmoduleupgrader module is still moving quickly to resolve a lot of open tickets, so it's possible that improvements coming down the pipeline might address the issues you were hitting in #15.

I'm not ready to dive in yet, but this module is on my wishlist as I'm starting to explore Drupal 8 a bit more. I'll let you know if it warrants gaining access (or just forking your copy outright).

DamienMcKenna’s picture

kim.pepper’s picture

@DamienMcKenna do you want to use yours as the primary repo to submit pull requests to?

DamienMcKenna’s picture

@kim.pepper: You don't have to (it's git after all) but it might make some things easier for you, e.g. keeping up with changes in the D7 codebase.

valthebald’s picture

wish I saw this topic earlier...
@kim.pepper: Have you done any work except for initial commit? Is it result of drupalmoduleupgrader?

I am working for some time on https://www.drupal.org/sandbox/valthebald/2339829, but of course, I'd prefer to join efforts with someone else, if the work is already in progress

DamienMcKenna’s picture

FYI just to mention it, I'm expecting to start getting involved in this sometime in January.

kim.pepper’s picture

@valthebald No, I haven't done much at all.

Happy to work with others around another repo.

Kim

valthebald’s picture

@DamienMcKenna/@kim.pepper, I have granted you commit permissions to the sandbox project.

If someone else is going to work on this, it would be probably a good idea to start opening issues, at least for the big tasks (i.e. converting meta tag configuration to D8 configuration entities)

DamienMcKenna’s picture

I'll be starting on this in the next week-or-two.

DamienMcKenna’s picture

Would anyone be interested in having a hangout / skype chat to discuss this within the next two weeks?

Dave Reid’s picture

I could in IRC.

mikey_p’s picture

IRC or hangout would be cool.

tsvenson’s picture

@DamienMcKenna *promoted* this on on Twitter just. I plan to use this module for a Drupal 8 project I'm about to startup now.

Will there be a need for supporting direct upgrading from a D7 site, or is that being easier to make now using Migrate in core?

rvilar’s picture

I'm interested too. For me is better IRC too

alex_drupal_dev’s picture

Hey Damien I am still pretty new to the Drupal 8 format for modules but I have been playing with it a bit. I would be happy to help out in any way I can. Let me know when you want to have the IRC and I will check it out. :)

jibran’s picture

IRC +1

valthebald’s picture

irc+1

a.milkovsky’s picture

As I see there are 2 repos for porting of the metatag module to Drupal 8:
1. https://github.com/kimpepper/metatag
2. https://www.drupal.org/sandbox/valthebald/2339829
And https://github.com/damienmckenna/metatag as well.

Which one will be used for development now?

P.S: irc +1

DamienMcKenna’s picture

FYI what I uploaded to github is a mirror of the main repo, and I also have one on bitbucket: https://bitbucket.org/DamienMcKenna/metatag

DamienMcKenna’s picture

Please select one of the times on the following event invite:

DamienMcKenna’s picture

So far it seems that either Monday the 16th or Tuesday the 17th between noon and 2pm EST (5pm to 7pm GMT) would work for more people than the other times, the difference currently comes down to whether valthebald or mikey_p could make it. I'll follow up tomorrow and will make a decision then.

DamienMcKenna’s picture

FYI I've changed the time options to only include when Dave Reid was available, please review the times and update your selection as appropriate. Thank you.

valthebald’s picture

I can make it both on 16th and 17th on suggested hours (will update doodle now)

DamienMcKenna’s picture

Ok, thank you all for letting me know when would work best for you. Based on the submissions I've picked this coming Monday, February 16th between noon and 2pm EST, i.e. between 5pm and 7pm GMT; you can download an icalendar file to add it to your calendar.

Lets plan to meet in the #drupal-seo channel on Freenode IRC.

DamienMcKenna’s picture

DamienMcKenna’s picture

Issue tags:+D8CX
DamienMcKenna’s picture

Issue tags:+Drupal 8.x
DamienMcKenna’s picture

I discovered that when drupal_set_title() was removed it was no longer possible to arbitrarily set the page title from a page a module does not control; we'll need to resolve #2121123: Introduce Drupal::formatTitle() as a replacement for drupal_set_title.

DamienMcKenna’s picture

Another one: hook_page_build() was removed so we'll have to use either hook_page_attachments() or hook_page_attachments_alter(). Hopefully.

Berdir’s picture

hook_page_attachments() should work fine for everything that uses #attached, yes, that's the only thing it can do. (and yes, html_head elements can be added through that, although the API is a bit strange)

DamienMcKenna’s picture

FYI I've made a rough alpha-grade copy available:

It doesn't do much, and there are a few todo items that we'll be dealing with early next week to fix some items, but it's a step in the right direction. Right now it *only* supports entities, check the README.txt file for the full todo list.

DamienMcKenna’s picture

The D8 codebase is now able to output the page title, and has a number of other improvements since last week. Please feel free to poke it with a stick.

ivanjaros’s picture

The only thing I was able to do was attach the field. I couldn't finish configuring it because if yo uvisit the field settings page the browser will abort the request. The same goes for displaying an entity form with attached field. Seems like issue with plugin implementation/invokation.

DamienMcKenna’s picture

@ivanjaros: I wasn't able to replicate that problem using 8.0.0-beta9.