Skip to content

Commit 410e57c

Browse files
committed
[GR-66402] GraalPy compatibility page update.
PullRequest: graalpython/3815
2 parents 3546a2e + cfe80aa commit 410e57c

File tree

13 files changed

+707
-281
lines changed

13 files changed

+707
-281
lines changed

docs/site/03-compatibility.md

Lines changed: 302 additions & 21 deletions
Large diffs are not rendered by default.

docs/site/_config.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
baseurl: "/python"
22
url: "https://graalvm.org"
33
github: "oracle/graalpython"
4-
language_version: 24.2.0
4+
language_version: 24.2.1
55
name: GraalPy
66

77
permalink: pretty

docs/site/_plugins/wheel_repo_plugin.rb

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
# frozen_string_literal: true
22

3+
require "set"
4+
35
# Plugin that generates a Python repository index for GraalPy wheels at
46
# /python/wheels. The input is the graalpy_wheels.txt file next to this file.
57
# The wheels themselves are hosted in GDS.
@@ -50,6 +52,38 @@ def generate(site)
5052
package_page.content = render package_links
5153
site.pages << package_page
5254
end
55+
56+
graalpy_versions = all_wheels.group_by do |wheel|
57+
wheel.filename =~ /graalpy(\d\d\d?)_/
58+
$1
59+
end
60+
graalpy_versions.each do |version, wheels|
61+
package_csv = Jekyll::PageWithoutAFile.new(site, "", "/wheels/", "v#{version}.csv")
62+
package_csv.content = wheels.group_by(&:name).map do |name, wheels|
63+
wheels.group_by { |w| w.filename.split("-")[1] }.map do |version, wheels|
64+
comment = "The GraalPy team provides binary wheels of this package for "
65+
platforms = wheels.map do |wheel|
66+
parts = wheel.filename.split("-")
67+
if parts.any? { |p| p.include? "linux" }
68+
"Linux"
69+
elsif parts.any? { |p| p.include? "win" }
70+
"Windows"
71+
elsif parts.any? { |p| p.include? "macos" }
72+
"macOS"
73+
end
74+
end.sort.compact
75+
if platforms.length == 1
76+
comment += "#{platforms.first}."
77+
elsif platforms.length == 2
78+
comment += "#{platforms.first} and #{platforms.last}."
79+
else
80+
comment += "#{platforms[0]}, #{platforms[1]}, and #{platforms[2]}."
81+
end
82+
"#{name},#{version},0,#{comment}"
83+
end
84+
end.flatten.join("\n")
85+
site.pages << package_csv
86+
end
5387
end
5488

5589
def render(links)
Lines changed: 4 additions & 0 deletions
Loading

docs/site/assets/img/python/huggingface.svg

Lines changed: 8 additions & 0 deletions
Loading

docs/site/assets/img/python/numpy.svg

Lines changed: 1 addition & 0 deletions
Loading
Lines changed: 111 additions & 0 deletions
Loading
Lines changed: 12 additions & 0 deletions
Loading

docs/site/assets/img/python/scipy.svg

Lines changed: 137 additions & 0 deletions
Loading

0 commit comments

Comments
 (0)