{"id":21385,"library":"github-heatmap","title":"GitHub Heatmap","description":"Generate SVG heatmaps and skyline visualizations for GitHub-like contribution graphs. Version 2.3.0 is the latest. Active development with frequent releases.","status":"active","version":"2.3.0","language":"python","source_language":"en","source_url":"https://github.com/malinkang/GitHubPoster","tags":["github","heatmap","svg","contribution-graph","visualization"],"install":[{"cmd":"pip install github-heatmap","lang":"bash","label":"Install from PyPI"}],"dependencies":[],"imports":[{"note":"Class name is 'GitHubPoster', not 'Poster' or 'Heatmap'.","wrong":"from github_heatmap import Poster","symbol":"GitHubPoster","correct":"from github_heatmap import GitHubPoster"}],"quickstart":{"code":"import os\nfrom github_heatmap import GitHubPoster\n\nposter = GitHubPoster(token=os.environ.get('GITHUB_TOKEN', ''))\nposter.run(username='example_user', year=2023)\nwith open('output.svg', 'rb') as f:\n    print(f.read()[:100])","lang":"python","description":"Initialize with a GitHub token, generate a heatmap SVG for a given user and year."},"warnings":[{"fix":"Generate a token with scopes: repo, user. Or use a fine-grained token with 'public_repo' access for public repos.","message":"The GitHub token must have the 'repo' and 'user' scopes. Using a token without the correct scopes will result in a 403 or empty output.","severity":"gotcha","affected_versions":"all"},{"fix":"Update imports: 'from github_heatmap import GitHubPoster'. Pass 'year=2023' instead of 'years=[2023]'.","message":"Version 2.x changed the API: the main class is now 'GitHubPoster' instead of 'Poster'. The 'run' method now accepts 'year' as integer (not 'years' list).","severity":"breaking","affected_versions":">=2.0.0"},{"fix":"Remove the 'mode' parameter from the constructor or run() call.","message":"The 'mode' parameter (e.g., 'mode=github') is deprecated. Version 2.3.0 auto-detects the platform.","severity":"deprecated","affected_versions":">=2.3.0"}],"env_vars":null,"last_verified":"2026-04-27T00:00:00.000Z","next_check":"2026-07-26T00:00:00.000Z","problems":[{"fix":"Install the package: pip install github-heatmap. Then import as: from github_heatmap import GitHubPoster","cause":"The package is installed with a hyphen but imported with an underscore. Some users mistakenly import 'github-heatmap'.","error":"ModuleNotFoundError: No module named 'github_heatmap'"},{"fix":"Upgrade to version 2.x and update code: from github_heatmap import GitHubPoster; poster = GitHubPoster(...); poster.run(...)","cause":"Using the old API from version 1.x where the class was 'Poster' and method was 'make'.","error":"AttributeError: 'GitHubPoster' object has no attribute 'run'"},{"fix":"Poster.run(username='example', year=2023) # single integer, not [2023]","cause":"Passing a list or string instead of an integer for the 'year' argument in run().","error":"ValueError: year must be an integer"}],"ecosystem":"pypi","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}