Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit de0f629

Browse files
committed
#14434: make tutorial link in 'help' banner version-specific
Without this fix, both 2.7 and 3.x would always point to the "current" docs...which means that before this fix python 3.2 'help' pointed to the 2.7 tutorial.
1 parent 9ee65f1 commit de0f629

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

Lib/pydoc.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1829,7 +1829,7 @@ def intro(self):
18291829
Welcome to Python %s! This is the online help utility.
18301830
18311831
If this is your first time using Python, you should definitely check out
1832-
the tutorial on the Internet at http://docs.python.org/tutorial/.
1832+
the tutorial on the Internet at http://docs.python.org/%s/tutorial/.
18331833
18341834
Enter the name of any module, keyword, or topic to get help on writing
18351835
Python programs and using Python modules. To quit this help utility and
@@ -1839,7 +1839,7 @@ def intro(self):
18391839
"keywords", or "topics". Each module also comes with a one-line summary
18401840
of what it does; to list the modules whose summaries contain a given word
18411841
such as "spam", type "modules spam".
1842-
''' % sys.version[:3])
1842+
''' % tuple([sys.version[:3]]*2))
18431843

18441844
def list(self, items, columns=4, width=80):
18451845
items = list(sorted(items))

0 commit comments

Comments
 (0)