##// END OF EJS Templates
Merge pull request #9200 from Carreau/rc2...
Matthias Bussonnier -
r22044:2b851fe3 merge
parent child Browse files
Show More
@@ -1,39 +1,23 b''
1 1 =====================
2 2 Development version
3 3 =====================
4 4
5 5 This document describes in-flight development work.
6 6
7 7 .. warning::
8 8
9 9 Please do not edit this file by hand (doing so will likely cause merge
10 10 conflicts for other Pull Requests). Instead, create a new file in the
11 11 `docs/source/whatsnew/pr` folder
12 12
13 13
14 IPython debugger (IPdb) now supports the number of context lines for the
15 ``where`` (and ``w``) commands. The `context` keyword is also available in various APIs.
16 See PR :ghpull:`9097`
17 14
18 YouTube video will now show thumbnail when exported to a media that do not support video. (:ghpull:`9086`)
19
20 Add warning when running `ipython <subcommand>` when subcommand is deprecated. `jupyter` should now be used.
21
22 Code in `%pinfo` (also known as `??`) are now highlighter (:ghpull:`8947`)
23
24 `%aimport` now support module completion. (:ghpull:`8884`)
25
26 `ipdb` output is now colored ! (:ghpull:`8842`)
27
28 Add ability to transpose columns for completion: (:ghpull:`8748`)
29
30 Many many docs improvements and bug fixes, you can see the list of changes [add link to GitHub diff]
31 15
32 16 .. DO NOT EDIT THIS LINE BEFORE RELEASE. FEATURE INSERTION POINT.
33 17
34 18
35 19 Backwards incompatible changes
36 20 ------------------------------
37 21
38 22
39 .. DO NOT EDIT THIS LINE BEFORE RELEASE. INCOMPAT INSERTION POINT. No newline at end of file
23 .. DO NOT EDIT THIS LINE BEFORE RELEASE. INCOMPAT INSERTION POINT.
@@ -1,46 +1,69 b''
1 1 ============
2 2 4.x Series
3 3 ============
4 4
5
6 IPython 4.1
7 ===========
8
9 Release February, 2016. IPython 4.1 contain mostly bug fixes. It though contain
10 a few improvement.
11
12
13 - IPython debugger (IPdb) now supports the number of context lines for the
14 ``where`` (and ``w``) commands. The `context` keyword is also available in
15 various APIs. See PR :ghpull:`9097`
16 - YouTube video will now show thumbnail when exported to a media that do not
17 support video. (:ghpull:`9086`)
18 - Add warning when running `ipython <subcommand>` when subcommand is
19 deprecated. `jupyter` should now be used.
20 - Code in `%pinfo` (also known as `??`) are now highlighter (:ghpull:`8947`)
21 - `%aimport` now support module completion. (:ghpull:`8884`)
22 - `ipdb` output is now colored ! (:ghpull:`8842`)
23 - Add ability to transpose columns for completion: (:ghpull:`8748`)
24
25 Many many docs improvements and bug fixes, you can see the
26 `list of changes <https://github.com/ipython/ipython/compare/4.0.0...4.1.0>`_
27
5 28 IPython 4.0
6 29 ===========
7 30
8 31 Released August, 2015
9 32
10 33 IPython 4.0 is the first major release after the Big Split.
11 34 IPython no longer contains the notebook, qtconsole, etc. which have moved to
12 35 `jupyter <https://jupyter.readthedocs.org>`_.
13 36 IPython subprojects, such as `IPython.parallel <https://ipyparallel.readthedocs.org>`_ and `widgets <https://ipywidgets.readthedocs.org>`_ have moved to their own repos as well.
14 37
15 38 The following subpackages are deprecated:
16 39
17 40 - IPython.kernel (now jupyter_client and ipykernel)
18 41 - IPython.consoleapp (now jupyter_client.consoleapp)
19 42 - IPython.nbformat (now nbformat)
20 43 - IPython.nbconvert (now nbconvert)
21 44 - IPython.html (now notebook)
22 45 - IPython.parallel (now ipyparallel)
23 46 - IPython.utils.traitlets (now traitlets)
24 47 - IPython.config (now traitlets.config)
25 48 - IPython.qt (now qtconsole)
26 49 - IPython.terminal.console (now jupyter_console)
27 50
28 51 and a few other utilities.
29 52
30 53 Shims for the deprecated subpackages have been added,
31 54 so existing code should continue to work with a warning about the new home.
32 55
33 56 There are few changes to the code beyond the reorganization and some bugfixes.
34 57
35 58 IPython highlights:
36 59
37 60 - Public APIs for discovering IPython paths is moved from :mod:`IPython.utils.path` to :mod:`IPython.paths`.
38 61 The old function locations continue to work with deprecation warnings.
39 62 - Code raising ``DeprecationWarning``
40 63 entered by the user in an interactive session will now display the warning by
41 64 default. See :ghpull:`8480` an :ghissue:`8478`.
42 65 - The `--deep-reload` flag and the corresponding options to inject `dreload` or
43 66 `reload` into the interactive namespace have been deprecated, and will be
44 67 removed in future versions. You should now explicitly import `reload` from
45 68 `IPython.lib.deepreload` to use it.
46 69
@@ -1,28 +1,32 b''
1 1 #!/usr/bin/env python
2 2 """IPython release build script.
3 3 """
4
5 4 import os
6 5 from shutil import rmtree
7 6
8 from toollib import sh, pjoin, get_ipdir, cd, compile_tree, execfile, sdists, wheels
7 from toollib import sh, pjoin, get_ipdir, cd, compile_tree, execfile, sdists, buildwheels
8
9 def build_release():
10
11 # Get main ipython dir, this will raise if it doesn't pass some checks
12 ipdir = get_ipdir()
13 cd(ipdir)
9 14
10 # Get main ipython dir, this will raise if it doesn't pass some checks
11 ipdir = get_ipdir()
12 cd(ipdir)
15 # Load release info
16 execfile(pjoin('IPython', 'core', 'release.py'), globals())
13 17
14 # Load release info
15 execfile(pjoin('IPython', 'core', 'release.py'), globals())
18 # Check that everything compiles
19 compile_tree('*')
16 20
17 # Check that everything compiles
18 compile_tree('*')
21 # Cleanup
22 for d in ['build', 'dist', pjoin('docs', 'build'), pjoin('docs', 'dist'),
23 pjoin('docs', 'source', 'api', 'generated')]:
24 if os.path.isdir(d):
25 rmtree(d)
19 26
20 # Cleanup
21 for d in ['build', 'dist', pjoin('docs', 'build'), pjoin('docs', 'dist'),
22 pjoin('docs', 'source', 'api', 'generated')]:
23 if os.path.isdir(d):
24 rmtree(d)
27 # Build source and binary distros
28 sh(sdists)
29 buildwheels()
25 30
26 # Build source and binary distros
27 sh(sdists)
28 sh(wheels)
31 if __name__ == '__main__':
32 build_release()
@@ -1,88 +1,88 b''
1 1 #!/usr/bin/env python
2 2 """IPython release script.
3 3
4 4 This should ONLY be run at real release time.
5 5 """
6 6 from __future__ import print_function
7 7
8 8 import os
9 9 import sys
10 10
11 11 from toollib import (get_ipdir, pjoin, cd, execfile, sh, archive,
12 sdists, archive_user, archive_dir)
12 sdists, archive_user, archive_dir, buildwheels)
13 13 from gh_api import post_download
14 14
15 15 # Get main ipython dir, this will raise if it doesn't pass some checks
16 16 ipdir = get_ipdir()
17 17 tooldir = pjoin(ipdir, 'tools')
18 18 distdir = pjoin(ipdir, 'dist')
19 19
20 20 # Where I keep static backups of each release
21 21 ipbackupdir = os.path.expanduser('~/ipython/backup')
22 22 if not os.path.exists(ipbackupdir):
23 23 os.makedirs(ipbackupdir)
24 24
25 25 # Start in main IPython dir
26 26 cd(ipdir)
27 27
28 28 # Load release info
29 29 version = None
30 30 execfile(pjoin('IPython','core','release.py'), globals())
31 31
32 32 # Build site addresses for file uploads
33 33 release_site = '%s/release/%s' % (archive, version)
34 34 backup_site = '%s/backup/' % archive
35 35
36 36 # Start actual release process
37 37 print()
38 38 print('Releasing IPython')
39 39 print('=================')
40 40 print()
41 41 print('Version:', version)
42 42 print()
43 43 print('Source IPython directory:', ipdir)
44 44 print()
45 45
46 46 # Perform local backup, go to tools dir to run it.
47 47 cd(tooldir)
48 48 sh('./make_tarball.py')
49 49 sh('mv ipython-*.tgz %s' % ipbackupdir)
50 50
51 51 # Build release files
52 52 sh('./build_release %s' % ipdir)
53 53
54 54 # Not Registering with PyPI, registering with setup.py is insecure as communication is not encrypted
55 55 cd(ipdir)
56 56
57 57 # Upload all files
58 58 sh(sdists)
59 for py in ('2', '3'):
60 sh('python%s setupegg.py bdist_wheel' % py)
59
60 buildwheels()
61 61
62 62 if 'upload' not in sys.argv:
63 63 print("`./release upload` to register and release")
64 64 sys.exit(0)
65 65
66 66
67 67 print('Will not upload with setuptools as upload connection is insecure. Please use `twine upload dist/*` to upload the files to PyPI')
68 68
69 69 cd(distdir)
70 70 print( 'Uploading distribution files to GitHub...')
71 71
72 72 for fname in os.listdir('.'):
73 73 # TODO: update to GitHub releases API
74 74 continue
75 75 print('uploading %s to GitHub' % fname)
76 76 desc = "IPython %s source distribution" % version
77 77 post_download("ipython/ipython", fname, description=desc)
78 78
79 79 # Make target dir if it doesn't exist
80 80 print('Uploading IPython to backup site.')
81 81 sh('ssh %s "mkdir -p %s/release/%s" ' % (archive_user, archive_dir, version))
82 82 sh('scp * %s' % release_site)
83 83
84 84 print( 'Uploading backup files...')
85 85 cd(ipbackupdir)
86 86 sh('scp `ls -1tr *tgz | tail -1` %s' % backup_site)
87 87
88 88 print('Done!')
@@ -1,64 +1,66 b''
1 1 """Various utilities common to IPython release and maintenance tools.
2 2 """
3 3 from __future__ import print_function
4 4
5 5 # Library imports
6 6 import os
7 7
8 8 # Useful shorthands
9 9 pjoin = os.path.join
10 10 cd = os.chdir
11 11
12 12 # Constants
13 13
14 14 # SSH root address of the archive site
15 15 archive_user = 'ipython@archive.ipython.org'
16 16 archive_dir = 'archive.ipython.org'
17 17 archive = '%s:%s' % (archive_user, archive_dir)
18 18
19 19 # Build commands
20 20 # Source dists
21 21 sdists = './setup.py sdist --formats=gztar,zip'
22 22 # Binary dists
23 wheels = './setupegg.py bdist_wheel'
23 def buildwheels():
24 for py in ('2', '3'):
25 sh('python%s setupegg.py bdist_wheel' % py)
24 26
25 27 # Utility functions
26 28 def sh(cmd):
27 29 """Run system command in shell, raise SystemExit if it returns an error."""
28 30 print("$", cmd)
29 31 stat = os.system(cmd)
30 32 #stat = 0 # Uncomment this and comment previous to run in debug mode
31 33 if stat:
32 34 raise SystemExit("Command %s failed with code: %s" % (cmd, stat))
33 35
34 36 # Backwards compatibility
35 37 c = sh
36 38
37 39 def get_ipdir():
38 40 """Get IPython directory from command line, or assume it's the one above."""
39 41
40 42 # Initialize arguments and check location
41 43 ipdir = pjoin(os.path.dirname(__file__), os.pardir)
42 44
43 45 ipdir = os.path.abspath(ipdir)
44 46
45 47 cd(ipdir)
46 48 if not os.path.isdir('IPython') and os.path.isfile('setup.py'):
47 49 raise SystemExit('Invalid ipython directory: %s' % ipdir)
48 50 return ipdir
49 51
50 52
51 53 def compile_tree(folder='.'):
52 54 """Compile all Python files below current directory."""
53 55 stat = os.system('python -m compileall {}'.format(folder))
54 56 if stat:
55 57 msg = '*** ERROR: Some Python files in tree do NOT compile! ***\n'
56 58 msg += 'See messages above for the actual file that produced it.\n'
57 59 raise SystemExit(msg)
58 60
59 61 try:
60 62 execfile
61 63 except NameError:
62 64 def execfile(fname, globs, locs=None):
63 65 locs = locs or globs
64 66 exec(compile(open(fname).read(), fname, "exec"), globs, locs)
@@ -1,78 +1,82 b''
1 1 #!/usr/bin/env python
2 2 """Update the What's New doc (development version)
3 3
4 4 This collects the snippets from whatsnew/pr/, moves their content into
5 5 whatsnew/development.rst (chronologically ordered), and deletes the snippets.
6 6 """
7 7
8 8 import io
9 import os
9 import sys
10 10 from glob import glob
11 11 from os.path import dirname, basename, abspath, join as pjoin
12 12 from subprocess import check_call, check_output
13 13
14 14 repo_root = dirname(dirname(abspath(__file__)))
15 15 whatsnew_dir = pjoin(repo_root, 'docs', 'source', 'whatsnew')
16 16 pr_dir = pjoin(whatsnew_dir, 'pr')
17 17 target = pjoin(whatsnew_dir, 'development.rst')
18 18
19 19 FEATURE_MARK = ".. DO NOT EDIT THIS LINE BEFORE RELEASE. FEATURE INSERTION POINT."
20 20 INCOMPAT_MARK = ".. DO NOT EDIT THIS LINE BEFORE RELEASE. INCOMPAT INSERTION POINT."
21 21
22 22 # 1. Collect the whatsnew snippet files ---------------------------------------
23 23
24 24 files = set(glob(pjoin(pr_dir, '*.rst')))
25 25 # Ignore explanatory and example files
26 26 files.difference_update({pjoin(pr_dir, f) for f in {
27 27 'incompat-switching-to-perl.rst',
28 28 'antigravity-feature.rst'}
29 29 })
30 30
31 if not files:
32 print("No automatic update available for what's new")
33 sys.exit(0)
34
31 35
32 36 def getmtime(f):
33 37 return check_output(['git', 'log', '-1', '--format="%ai"', '--', f])
34 38
35 39 files = sorted(files, key=getmtime)
36 40
37 41 features, incompats = [], []
38 42 for path in files:
39 43 with io.open(path, encoding='utf-8') as f:
40 44 try:
41 45 content = f.read().rstrip()
42 46 except Exception as e:
43 47 raise Exception('Error reading "{}"'.format(f)) from e
44 48
45 49 if basename(path).startswith('incompat-'):
46 50 incompats.append(content)
47 51 else:
48 52 features.append(content)
49 53
50 54 # Put the insertion markers back on the end, so they're ready for next time.
51 55 feature_block = '\n\n'.join(features + [FEATURE_MARK])
52 56 incompat_block = '\n\n'.join(incompats + [INCOMPAT_MARK])
53 57
54 58 # 2. Update the target file ---------------------------------------------------
55 59
56 60 with io.open(target, encoding='utf-8') as f:
57 61 content = f.read()
58 62
59 63 assert content.count(FEATURE_MARK) == 1
60 64 assert content.count(INCOMPAT_MARK) == 1
61 65
62 66 content = content.replace(FEATURE_MARK, feature_block)
63 67 content = content.replace(INCOMPAT_MARK, incompat_block)
64 68
65 69 # Clean trailing whitespace
66 70 content = '\n'.join(l.rstrip() for l in content.splitlines())
67 71
68 72 with io.open(target, 'w', encoding='utf-8') as f:
69 73 f.write(content)
70 74
71 75 # 3. Stage the changes in git -------------------------------------------------
72 76
73 77 for file in files:
74 78 check_call(['git', 'rm', file])
75 79
76 80 check_call(['git', 'add', target])
77 81
78 82 print("Merged what's new changes. Check the diff and commit the change.")
General Comments 0
You need to be logged in to leave comments. Login now