Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

client/cdn: manifest returns dict, gid is a key #461

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
StalkR wants to merge 1 commit into ValvePython:master from StalkR:fix-get_manifests
Closed

client/cdn: manifest returns dict, gid is a key #461

StalkR wants to merge 1 commit into ValvePython:master from StalkR:fix-get_manifests

Conversation

@StalkR
Copy link

@StalkR StalkR commented Apr 25, 2024

Hello,

I got an exception on get_manifests:

from steam.client import SteamClient
from steam.client.cdn import CDNClient
s = SteamClient()
s.anonymous_login()
cdn = CDNClient(s)
cdn.get_manifests(730)
Traceback (most recent call last):
 File "/usr/local/lib/python3.9/dist-packages/steam/client/cdn.py", line 785, in async_fetch_manifest
 app_id, depot_id, int(manifest_gid), branch_name, branch_pass
TypeError: int() argument must be a string, a bytes-like object or a number, not 'dict'

It's because the manifest object is a dict (I suppose steam must have changed it):

from steam.client import SteamClient
from steam.client.cdn import CDNClient
s = SteamClient()
s.anonymous_login()
cdn = CDNClient(s)
depot_info = cdn.get_app_depot_info(730)
print(depot_info[str(2347770)]['manifests']['public'])
{'gid': '2869365522094710973', 'size': '35004749517', 'download': '28894554320'}

This pull requests fixes it by adding .get('gid') in the relevant code.

Thanks for the project and library! I started using it and I like the API, very short, intuitive, easier to play with than SteamKit/C#.

Copy link
Author

StalkR commented Apr 25, 2024

I now see this was reported in 2023 as #436 and there's already a PR (#437) for it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

No reviews

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

1 participant

AltStyle によって変換されたページ (->オリジナル) /