Skip to content

Commit 73c5e77

Browse files
committed
update before class
1 parent 0ebaf06 commit 73c5e77

4 files changed

Lines changed: 20 additions & 19 deletions

File tree

content/09-packages/python-more-modules.md

Lines changed: 7 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -14,17 +14,13 @@ We can look at the path via ``sys.path``. On my machine I get:
1414

1515
```
1616
['/home/zingale/.local/bin',
17-
'/home/zingale/classes/python-science/content/09-packages',
18-
'/home/zingale/classes/numerical_exercises',
19-
'/home/zingale/classes/astro_animations',
20-
'/usr/lib64/python312.zip',
21-
'/usr/lib64/python3.12',
22-
'/usr/lib64/python3.12/lib-dynload',
17+
'/usr/lib64/python314.zip',
18+
'/usr/lib64/python3.14',
19+
'/usr/lib64/python3.14/lib-dynload',
2320
'',
24-
'/home/zingale/.local/lib/python3.12/site-packages',
25-
'/usr/lib64/python3.12/site-packages',
26-
'/usr/lib/python3.12/site-packages']
27-
21+
'/home/zingale/.local/lib/python3.14/site-packages',
22+
'/usr/lib64/python3.14/site-packages',
23+
'/usr/lib/python3.14/site-packages']
2824
```
2925

3026
```{note}
@@ -46,7 +42,7 @@ python3 -m site --user-site
4642
on my machine, this gives:
4743

4844
```
49-
/home/zingale/.local/lib/python3.12/site-packages
45+
/home/zingale/.local/lib/python3.14/site-packages
5046
```
5147

5248
```{tip}

content/09-packages/python-packages.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -189,7 +189,7 @@ print(mymodule.__file__)
189189
it shows us where the module is installed on our system. In my case, it is:
190190

191191
```
192-
/home/zingale/.local/lib/python3.12/site-packages/mymodule-0.1.0-py3.12.egg/mymodule/__init__.py
192+
/home/zingale/.local/lib/python3.14/site-packages/mymodule/__init__.py
193193
```
194194

195195
Let's generate a plot:

content/09-packages/python-tools.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,10 +51,10 @@ as your write your code.
5151
use of new features where available. For instance, you can run as:
5252

5353
```
54-
pyupgrade --py39-plus file.py
54+
pyupgrade --py313-plus file.py
5555
```
5656

57-
to update to python 3.9 support.
57+
to update to python 3.13 support.
5858

5959
* [isort](https://pycqa.github.io/isort/)
6060

examples/commandline/argparse_example.py

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,16 @@
66
# simple example of argparse
77

88
parser = argparse.ArgumentParser()
9-
parser.add_argument("-a", help="the -a option", action="store_true")
10-
parser.add_argument("-b", help="-b takes a number", type=int, default=0)
11-
parser.add_argument("-c", help="-c takes a string", type=str, default=None)
12-
parser.add_argument("--darg", help="the --darg option", action="store_true")
13-
parser.add_argument("--earg", help="--earg takes a string", type=str, metavar="test",
9+
parser.add_argument("-a", help="the -a option",
10+
action="store_true")
11+
parser.add_argument("-b", help="-b takes a number",
12+
type=int, default=0)
13+
parser.add_argument("-c", help="-c takes a string",
14+
type=str, default=None)
15+
parser.add_argument("--darg", help="the --darg option",
16+
action="store_true")
17+
parser.add_argument("--earg", help="--earg takes a string",
18+
type=str, metavar="test",
1419
default="example string")
1520

1621
# extra arguments (positional)

0 commit comments

Comments
 (0)