1 |
Signed-off-by: Michał Górny <mgorny@g.o> |
2 |
--- |
3 |
.../2021-04-29-python3-9.en.txt | 92 +++++++++++++++++++ |
4 |
1 file changed, 92 insertions(+) |
5 |
create mode 100644 2021-04-29-python3-9/2021-04-29-python3-9.en.txt |
6 |
|
7 |
diff --git a/2021-04-29-python3-9/2021-04-29-python3-9.en.txt b/2021-04-29-python3-9/2021-04-29-python3-9.en.txt |
8 |
new file mode 100644 |
9 |
index 0000000..29fdc9d |
10 |
--- /dev/null |
11 |
+++ b/2021-04-29-python3-9/2021-04-29-python3-9.en.txt |
12 |
@@ -0,0 +1,92 @@ |
13 |
+Title: Python 3.9 to become the default target on 2021-06-01 |
14 |
+Author: Michał Górny <mgorny@g.o> |
15 |
+Posted: 2021-04-29 |
16 |
+Revision: 1 |
17 |
+News-Item-Format: 2.0 |
18 |
+Display-If-Installed: dev-lang/python:3.7 |
19 |
+Display-If-Installed: dev-lang/python:3.8 |
20 |
+ |
21 |
+We are planning to switch the default Python target of Gentoo systems |
22 |
+on 2021-06-01, from Python 3.8 to Python 3.9. If you have not changed |
23 |
+the values of PYTHON_TARGETS or PYTHON_SINGLE_TARGET, the change will |
24 |
+have immediate effect on your system and the package manager will try |
25 |
+to switch automatically on the next upgrade following the change. |
26 |
+If you did change the values, prefer a safer approach or have problems |
27 |
+with the update, read on. |
28 |
+ |
29 |
+Please note that the default upgrade method switches packages to the new |
30 |
+Python versions as they are rebuilt. This means that all interdependent |
31 |
+packages have to support the new version for the upgrade to proceed, |
32 |
+and that some programs may temporarily fail to find their dependencies |
33 |
+throughout the upgrade (although programs that are already started |
34 |
+are unlikely to be affected). |
35 |
+ |
36 |
+ |
37 |
+If you wish to avoid changing Python targets at this moment, you can |
38 |
+force the old targets by setting your /etc/portage/package.use to e.g.: |
39 |
+ |
40 |
+ */* PYTHON_TARGETS: -* python3_8 |
41 |
+ */* PYTHON_SINGLE_TARGET: -* python3_8 |
42 |
+ |
43 |
+This will enforce Python 3.8 as the current target choice and block |
44 |
+any future updates. However, please note that this solution will only |
45 |
+be suitable for a few more months and you will eventually need to |
46 |
+perform the migration. |
47 |
+ |
48 |
+ |
49 |
+If you wish to use a safer approach to the migration and temporarily |
50 |
+preserve the support for Python 3.7 and Python 3.8 simultaneously, |
51 |
+set /etc/portage/package.use to: |
52 |
+ |
53 |
+ */* PYTHON_TARGETS: -* python3_7 python3_8 |
54 |
+ */* PYTHON_SINGLE_TARGET: -* python3_7 |
55 |
+ |
56 |
+Afterwards, rebuild your system with emerge's --changed-use option or |
57 |
+equivalent. This will cause your packages to gain Python 3.8 support |
58 |
+while preserving Python 3.7 support whenever possible. Then, change |
59 |
+the second line to: |
60 |
+ |
61 |
+ */* PYTHON_SINGLE_TARGET: -* python3_8 |
62 |
+ |
63 |
+This will switch packages that can not support two Python versions |
64 |
+simultaneously, to use Python 3.8. Rebuild again. Finally, switch |
65 |
+the first line to the final form: |
66 |
+ |
67 |
+ */* PYTHON_TARGETS: -* python3_8 |
68 |
+ |
69 |
+The next --changed-use rebuild will remove Python 3.7 support from your |
70 |
+packages. |
71 |
+ |
72 |
+ |
73 |
+You can also switch to Python 3.8 earlier by setting: |
74 |
+ |
75 |
+ */* PYTHON_TARGETS: -* python3_8 |
76 |
+ */* PYTHON_SINGLE_TARGET: -* python3_8 |
77 |
+ |
78 |
+If you choose to follow this or the previous approach, you may want to |
79 |
+remove the package.use overrides after the switch or just leave them |
80 |
+in place to protect your system from the next automatic upgrade |
81 |
+of Python. |
82 |
+ |
83 |
+ |
84 |
+The Python 3.7 cleanup requires that Python 3.7 is removed from complete |
85 |
+dependency trees in batch. If some of the installed packages using |
86 |
+an older Python version are not triaged for the upgrade, the package |
87 |
+manager will throw dependency conflicts. This makes it important that |
88 |
+the upgrade is carried via a --deep --changed-use @world upgrade, |
89 |
+as well as that any stray packages are removed prior to it, e.g.: |
90 |
+ |
91 |
+ emerge --depclean |
92 |
+ emerge -1vUD @world |
93 |
+ emerge --depclean |
94 |
+ |
95 |
+ |
96 |
+By the time of the switch, it is quite probable that Python 3.10 will |
97 |
+already be available in ~arch Gentoo. Users wishing a more bleeding |
98 |
+edge experience may wish to switch to python3_10 target instead. |
99 |
+ |
100 |
+ |
101 |
+If you have PYTHON_TARGETS or PYTHON_SINGLE_TARGET declared |
102 |
+in make.conf, it is strongly recommended to remove the declarations |
103 |
+and use package.use as presented above. Use of make.conf to set flags |
104 |
+is strongly discouraged as it does not respect package defaults. |
105 |
-- |
106 |
2.31.1 |