st2client calls `.lower()` on url path, causing name resolution issues in a docker environment
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 6.5k
- Forks
- 787
- PR merge metrics
- No merged PRs in 30d
Description
SUMMARY
If the stackstorm client is given the hostname stackstorm-TRSTRUTH, it will attempt to make requests to stackstorm-trstruth/api/v1 which in turn causes a resolution error. I believe it is due to this line:
https://github.com/StackStorm/st2/blob/d17bf7e945168b87ba6f3c154fb272c7822531e8/st2client/st2client/models/core.py#L119
not sure if this is deliberate, but might we consider removing .lower() from that return statement?
ISSUE TYPE
Pick one below and delete the rest:
- Bug Report
STACKSTORM VERSION
Paste the output of st2 --version:
st2 3.0.1, on Python 2.7.6
OS / ENVIRONMENT / INSTALL METHOD
Docker mppc
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in st2client/st2client/models/core.py at the linked line and inspect how the URL path is assembled. Reproduce the request with the Docker hostname stackstorm-TRSTRUTH, then verify the behavior around case preservation and name resolution; done means the reported resolution issue is addressed without breaking URL construction.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- cli, networking
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100