# Cannot import role to galaxy

**URL:** <https://forum.ansible.com/t/cannot-import-role-to-galaxy/8127>\
**Category:** Get Help\
**Tags:** galaxy-ng\
**Created:** [August 28, 2024, 8:13am UTC](https://forum.ansible.com/t/cannot-import-role-to-galaxy/8127 "2024-08-28T08:13:28Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![HanXHX](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/hanxhx/32/4589_2.png) [@HanXHX](https://forum.ansible.com/u/HanXHX)\
**Post date:** [August 28, 2024, 8:13am UTC](https://forum.ansible.com/t/cannot-import-role-to-galaxy/8127/1 "2024-08-28T08:13:28Z")

</div>

Hi,

I wanted to release on galaxy a new version of a legacy ansible role ([GitHub - HanXHX/ansible-mysql: Ansible role for Debian : MariaDB (Galera Cluster as option)](https://github.com/HanXHX/ansible-mysql)).

I always have a 403 error.

I tried:

- On `meta/main.yml`: Rename my previous namespace (from `hanxhx` to my real Github user name `HanXHX`)
- On `meta/main.yml`: remove `namespace`
- Force alternate branch on `ansible-galaxy role import`
- I regened an API key ([Ansible Galaxy](https://galaxy.ansible.com/ui/token/))
- Alternate Ansible versions…

Example:

```commandline
$ ansible-galaxy role import --api-key **** HanXHX ansible-mysql --branch fix_galaxy -vvvv
ansible-galaxy [core 2.17.3]
  config file = None
  configured module search path = ['/home/triplestack/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']
  ansible python module location = /home/triplestack/dev/PERSO/ansible-mysql/venv/lib/python3.10/site-packages/ansible
  ansible collection location = /home/triplestack/.ansible/collections:/usr/share/ansible/collections
  executable location = /home/triplestack/dev/PERSO/ansible-mysql/venv/bin/ansible-galaxy
  python version = 3.10.12 (main, Nov 20 2023, 15:14:05) [GCC 11.4.0] (/home/triplestack/dev/PERSO/ansible-mysql/venv/bin/python)
  jinja version = 3.1.4
  libyaml = True
No config file found; using defaults
Initial connection to galaxy_server: https://galaxy.ansible.com
Opened /home/triplestack/.ansible/galaxy_token
Calling Galaxy at https://galaxy.ansible.com/api/
Found API version 'v3, pulp-v3, v1' with Galaxy server default (https://galaxy.ansible.com/api/)
Calling Galaxy at https://galaxy.ansible.com/api/v1/imports/
ERROR! None (HTTP Code: 403, Message: Forbidden)

```

Issue with my Ansible Galaxy account?

Best,

Emilien

---

<div class="post-metadata">

**Author:** ![HanXHX](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/hanxhx/32/4589_2.png) [@HanXHX](https://forum.ansible.com/u/HanXHX)\
**Post date:** [August 28, 2024, 12:43pm UTC](https://forum.ansible.com/t/cannot-import-role-to-galaxy/8127/2 "2024-08-28T12:43:00Z")

</div>

In “my namespace” page, I only have `hanxhx0`… I never use this namespace…

→ [Ansible Galaxy](https://galaxy.ansible.com/ui/namespaces/hanxhx0/)

With my nickname i can see 2 namespaces: [Ansible Galaxy](https://galaxy.ansible.com/ui/namespaces/?page_size=20&sort=name&keywords=hanxhx&page=1)

Anyone can fix my account please?

---

<div class="post-metadata">

**Author:** ![HanXHX](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/hanxhx/32/4589_2.png) [@HanXHX](https://forum.ansible.com/u/HanXHX)\
**Post date:** [August 29, 2024, 3:27pm UTC](https://forum.ansible.com/t/cannot-import-role-to-galaxy/8127/3 "2024-08-29T15:27:50Z")

</div>

Any help please?

Thanks!

---

<div class="post-metadata">

**Author:** ![HanXHX](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/hanxhx/32/4589_2.png) [@HanXHX](https://forum.ansible.com/u/HanXHX)\
**Post date:** [October 15, 2024, 1:08pm UTC](https://forum.ansible.com/t/cannot-import-role-to-galaxy/8127/4 "2024-10-15T13:08:59Z")

</div>

Up? Can you help me please?

---

<div class="post-metadata">

**Author:** ![TKeller](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/tkeller/32/5215_2.png) [@TKeller](https://forum.ansible.com/u/TKeller)\
**Post date:** [October 21, 2024, 2:30pm UTC](https://forum.ansible.com/t/cannot-import-role-to-galaxy/8127/5 "2024-10-21T14:30:39Z")

</div>

Good evening,

We have made you the collection owner for that namespace. Please try again now.
