{ "info": { "author": "Ross Patterson", "author_email": "me@rpatterson.net", "bugtrack_url": null, "classifiers": [ "Framework :: Plone", "Programming Language :: Python", "Topic :: Software Development :: Libraries :: Python Modules" ], "description": "collective.upgrade\n==================\n\nThis package provides helpers for upgrading CMF portals, such as Plone\nsites, supporting incremental commits, upgrading multiple portals at\nonce, and a command-line script for upgrading scripts outside the\nbrowser with post-mortem debugging of errors. Together, these\nfeatures greatly reduce the amount of time spent on each iteration of\ndeveloping your upgrade steps.\n\nAlso included are a number of upgrade steps for cleaning up messy\nportals during upgrades including cleaning up broken objects,\ncomponents and registrations.\n\n.. contents::\n\nCAUTION\n-------\n\nUse of this package will immediately commit changes to your ZODB.\nThere is no \"dry run\" option as that is contrary to it's purpose. As\nsuch, it should *never* be used on a ZODB that has not been backed up\nalong with the BLOBs *immediately before* use. Neither should it be\nused directly on production as a first attempt at upgrading portals. \n\nQuick Start\n-----------\n\nIn a buildout with::\n\n [instance1]\n recipe = plone.recipe.zope2instance\n eggs = ...\n\nAdd another part like so::\n\n parts =\n ...\n upgrade\n ...\n\n [instance1]\n ...\n eggs = ...\n collective.upgrade\n http-address = localhost:8080\n ...\n\n [upgrade]\n recipe = zc.recipe.egg\n eggs = ${instance1:eggs}\n scripts = upgrade-portals\n arguments = args=[\n '--zope-conf', '${instance1:location}/etc/zope.conf',\n '--log-file', '${buildout:directory}/var/log/upgrade.log']\n ...\n\nThen, after running buildout, you can upgrade all Plone portals and\ntheir add-ons and monitor the progress in ``var/log/upgrade.log`` with::\n\n $ bin/upgrade-portals\n\nAlternatively, you can open the following URL in your browser to\nupgrade all portals and the logs of progress will be streamed to\nyour browser::\n\n http://localhost:8080/@@collective.upgrade.form?submitted=1\n\nUse the ``--help`` option for more details::\n\n $ bin/upgrade-portals --help\n usage: upgrade-portals [-h] [-l FILE] [-z FILE] [-d] [-U] [-G PROFILE_ID] [-A]\n [PATH [PATH ...]]\n \n Upgrade CMF portals in a Zope 2 application using GenericSetup upgrade steps\n \n positional arguments:\n PATH Run upgrades for the portals at the given paths only\n (default: upgrade all CMF portals in the Zope app)\n \n optional arguments:\n -h, --help show this help message and exit\n -l FILE, --log-file FILE\n Log upgrade messages, filtered for duplicates, to FILE\n -z FILE, --zope-conf FILE\n The \"zope.conf\" FILE to use when starting the Zope2 app.\n Can be omitted when used as a zopectl \"run\" script.\n -d, --disable-link-integrity\n When upgrading a portal using plone.app.linkintegrity,\n disable it during the upgrade.\n -u, --username\n Specify username to use during the upgrade (if not\n provided, a special user will run the upgrade).\n\n upgrades:\n -U, --skip-portal-upgrade\n Skip running the upgrade steps for the core Plone\n baseline profile.\n -G PROFILE_ID, --upgrade-profile PROFILE_ID\n Run all upgrade steps for the given profile (default:\n upgrade all installed extension profiles)\n -A, --skip-all-profiles-upgrade\n Skip running all upgrade steps for all installed\n extension profiles.\n\n\nIncremental Commits\n-------------------\n\nSince upgrades are often long running, restarting the upgrade on every\nerror can make troubleshooting and debugging extremely time\nconsuming. It's also unsafe, however, to commit the results of an\nupgrade that failed in the middle since there's no way to guarantee of\ncleanup the partial execution of an upgrade step.\n\nFortunately, the upgrade step support for ``Products.GenericSetup``\nprofiles provides a good way to incrementally commit upgrade progress\nin a way that much less risky and can save a lot of time in the\nupgrade troubleshooting and debugging process.\n\nThe core of ``collective.upgrade`` are upgrader classes which support\nincremental upgrading of a portal using GenericSetup profiles.\nUpgrade starts with the portal's base profile and then proceeds to\nupgrade all the other installed profiles. While processing each\nprofile, it commits at the last successful profile version reached but\naborting any set of upgrade steps that did not succeed.\n\nIn other words, each time a ``collective.upgrade`` upgrader runs, it\nwill pick up from the last successful profile version reached without\nhaving to repeat what has already succeeded.\n\nTo use this upgrader you can simply visit the\n``@@collective.upgrade.form?submitted=1`` view on the portal to\nupgrade. Alternatively, you can use the ``upgrade-portals`` console\nscript described in the `Quick Start`_ section.\n\nMultiple Portals\n----------------\n\nAnother form supports upgrading multiple portals at once. By default\nthe form will start at the form context and walk the Zope OFS object\ntree applying the upgrade to each CMF portal found. It is also\npossible to specify the paths of the portals to upgrade.\n\nIt uses the same incremental commit support described above for each\nportal and commits after each portal and can also be run using the\n``@@collective.upgrade.form?submitted=1`` view on the container of the\nportals to upgrade or using the console script described in the `Quick\nStart`_ section.\n\nCommand-line Script\n-------------------\n\nThis package also provides a runnable script which can be installed\nand used to run the multiple portal upgrade process without using the\nbrowser. The script logs upgrade messages to a separate log file\nfiltering for duplicates to make the upgrade process much easier to\nmonitor and review for any unexpected issues. If the upgrade raises\nan exception, the upgrader will abort the transaction and the console\nscript will invoke ``pdb.post_mortem()`` to allow inspecting the\nerror. Together, these features make the console script a much faster\nway to iterate through the development of an upgrade procedure.\n\nUse the ``--help`` option of the script or see the `Quick Start`_\nsection for details.\n\nReconciling Users and Groups\n----------------------------\n\nReconcile users and groups between two PluggableAuthService plugins.\nUseful, for example, to migrate users and groups from the local\nstorage plugins to an LDAP plugin added later.\n\n#. The export steps search the destination plugins for users and\n groups that correspond to those in the source plugins. Use real\n names for search when an exact match on id can't be found.\n\n#. The export step writes a CSV file listing all users and groups from\n the source plugins including those that match exactly on id, those\n that found matches on real names, and those that found no matches.\n\n This CSV can be edited to add manual matches and can be used as a\n list of users to notify that their logins or passwords may change\n between the source and destination plugins.\n\n#. The import step reads the same CSV file to update:\n\n * OFS ownership\n * CMF creators\n * local roles\n * group memberships\n\nTo use these steps, make sure the destination PAS plugin is the first\nactivated IUserEnumerationPlugin, IGroupEnumerationPlugin, and\nIPropertiesPlugin plugin, then run the ``reconcile_users`` and\n``reconcile_groups`` export steps. The CSV files generated in the\nexport can then be edited and adjusted until they represent the\nchanges that should be applied at which point they can be placed\ninside a GS import profile and imported to apply the changes.\n\nUpgrade Steps\n-------------\n\nThis package also registers additional upgrade steps for the Plone 3.*\nto 4.0 upgrade which do the following:\n\n * cleanup broken OFS objects\n * cleanup broken TextIndexes objects\n * cleanup broken component registrations\n * cleanup broken setup registrations\n * cleanup broken cmfeditions versions\n * migrate cmfeditions folder versions to btrees\n * cleanup duplicate UIDs\n\nRegistered for the 3.* to 4.0 upgrade by default, these steps can be\nregistered for any upgrade you might need them for. If you find that\na particular Plone upgrade is helped by registering one of the\nexisting steps or a new step, let me know and I'll likely add it to\nthe registrations in this package.\n\nIncluding ``experimental.broken`` while running the upgrade steps for\ncleaning up broken objects is probably a better idea than not doing\nso. This will be included automatically if you require the\n``collective.upgrade [steps]`` extra.\n\nAn unregistered upgrade step function,\n``collective.upgrade.steps.setDefaultEditor``, can be registered in ZCML\nto set the default editor for all users. It requires\n``collective.setdefaulteditor`` which will be included automatically if\nyou require the ``collective.upgrade [steps]`` extra.\n\nHelper functions are also available in the ``collective.upgrade.steps``\nmodule. These helpers are all meant to be used when writing your own\nupgrades steps. See the ``collective.upgrade.steps`` source for\ndetails:\n\n * reset the site to the baseline GenericSetup profile plus default extensions\n * delete custom skin objects\n * cleanup missing skin/theme layers\n * uninstall add-ons\n * pack the ZODB pruning old revision history\n * BBB import/export steps for resource registries before the Plone 5 switch to\n using plone.app.registry\n\nChangelog\n=========\n\n\n1.5 (2019-05-06)\n----------------\n\n- Bugfix: Fix incremental commits when no source matches the first step.\n\n\n1.4 (2019-03-31)\n----------------\n\n- Bugfix: Fix upgrading all profiles, was running all upgrade steps for all\n profiles that had upgrade steps registered.\n [rpatterson]\n\n- Bugfix: Fix the Zope instance run script argument handling.\n [rpatterson]\n\n- Bugfix: portal_languages is no longer a persistent tool.\n See: https://docs.plone.org/manage/upgrading/version_specific_migration/p4x_to_p5x_upgrade.html#portal-languages-is-now-a-utility\n [bsuttor]\n\n\n1.3 (2018-04-18)\n----------------\n\n- Add zope global request to PortalUpgrader.\n [bsuttor]\n\n\n1.2 (2017-03-23)\n----------------\n\n- Add an upgrade step to reset the site to the baseline GenericSetup profile\n plus default extensions.\n [rpatterson]\n\n- BBB import/export steps for resource registries before the Plone 5 switch to\n using plone.app.registry.\n [rpatterson]\n\n- Added argument to define Zope user id to use.\n [gbastien]\n\n- Complete portal setup : portal_skins, portal_languages, BrowserLayer.\n [gbastien]\n\n\n1.1 - 2014-05-08\n----------------\n\n- Restore Python 2.6 compatibility.\n [rpatterson]\n\n\n1.0 - 2014-04-21\n----------------\n\n- Add an upgrade step for cooking the resource registries. Useful when\n encountering viewlet errors on the resource registry viewlets after an\n upgrade.\n [@rpatterson]\n\n\n1.0rc1 - 2014-04-08\n-------------------\n\n- Add options for controlling which profiles are upgraded.\n [@rpatterson]\n\n- Migrate from ``optparse`` to ``argparse`` and move portal paths from an\n option to a positional argument.\n [@rpatterson]\n\n- Add an upgrade step function that packs the ZODB.\n [@rpatterson]\n\n- Reduce dependencies by moving some into an 'steps' extras_require.\n [@rpatterson]\n\n- Fix a transaction error when the transaction note becomes too large.\n [@rpatterson]\n\n\n0.4 - 2014-02-28\n----------------\n\n- Fix an import step bug when installing a Plone site into a fresh Zope\n instance. Fixes #3. Thanks to @href for the report. [@rpatterson]\n\n\n0.3 - 2014-01-30\n----------------\n\n- Add export and import steps for reconciling users and groups between\n two PluggableAuthService plugins, such as between existing\n Plone-only users and a newly added LDAP plugin.\n [@rpatterson]\n\n- Support Plone 4.3, tolerate a deleted KSS tool\n [@rpatterson]\n\n\n0.2 - 2012-11-14\n----------------\n\n- Fix upgrading \"Products\" namespace profiles without previous version numbers\n [@rpatterson]\n\n- Fix upgrade step handling, was skipping steps\n [@rpatterson]\n\n- Fix duplicate UUID cleanup\n [@rpatterson]\n\n- Move broken object steps into a separate ZCML file, should be\n optional and used with care\n [@rpatterson]\n\n- Plone 4.2 compatibility\n [@rpatterson]\n\n\n0.1 - 2012-11-05\n----------------\n\n- Initial release.\n [@rpatterson]\n", "description_content_type": "", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "http://github.com/collective/collective.upgrade", "keywords": "Zope CMF Plone GenericSetup upgrade", "license": "GPL", "maintainer": "", "maintainer_email": "", "name": "collective.upgrade", "package_url": "https://pypi.org/project/collective.upgrade/", "platform": "", "project_url": "https://pypi.org/project/collective.upgrade/", "project_urls": { "Homepage": "http://github.com/collective/collective.upgrade" }, "release_url": "https://pypi.org/project/collective.upgrade/1.5/", "requires_dist": null, "requires_python": "", "summary": "CMF portal upgrade helpers", "version": "1.5" }, "last_serial": 5234231, "releases": { "0.1": [ { "comment_text": "", "digests": { "md5": "6cebdb5fad942378fa3ef46e48f54ddc", "sha256": "3af8190b08d76faac82bf01d72c70bc995883fafc3230c593a3a5a407631f8c4" }, "downloads": -1, "filename": "collective.upgrade-0.1.tar.gz", "has_sig": false, "md5_digest": "6cebdb5fad942378fa3ef46e48f54ddc", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 16288, "upload_time": "2012-11-05T15:03:37", "url": "https://files.pythonhosted.org/packages/a1/5b/6a20f5bef6927cf8ea57a750c11930964f86f632582973d4586382a4a6b3/collective.upgrade-0.1.tar.gz" } ], "0.2": [ { "comment_text": "", "digests": { "md5": "f52e54bab2a6656926ddad64dfdf4e91", "sha256": "3d97ec9105dc21df0a76c414ac74a8fd302cf5ff00a1c4eadcccdfafe77e82df" }, "downloads": -1, "filename": "collective.upgrade-0.2.tar.gz", "has_sig": false, "md5_digest": "f52e54bab2a6656926ddad64dfdf4e91", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 16605, "upload_time": "2012-11-15T01:45:05", "url": "https://files.pythonhosted.org/packages/39/8a/a3e7848928f6858135aa102227afa487094d1ab7eabba5634419a0b8d640/collective.upgrade-0.2.tar.gz" } ], "0.3": [ { "comment_text": "", "digests": { "md5": "ab454901b1c35cb964464207b28128f3", "sha256": "3e767b5df77b79cf0267d201014254ffda2aea5f31425452d810211430105713" }, "downloads": -1, "filename": "collective.upgrade-0.3.tar.gz", "has_sig": false, "md5_digest": "ab454901b1c35cb964464207b28128f3", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 24857, "upload_time": "2014-01-30T18:23:38", "url": "https://files.pythonhosted.org/packages/3e/d9/7cf026c44e2e92b28ffff8b8add6b56a69d7610fc3c2c46f9a181fdf11ca/collective.upgrade-0.3.tar.gz" } ], "0.4": [ { "comment_text": "", "digests": { "md5": "8f88497a700a07f04b041abab83dd622", "sha256": "3d377e1a2de35987d5e70822e36b1289de371160578276862453a6ac6e7ea867" }, "downloads": -1, "filename": "collective.upgrade-0.4.tar.gz", "has_sig": false, "md5_digest": "8f88497a700a07f04b041abab83dd622", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 25157, "upload_time": "2014-03-01T00:53:29", "url": "https://files.pythonhosted.org/packages/8d/be/36963101aedec25ad917eb65914ae0fce8c8f8cf2a8b78b6b178a28ca168/collective.upgrade-0.4.tar.gz" } ], "1.0": [ { "comment_text": "", "digests": { "md5": "96cd57786b0f7d00ec6d7eba2093c34e", "sha256": "060e05a75395fe9614e96fa246df6ddfddbcdb3f1a0022df5d540642faa51712" }, "downloads": -1, "filename": "collective.upgrade-1.0.zip", "has_sig": false, "md5_digest": "96cd57786b0f7d00ec6d7eba2093c34e", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 39994, "upload_time": "2014-04-21T08:40:35", "url": "https://files.pythonhosted.org/packages/08/b5/af97e07c0046ba08a3b5e887fb56c7c855801dac54459e352e48bf0dca18/collective.upgrade-1.0.zip" } ], "1.0rc1": [ { "comment_text": "", "digests": { "md5": "96922882d0149c832651c1343785673e", "sha256": "b29cd5365a6f2e98e25b797806355c167bc25f7487629e2de1fededa3a719384" }, "downloads": -1, "filename": "collective.upgrade-1.0rc1.tar.gz", "has_sig": false, "md5_digest": "96922882d0149c832651c1343785673e", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 26735, "upload_time": "2014-04-08T21:42:12", "url": "https://files.pythonhosted.org/packages/9a/a5/5b6873f1b7e0dd8b1436bf84b7835caba9f36419c2f5bc5f7f952e1e0664/collective.upgrade-1.0rc1.tar.gz" } ], "1.1": [ { "comment_text": "", "digests": { "md5": "fd991477f0d5ca9008ecb05b220dfd25", "sha256": "98b09a80799b2b7bdb46386804a2a1c2109221000b9b335fe702804895d231f2" }, "downloads": -1, "filename": "collective.upgrade-1.1.zip", "has_sig": false, "md5_digest": "fd991477f0d5ca9008ecb05b220dfd25", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 40163, "upload_time": "2014-05-08T18:49:06", "url": "https://files.pythonhosted.org/packages/d3/29/e36a4ef98f3ef592b67f5f0eab43cb766e6c1bac22973e4527698f0e707b/collective.upgrade-1.1.zip" } ], "1.2": [ { "comment_text": "", "digests": { "md5": "ca466572d16198aa592e5080f03dc2aa", "sha256": "c165c2945524eabf852aebdedcf8bcfca06ad89dfba1f135746958f4a083b6a3" }, "downloads": -1, "filename": "collective.upgrade-1.2.tar.gz", "has_sig": false, "md5_digest": "ca466572d16198aa592e5080f03dc2aa", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 32493, "upload_time": "2017-03-23T09:20:53", "url": "https://files.pythonhosted.org/packages/80/52/f94bd0654f08b2a35fa57bbfdf1c4e568f7a196ce2c5295c7991bfc5a426/collective.upgrade-1.2.tar.gz" } ], "1.3": [ { "comment_text": "", "digests": { "md5": "9ecd80ec06f894235bd38b8d277e8aaf", "sha256": "b403175dba73eb07615c7f91e8fd9cc0ea57865bda73b7c5cf9f77320b1621b7" }, "downloads": -1, "filename": "collective.upgrade-1.3.tar.gz", "has_sig": false, "md5_digest": "9ecd80ec06f894235bd38b8d277e8aaf", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 32581, "upload_time": "2018-04-18T14:31:53", "url": "https://files.pythonhosted.org/packages/5a/7e/80c18f97e4360a3a51d4e70eeb4af1adff4ab483368cc95b224ce4981200/collective.upgrade-1.3.tar.gz" } ], "1.4": [ { "comment_text": "", "digests": { "md5": "fbdf53f53c25077cdc258894ac5190b6", "sha256": "fd58e2a11246e76d10ce4bb487ec35f7b06e00766c999d41b57593020dc443d1" }, "downloads": -1, "filename": "collective.upgrade-1.4-py2-none-any.whl", "has_sig": false, "md5_digest": "fbdf53f53c25077cdc258894ac5190b6", "packagetype": "bdist_wheel", "python_version": "2.7", "requires_python": null, "size": 42683, "upload_time": "2019-04-11T18:23:42", "url": "https://files.pythonhosted.org/packages/a1/e1/e2555979ab597119e9598c4403bcbd5d0c7a808f686baaf91dde37a87731/collective.upgrade-1.4-py2-none-any.whl" }, { "comment_text": "", "digests": { "md5": "6e3614cc3a6c2e33f16a8ad52b24e657", "sha256": "c3144e77d21fcc57f184fdedca5215a3bbbf4e73a915536ae39c9dd74e13cac6" }, "downloads": -1, "filename": "collective.upgrade-1.4.tar.gz", "has_sig": false, "md5_digest": "6e3614cc3a6c2e33f16a8ad52b24e657", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 36529, "upload_time": "2019-04-11T18:23:40", "url": "https://files.pythonhosted.org/packages/05/78/e776635381905f16247415796d6df7c8dcb5b9c2a0cebd29f7c9c6585449/collective.upgrade-1.4.tar.gz" } ], "1.5": [ { "comment_text": "", "digests": { "md5": "9efd9dc741382092726e4b27da1b9a7d", "sha256": "525712b4ac15ac21e764d523e7309f5381fa24f4b87a1c4ffd9b05b2022d5c77" }, "downloads": -1, "filename": "collective.upgrade-1.5-py2-none-any.whl", "has_sig": false, "md5_digest": "9efd9dc741382092726e4b27da1b9a7d", "packagetype": "bdist_wheel", "python_version": "2.7", "requires_python": null, "size": 42673, "upload_time": "2019-05-06T18:12:34", "url": "https://files.pythonhosted.org/packages/ba/46/621efb54aba055b0b1423d1795557fbe826cb139fdede7a950e178151ac3/collective.upgrade-1.5-py2-none-any.whl" }, { "comment_text": "", "digests": { "md5": "b0c795fd19ec58e6cde86abe1d0e1a40", "sha256": "9b6ce189396a530f7c67ee366e43f52d0713498859e3bc879eceb7083606cc03" }, "downloads": -1, "filename": "collective.upgrade-1.5.tar.gz", "has_sig": false, "md5_digest": "b0c795fd19ec58e6cde86abe1d0e1a40", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 36985, "upload_time": "2019-05-06T18:12:33", "url": "https://files.pythonhosted.org/packages/93/62/424d2c615453979d5fff8a51398630c64d7d1d9dfb85510d8f3ff5edf819/collective.upgrade-1.5.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "9efd9dc741382092726e4b27da1b9a7d", "sha256": "525712b4ac15ac21e764d523e7309f5381fa24f4b87a1c4ffd9b05b2022d5c77" }, "downloads": -1, "filename": "collective.upgrade-1.5-py2-none-any.whl", "has_sig": false, "md5_digest": "9efd9dc741382092726e4b27da1b9a7d", "packagetype": "bdist_wheel", "python_version": "2.7", "requires_python": null, "size": 42673, "upload_time": "2019-05-06T18:12:34", "url": "https://files.pythonhosted.org/packages/ba/46/621efb54aba055b0b1423d1795557fbe826cb139fdede7a950e178151ac3/collective.upgrade-1.5-py2-none-any.whl" }, { "comment_text": "", "digests": { "md5": "b0c795fd19ec58e6cde86abe1d0e1a40", "sha256": "9b6ce189396a530f7c67ee366e43f52d0713498859e3bc879eceb7083606cc03" }, "downloads": -1, "filename": "collective.upgrade-1.5.tar.gz", "has_sig": false, "md5_digest": "b0c795fd19ec58e6cde86abe1d0e1a40", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 36985, "upload_time": "2019-05-06T18:12:33", "url": "https://files.pythonhosted.org/packages/93/62/424d2c615453979d5fff8a51398630c64d7d1d9dfb85510d8f3ff5edf819/collective.upgrade-1.5.tar.gz" } ] }