[SOLVED] Changed overwrite possibilities?


(Martin Huber) #1

Hey,
next stumble … Sorry :persevere:.

I did in Neos 2.3 overwrite the Default Neos-NodeTypes like «maximum» of «‘Neos.Seo:TitleTagMixin’» from 60 to 75 letters.
After migration to 3.0.1 the file Vendor.Site/Configuration/NodeTypes.OverwriteNeosContent.yaml does NOT have any influence. Maybe I did some missteps in the config.file while auto-migration-process. But I don’t know, where I can find the configuration-file for include yaml-files, or to accept overwrite the neos-nodetypes.

The changes within the file seams to be OK.

I also tried to copy the Original nodeType definition out of «/Packages/Application/Neos.Seo/Configuration/NodeTypes.Mixins.yaml» paste it in the OverwriteNeosContent.yaml and change something > Nothing has change in Backend (so typo as reason should be excluded).

Then I changed in the original NodeTypes.Mixins.yaml File > the change is visible in Backend.

I changed also the file-Name, so it will be at the end with z_. Also include in other nodeType files. The definition of the other nodetype within is working, but the overwrite part also get no change in Backend …

No more ideas.

  • What could be the fault?

  • ***Where I have to set the «new eligibility»***?

  • Some Idea or helping hints?


(Aske Ertmann) #2

Make sure the package you have the overriding config in has a composer dependency to the neos-seo package. That determines the ordering the configuration is loaded in. It probably worked previously because you installed that the SEO package later than the other package, but that’s random and will eventually fail.


(Martin Huber) #3

Probably you are right, but to be honest I’m quite confused after a few tried on different ways. But no one has bring the solution. So I will ask more accurate:

With dependency you mean require-statement?

In Neos 2.3.8 I used a package with all the stuff nodetypes.yaml, typoScript.ts, fluid.html and so on.
In root/composer.json the require-statement was

"require": {
        "typo3/neos": "~2.3.0",
        "typo3/neos-nodetypes": "~2.3.0",
        "typo3/neos-seo": "^1.0",
        "neos/redirecthandler-neosadapter": "^1.0",
        "neos/redirecthandler-databasestorage": "^1.0",
        "typo3/swiftmailer": "^5.4",
        "flowpack/simplesearch-contentrepositoryadaptor": "^1.3",
        "flowpack/simplesearch": "^1.3",
        "mittwald-flow/symlink-publishing": "~2.0",       
        "sitegeist/movealong": "^1.0.0",
        "vendorname/mysitepackage": "~0.2.1"
    },

In «vendorname.mysitepackage/composer.json» was the require statement:

"require": {
        "typo3/neos": "~2.3.0",
        "typo3/neos-nodetypes": "~2.3.0",
        "typo3/neos-seo": "^1.0",
        "neos/redirecthandler-neosadapter": "^1.0",
        "neos/redirecthandler-databasestorage": "^1.0",
        "typo3/swiftmailer": "^5.4",
        "flowpack/simplesearch-contentrepositoryadaptor": "^1.3",
        "flowpack/simplesearch": "^1.3",
        "mittwald-flow/symlink-publishing": "~2.0",        
        "sitegeist/movealong": "^1.0.0"
    },

All was working fine with the overwrite-stuff like «‘TYPO3.Neos.NodeTypes:TitleMixin’:» Although the require-statement was nearly duplicated.

Neos 3.0 migration

While migration to 3.0 there where a lot of problems. I guess, also because of duplicated require-statements.
So I cleaned up (beside countless other trials), all the important migration-auto-rename in the root-composer.json:

root/composer.json:

"require": {
        "neos/neos": "~3.0.0",
        "neos/nodetypes": "~3.0.0",
        "neos/seo": "~2.0.0",
        "neos/redirecthandler-neosadapter": "^2.0",
        "neos/redirecthandler-databasestorage": "^2.0",
        "neos/swiftmailer": "~6.0.0",
        "flowpack/simplesearch-contentrepositoryadaptor": "^2.0",
        "flowpack/simplesearch": "^2.0",       
        "vendorname/mysitepackage": "3.0.0"
    },

In «vendorname.mysitepackage/composer.json» was the require statement:

"require": {
        "neos/neos": "~3.0.0"
    },

At the end, the migration was successful and most of the problems was gone. Know with your tip I tried in all directions:
1. Back to duplicate all the requires
2. in root only require “vendorname/mysitepackage”: “3.0.0” in package composer.json all the other stuff.
3. Duplicate all the requires but vendorname/mysitepackage at the top
Also with flush cache between, and relogin in backend

Alltime the same: The maximum from the default-nodeType ‘Neos.Seo:SeoMetaTagsMixin’: is showing without overwriting …

###Question:

  • Sorry – Probably I understand something fundamental wrong. Did someone has a tip?

(Aske Ertmann) #4

You can do it that way, but if the site package is part of your distribution git repository it’s a bit cumbersome.

What I usually do is to have the root composer manifest have stuff like you had it and then just add a few dependencies that the site package actually needs in the site package composer manifest with a * version requirement and then keeping the actual versions in the root manifest.

Example https://github.com/neos/Neos.Demo/blob/master/composer.json#L7-L9


(Aske Ertmann) #5

And remember to run ./flow package:rescan after changing these things. Possibly also deleting Configuration/PackageStates.php


(Martin Huber) #6

Crazy, but Yepp, works at the end:

So for other stumblers:
I did:
root.manifest (root/composer.json excerpt: only require part):

"require": {
        "neos/neos": "~3.0.0",
        "neos/nodetypes": "~3.0.0",
        "neos/seo": "~2.0.0",
        "neos/redirecthandler-neosadapter": "^2.0",
        "neos/redirecthandler-databasestorage": "^2.0",
        "neos/swiftmailer": "~6.0.0",
        "flowpack/simplesearch-contentrepositoryadaptor": "^2.0",
        "flowpack/simplesearch": "^2.0",
        "jonnitto/googlemaps": "^2.3",
        "vendorname/mysitepackage": "3.0.6"
    },

Own package have to be at the end.

Package composer.manifest (VendorName.SiteName/composer.json excerpt: only require part):

"require": {
        "neos/neos": "*",
        "neos/nodetypes": "*",
        "neos/seo": "*"
    },

And all the other packages where you like to overwrite parts.

Then I did:
1. execute: composer update
2. execute: rm Configuration/PackageStates.php
3. execute: ./flow neos.flow:package:rescan
short ./flow package:rescan throws an error:
Unrecognized Command
Sorry, but he command “neos.flow:package:rescan” must be specified by its full command
identifier because it is a compile time command which cannot be resolved
from an abbreviated command identifier.

So use the long «noes.flow:package…» from step 3.
##4. DONE – Overwrite is operative!

Tank you @aertmann!

###Last short question:

  • Is it ok, when I delete all the migrations.stuff in extra. Looks not simplifying: Or would the deleting be a cause for next stumbling?

[SOLVED] Wrong form.yaml-file-pointer on public server with subdomain using
(Gökhan Sirin) #7

Thank you! Helped me a lot today!