File tree Expand file tree Collapse file tree 3 files changed +8
-3
lines changed
Expand file tree Collapse file tree 3 files changed +8
-3
lines changed Original file line number Diff line number Diff line change 1+ Replace `pkg_resources` with `importlib.metadata` @gforcada
Original file line number Diff line number Diff line change 1+ [build-system ]
2+ requires = [" setuptools>=68.2,<75.8.0" ]
3+
14[tool .towncrier ]
25filename = " CHANGES.rst"
36directory = " news/"
Original file line number Diff line number Diff line change 11# -*- coding: utf-8 -*-
22from importlib import import_module
3+ from importlib .metadata import distribution
4+ from importlib .metadata import PackageNotFoundError
35from plone import api
46from plone .dexterity .interfaces import IDexterityFTI
57from plone .volto .bbb import get_installer
1315
1416import json
1517import logging
16- import pkg_resources
1718import transaction
1819
1920
2021try :
21- pkg_resources . get_distribution ("plone.app.multilingual" )
22+ distribution ("plone.app.multilingual" )
2223 from plone .app .multilingual .browser .setup import SetupMultilingualSite
2324 from plone .app .multilingual .setuphandlers import enable_translatable_behavior
2425
2526 HAS_MULTILINGUAL = True
26- except pkg_resources . DistributionNotFound :
27+ except PackageNotFoundError :
2728 HAS_MULTILINGUAL = False
2829
2930PLONE_6 = getattr (import_module ("Products.CMFPlone.factory" ), "PLONE60MARKER" , False )
You can’t perform that action at this time.
0 commit comments