Problems with A* Pathfinding

I’m trying to learn unity and I’m using A* to have an enemy path find to a player. I believe most of the code is working as unity shows that it is finding a path towards the player but the enemy won’t move toward it.

Here is my code:

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using Pathfinding;

public class Enemy : MonoBehaviour
{
    [Header("Pathfinding")]
    public Transform target;
    public float activateDistance = 1f;
    public float pathUpdateSeconds = 1f;

    [Header("Physics")]
    public float speed = 1f;
    public float nextWaypointDistance = 1f;
    public float jumpNodeHeightRequirement = 1f;
    public float jumpModifier = 1f;
    public float jumpCheckOffset = 1f;

    [Header("CustomBehavior")]
    public bool followEnabled = true;
    public bool jumpEnabled = true;
    public bool directionLookEnabled = true;

    private Path path;
    private int currentWaypoint = 0;
    private bool isGrounded = false;
    Seeker seeker;
    Rigidbody2D rb;

    public void Start()
    {
        seeker = GetComponent<Seeker>();
        rb = GetComponent<Rigidbody2D>();

        InvokeRepeating("UpdatePath", 0f, pathUpdateSeconds);
    }

    private void FixedUpdate()
    {
        if (TargetInDistance() && followEnabled)
        {
            PathFollow();
        }
    }

    private void UpdatePath()
    {
        if (followEnabled && TargetInDistance() && seeker.IsDone())
        {
            seeker.StartPath(rb.position, target.position, OnPathComplete);
        }
    }

    private void PathFollow()
    {
        if (path == null)
        {
            return;
        }

        if (currentWaypoint >= path.vectorPath.Count)
        {
            return;
        }

        isGrounded = Physics2D.Raycast(transform.position, -Vector3.up, GetComponent<Collider2D>().bounds.extents.y + jumpCheckOffset);

        Vector2 direction = ((Vector2)path.vectorPath[currentWaypoint] - rb.position).normalized;
        Vector2 force = direction * speed * Time.deltaTime;

        if (jumpEnabled && isGrounded)
        {
            if (direction.y > jumpNodeHeightRequirement)
            {
                rb.AddForce(Vector2.up * speed * jumpModifier);
            }
        }

        rb.AddForce(force);

        float distance = Vector2.Distance(rb.position, path.vectorPath[currentWaypoint]);
        if (distance < nextWaypointDistance)
        {
            currentWaypoint++;
        }
    }

    private bool TargetInDistance()
    {
        return Vector2.Distance(transform.position, target.transform.position) < activateDistance;
    }

    private void OnPathComplete(Path p)
    {
        if (p.error)
        {
            path = p;
            currentWaypoint = 0;
        }
    }
}

Have you tried to play around with speed? Increase by a lot (e.g. by 100) and see if it makes a difference. Maybe it moves but very very slow so it’s not really visible, the code seems fine to me

yes I did but it didn’t move at all, I also tried changing the activation range but it didn’t work.

I can put the link to the vid i was watching