Commit graph

19 commits

Author SHA1 Message Date
Noorhteen Raja NJ
38295a1dd9
Remove globals (#4280)
* refactor: remove usage of global variables in abbrevs.py

* chore: add flake8-mutable to prevent mutable defaults

* fix: abbrevs expand test

* refactor: add xonsh session singleton

* refactor: fix circular errors when using xonshSession as singleton

* refactor: remove black magicked builtin attributes

* style: black format tests as well

* refactor: update tests to use xonsh-session singleton

* refactor: update abbrevs to not use builtins

* test: remove DummyCommandsCache and patch orig class

* fix: failing test_command_completers

* test: use monkeypatch to update xession fixture

* fix: failing test_pipelines

* fix: failing test_main

* chore: run test suit as single invocation

* test: fix tests/test_xonsh.xsh

* refactor: remove builtins from docs/conf.py

* fix: mypy error in jobs

* fix: test error from test_main

* test: close xession error in test_command_completers

* chore: use pytest-cov for reporting coverage

this will include subprocess calls, and will increase coverage

* style:
2021-05-20 13:14:26 +03:00
a
b8caf65534 no_color to reset 2020-10-09 01:04:52 +03:00
Gil Forsyth
258c2fc610 Run black on all bundled xontribs 2019-04-26 11:11:11 -04:00
Anthony Scopatz
2264f72b45 fixed some more bugs 2018-09-13 17:08:01 -04:00
Anthony Scopatz
23251a4a67 some remaining style fixes 2018-07-16 09:43:36 -04:00
Anthony Scopatz
ca49e2e246 more style fixes 2018-07-15 17:26:22 -05:00
Joel Gerber
2abb24f4f6
Docstring and comment spelling corrections
A number of common spelling typos found within various docstrings and
comments found within source code files have been identified and resolved.
2017-06-07 11:51:17 -04:00
Derek Thomas
da250793e7 add iterm2 and inline-image support for xontrib-mpl
- requires the use of `iTerm2.app` app for OSX
- requires the presence of package `iterm2_tools` to work
2016-10-09 22:55:42 +08:00
Derek Thomas
99c43bd28e add doc-string for mplhooks.show 2016-10-09 22:53:32 +08:00
Derek Thomas
ffded5cc7c add returns to the doc-string for mpl
- also, remove the link to forked method because the current methodology
has diverged from it entirely
2016-10-09 22:49:30 +08:00
Derek Thomas
0806b0ff48 mpl now relies on a buffer method as the recommended way to save figure
- also, removes reliance on the canvas object in favor of simple
high-level figure methods
2016-10-09 22:47:35 +08:00
Derek Thomas
33c49e55f1 refactor xontrib-mpl
- add environment configuration: $XONTRIB_MPL_MINIMAL_DEFAULT
    + defines if the plot will plot will minimize all plots and reduce
    margins to nearly nothing
    + if false, the printed plot will attempt meet the same layout as
    the figure is meant to contain, but text will look mostly like
    single characters unless font size is particularly large compared to
    the plot area.
- split the array generation into two functions
    + figure_to_rgb_array now is a simple function that generates a
    numpy array of the image representation of the figure.
    + figure_to_tight_array replaces the old figure_to_rgb_array by
    taking in a width, height, and minimal boolean.
2016-10-09 21:23:22 +08:00
Derek Thomas
57d1b3b38e mpl adjusts subplot positions to force no margins
- does not use tight layout anymore
2016-10-03 23:51:27 +09:00
Derek Thomas
f3ea7c273d mpl now iterates over all axes in the figure to change parameters
- also added ylabel, xlabel, and title zeroing, so that they do not
interfere with the layout since it cannot be displayed anyway
2016-10-03 23:42:39 +09:00
Derek Thomas
e7f2d5a281 move mpl figure-copy routine to figure_to_rgb_array
- this simplifies testing
- this also makes more sense because it copies the figure just when
changes are being applied
- the figure is also closed in this function
2016-10-03 15:59:28 +09:00
Derek Thomas
4e941f7ff4 add inline documentation for mpl figure copy/close 2016-10-03 12:51:43 +09:00
Derek Thomas
aec0430622 xontrib-mpl makes a copy of the current figure before modifying it 2016-10-02 17:18:20 +09:00
Leonardo Santagada
61099aab10 small style changes 2016-07-18 11:30:57 +02:00
Anthony Scopatz
8f886ca11a started xontrib 2016-05-08 17:45:03 -04:00
Renamed from xonsh/mplhooks.py (Browse further)