OnTriggerEnter2D works sometimes and also double registers

Im a beginner at game development and i have just made som small projects in unity. Im trying to learn more by creating simpler games so i decided to create my own twist of flappy bird. But while working on it i stumbled upon a problem with the OnTriggerEnter2D registration. I have looked around the internet for solutions but i havent found one.

So i have a player with the script attached. The player has Rigidbody2D and a BoxCollider2D. The pipe is a group of the upper and lower pipe and with an empty object holding another BoxCollider2D used for adding points. Now here’s the problem when I play the game it sometimes registrates 1 point sometimes 2. No Points at all or the points can also be added when i have already passed the pipe. The thing is that ive used a debug to see if it registrates the trigger and ive noticed that it is not registrating. That was ofcourse expected because of the score not going up. Sometimes it does and sometimes not.

Does anyone have a clue what could be wrong?

Following is the code inside the player that handels collisions

void OnTriggerEnter2D(Collider2D collision)

    //if the player collides with the grow PowerUp
    if(collision.name == "GrowPowerUp")
    ScoreText.text = "" + Score;

    //If the player pass through the scorebox
    if (collision.name == "Score")
        Score += 1;
        Debug.Log("+1 Point");