MCPcopy
hub / github.com/scrapy/scrapy / copy

Method copy

scrapy/settings/__init__.py:620–630  ·  view source on GitHub ↗

Make a deep copy of current settings. This method returns a new instance of the :class:`Settings` class, populated with the same values and their priorities. Modifications to the new object won't be reflected on the original settings.

(self)

Source from the content-addressed store, hash-verified

618 raise TypeError("Trying to modify an immutable Settings object")
619
620 def copy(self) -> Self:
621 """
622 Make a deep copy of current settings.
623
624 This method returns a new instance of the :class:`Settings` class,
625 populated with the same values and their priorities.
626
627 Modifications to the new object won't be reflected on the original
628 settings.
629 """
630 return copy.deepcopy(self)
631
632 def freeze(self) -> None:
633 """

Callers 3

frozencopyMethod · 0.95
copy_to_dictMethod · 0.95
_compile_rulesMethod · 0.45

Calls 1

deepcopyMethod · 0.80

Tested by

no test coverage detected