Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commita6f881a

Browse files
committed
Merge branch 'v1.5.x' into v2.0.x
2 parents17a3a6d +0cf4085 commita6f881a

File tree

4 files changed

+10
-9
lines changed

4 files changed

+10
-9
lines changed

‎lib/matplotlib/dates.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -281,7 +281,7 @@ def _from_ordinalf(x, tz=None):
281281
elifdt.microsecond>999990:
282282
dt+=datetime.timedelta(microseconds=1e6-dt.microsecond)
283283

284-
returndt
284+
returndt.astimezone(tz)
285285

286286

287287
# a version of _from_ordinalf that can operate on numpy arrays

‎lib/matplotlib/dviread.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -387,7 +387,11 @@ def _fnt_def(self, k, c, s, d, a, l, n):
387387
fontname=n[-l:].decode('ascii')
388388
tfm=_tfmfile(fontname)
389389
iftfmisNone:
390-
raiseFileNotFoundError("missing font metrics file: %s"%fontname)
390+
ifsix.PY2:
391+
error_class=OSError
392+
else:
393+
error_class=FileNotFoundError
394+
raiseerror_class("missing font metrics file: %s"%fontname)
391395
ifc!=0andtfm.checksum!=0andc!=tfm.checksum:
392396
raiseValueError('tfm checksum mismatch: %s'%n)
393397

‎lib/matplotlib/tests/test_cycles.py

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,8 @@ def test_colorcycle_basic():
2626
ax.legend(loc='upper left')
2727

2828

29-
@image_comparison(baseline_images=['marker_cycle'],remove_text=True,
30-
extensions=['png'])
29+
@image_comparison(baseline_images=['marker_cycle','marker_cycle'],
30+
remove_text=True,extensions=['png'])
3131
deftest_marker_cycle():
3232
fig=plt.figure()
3333
ax=fig.add_subplot(111)
@@ -44,11 +44,6 @@ def test_marker_cycle():
4444
ax.plot(xs,ys,label='red2 dot',lw=4,ms=16)
4545
ax.legend(loc='upper left')
4646

47-
48-
# Reuse the image from test_marker_cycle()
49-
@image_comparison(baseline_images=['marker_cycle'],remove_text=True,
50-
extensions=['png'])
51-
deftest_marker_cycle_keywords():
5247
fig=plt.figure()
5348
ax=fig.add_subplot(111)
5449
# Test keyword arguments, numpy arrays, and generic iterators

‎tools/test_triage.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,8 @@
2424
R: Reject test. Copy the expected result to the source tree.
2525
"""
2626

27+
from __future__importunicode_literals
28+
2729
importos
2830
importshutil
2931
importsys

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp