digitalocean / digitalocean/doctl

Get droplet by name does not work in the case your name is a number

Open
#1,087 1 comment 1 reaction 0 assignees View on GitHub
bug
Dominant language
Go
Stars
3.4k
Forks
496
Avg merge
1d 2h
Merged PRs (30d)
31

Description

**Describe the Issue:**

1. Create a new droplet with a name that contains only numbers (e.g.: 123456)
2. Try to get this droplet using `doctl compute droplet get 123456`
3. Notice that you will get a 404 even though the get is supposed to retrieve results by name as well

**Environment:**
- doctl version: doctl version 1.69.0-release
- OS: Ubuntu 20.04
- Installation method: Snap package

**Additional Details:**

I guess that if the get endpoint sees a number, it will try to get it by ID but will omit to try to get it by name as well.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.