posit-dev / posit-dev/rsconnect-python
`RSConnectExecutor.server_settings` throws error if `self.client` is a `PositClient` object
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 37
- Forks
- 28
- Avg merge
- 1d 3h
- Merged PRs (30d)
- 7
Description
With a RSConnectExecutor object, if .server_settings is accessed and self.client is a PositClient object (as opposed to a RSConnectClient object), it will throw an error.
I'm running into this problem while working on #545, when I try to deploy a Shiny app to shinyapps.io.
The problem is that the server_settings property accesses self.client.server_settings. self.client can be a RSConnectClient or PositClient object. However, the PositClient class does not have .server_settings.
Maybe the PositClient class could have a .server_settings field, set to None or an empty dictionary?
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 rsconnect/api.py at the server_settings property around lines 916–919, then inspect how RSConnectExecutor uses self.client and compare the RSConnectClient and PositClient classes. The fix is done when accessing server_settings with either client type no longer raises an attribute error and existing RSConnectClient behavior remains intact.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- api, cli
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 50/100