Skip to content
Open
Show file tree
Hide file tree
Changes from 2 commits
Commits
Show all changes
40 commits
Select commit Hold shift + click to select a range
ff6a817
Deprecation for deprecated fucntions
RohitP2005 Jan 16, 2025
7f34a0b
style: pre-commit fixes
pre-commit-ci[bot] Jan 16, 2025
3da7140
Merge branch 'pybamm-team:develop' into issue#2028
RohitP2005 Feb 2, 2025
3a15fe8
Removed previous deprecation warnings
RohitP2005 Feb 2, 2025
9c500b5
Merge branch 'pybamm-team:develop' into issue#2028
RohitP2005 Feb 3, 2025
949571b
Added -W flag to pytest
RohitP2005 Feb 3, 2025
3f327cb
Custom decorator added and filterwarningn adjusted
RohitP2005 Feb 4, 2025
9d29350
Merge branch 'develop' into issue#2028
RohitP2005 Feb 5, 2025
1eb61a0
setuptools fix
RohitP2005 Feb 10, 2025
47051ab
Merge branch 'develop' into issue#2028
RohitP2005 Feb 10, 2025
e57a1fd
using agriyakhetarpal's approach to ignore external warnings
RohitP2005 Feb 13, 2025
dba1881
Merge branch 'develop' into issue#2028
RohitP2005 Feb 13, 2025
c48ed38
Merge branch 'pybamm-team:develop' into issue#2028
RohitP2005 Feb 14, 2025
b91e9ce
Update pyproject.toml
RohitP2005 Feb 15, 2025
c564c87
moving deprecation decorator to uitl.py
RohitP2005 Feb 14, 2025
52e610b
Merge branch 'develop' into issue#2028
RohitP2005 Feb 20, 2025
a4025a1
style: pre-commit fixes
pre-commit-ci[bot] Feb 20, 2025
33ff787
Moved decorators to utils and corrected pytest config
RohitP2005 Feb 20, 2025
9d9c1bf
Added msg parameter in deprecation decorator
RohitP2005 Feb 20, 2025
139704c
Applied decorators to necessary functions
RohitP2005 Feb 20, 2025
808d5cd
Corrected imports for utils
RohitP2005 Feb 20, 2025
28f5397
Update pyproject.toml
RohitP2005 Feb 20, 2025
a703eca
Update pyproject.toml
RohitP2005 Feb 20, 2025
8784b35
removed old deprecation warningsdfasf
RohitP2005 Feb 20, 2025
7902c43
deprecation Decorator accepts msg as a dictionary
RohitP2005 Feb 20, 2025
eaf0994
Merge branch 'develop' into issue#2028
arjxn-py Feb 22, 2025
930190b
Update pyproject.toml
RohitP2005 Mar 13, 2025
6c76623
Merge branch 'develop' into issue#2028
RohitP2005 Mar 13, 2025
422029a
fixed deprecated tests
RohitP2005 Mar 26, 2025
6e2eb5a
Merge branch 'pybamm-team:develop' into issue#2028
RohitP2005 Apr 9, 2025
840b696
test coverage for deprecate warnings
RohitP2005 Apr 9, 2025
194c657
Added _set_paramters function in the test
RohitP2005 Apr 9, 2025
41e58e3
Merge branch 'develop' into issue#2028
RohitP2005 Apr 10, 2025
a565419
Unit test fixed
RohitP2005 Apr 12, 2025
0bf9abf
doctests fix
RohitP2005 Apr 12, 2025
6a63a05
Updated setuptools version
RohitP2005 Apr 13, 2025
444cf08
Merge branch 'develop' into issue#2028
RohitP2005 Apr 13, 2025
6db0714
Merge branch 'pybamm-team:develop' into issue#2028
RohitP2005 Apr 18, 2025
2e8d684
added test auxiliary domains
RohitP2005 Apr 15, 2025
71a5197
Merge branch 'pybamm-team:develop' into issue#2028
RohitP2005 May 6, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ dependencies = [
"posthog",
"pyyaml",
"platformdirs",
"deprecation"
]

[project.urls]
Expand Down
13 changes: 13 additions & 0 deletions src/pybamm/expression_tree/symbol.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
import pybamm
from pybamm.util import import_optional_dependency
from pybamm.expression_tree.printing.print_name import prettify_print_name
from deprecation import deprecated

if TYPE_CHECKING: # pragma: no cover
import casadi
Expand Down Expand Up @@ -356,6 +357,12 @@ def domain(self, domain):
)

@property
@deprecated(
deprecated_in="25.1.0",
removed_in="26.0.0",
current_version=pybamm.__version__,
details="Use `symbol.domains` instead.",
)
def auxiliary_domains(self):
"""Returns auxiliary domains."""
raise NotImplementedError(
Expand Down Expand Up @@ -994,6 +1001,12 @@ def create_copy(
children = self._children_for_copying(new_children)
return self.__class__(self.name, children, domains=self.domains)

@deprecated(
deprecated_in="25.1.0",
removed_in="26.0.0",
current_version=pybamm.__version__,
details="Use `create_copy` instead.",
)
def new_copy(
self,
new_children: list[Symbol] | None = None,
Expand Down
14 changes: 13 additions & 1 deletion src/pybamm/simulation.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
from datetime import timedelta
import pybamm.telemetry
from pybamm.util import import_optional_dependency

from deprecation import deprecated
from pybamm.expression_tree.operations.serialise import Serialise


Expand Down Expand Up @@ -171,6 +171,12 @@ def _set_random_seed(self):
% (2**32)
)

@deprecated(
deprecated_in="25.1.0",
removed_in="26.0.0",
current_version=pybamm.__version__,
details="pybamm.simulation.set_up_and_parameterise_experiment is deprecated and not meant to be accessed by users.",
)
def set_up_and_parameterise_experiment(self, solve_kwargs=None):
msg = "pybamm.simulation.set_up_and_parameterise_experiment is deprecated and not meant to be accessed by users."
warnings.warn(msg, DeprecationWarning, stacklevel=2)
Expand Down Expand Up @@ -254,6 +260,12 @@ def _set_up_and_parameterise_experiment(self, solve_kwargs=None):
parameterised_model
)

@deprecated(
deprecated_in="25.1.0",
removed_in="26.0.0",
current_version=pybamm.__version__,
details="pybamm.set_parameters is deprecated and not meant to be accessed by users.",
)
def set_parameters(self):
msg = (
"pybamm.set_parameters is deprecated and not meant to be accessed by users."
Expand Down
Loading