AttributeError: Axes object has no attribute 'add_tick_labels'

%%manim -ql -v WARNING FourierSeriesScene

from manim import *

class FourierSeriesScene(Scene):
    def construct(self):
        # ------------------------------
        # 1. Title
        # ------------------------------
        title = Text("Fourier Series Approximation of a Square Wave", font_size=36)
        self.play(Write(title))
        self.wait(1)
        self.play(FadeOut(title))
        
        # ------------------------------
        # 2. Axes Configuration
        # ------------------------------
        axes = Axes(
            x_range=(-PI, PI, PI/2),
            y_range=(-1.5, 1.5, 0.5),
            x_length=10,
            y_length=4,
            axis_config={"color": WHITE},
        ).to_edge(DOWN)
        
        # Add axis labels
        axes_labels = axes.get_axis_labels(x_label="x", y_label="f(x)")
        
        # Add tick labels using 'add_tick_labels()' method
        axes.add_tick_labels(font_size=10)
        
        # Display axes and labels
        self.play(Create(axes), Write(axes_labels))
        
        # ------------------------------
        # 3. Target Square Wave
        # ------------------------------
        def square_wave(x):
            return 1 if x > 0 else -1

        square_wave_graph = axes.get_graph(
            lambda x: square_wave(x),
            discontinuities=[0],
            color=YELLOW
        )
        square_wave_label = axes.get_graph_label(
            square_wave_graph, label="\\text{Square Wave}", x_val=PI, direction=UR
        )
        self.play(Create(square_wave_graph), Write(square_wave_label))
        
        self.wait(1)
        
        # ------------------------------
        # 4. Fourier Series Initialization
        # ------------------------------
        fourier_series = VMobject()
        fourier_series.set_color(BLUE)
        fourier_series.set_stroke(width=2)
        
        self.add(fourier_series)
        
        # ------------------------------
        # 5. Fourier Series Construction
        # ------------------------------
        num_harmonics = 9  # Number of harmonics to include (only odds)
        harmonics = []
        
        # Initial Fourier Series (zero function)
        fourier_sum = axes.get_graph(lambda x: 0, color=BLUE)
        self.play(Transform(fourier_series, fourier_sum))
        
        for n in range(1, num_harmonics + 1, 2):  # Only odd harmonics
            # Coefficient for nth harmonic
            coeff = (4) / (n * PI)
            
            # Define the current harmonic function
            harmonic = axes.get_graph(
                lambda x, n=n: coeff * np.sin(n * x),
                color=BLUE
            )
            harmonics.append(harmonic)
            
            # Calculate the current sum of harmonics
            fourier_sum = axes.get_graph(
                lambda x, harmonics=harmonics: sum(
                    (4/(k * PI)) * np.sin(k * x) for k in range(1, len(harmonics)*2, 2)
                ),
                color=BLUE
            )
            
            # Update the Fourier series by adding the new harmonic
            self.play(Create(harmonic), run_time=1)
            self.play(Transform(fourier_series, fourier_sum), run_time=1)
            self.wait(0.5)
        
        # ------------------------------
        # 6. Final Wait and Cleanup
        # ------------------------------
        self.wait(2)
        
        # Clean Up
        self.play(FadeOut(VGroup(axes, axes_labels, square_wave_graph, square_wave_label, fourier_series)))