• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

hgrecco / pint / 1729
92%
master: 91%

Build:
Build:
LAST BUILD BRANCH: fix-nonmult-doc
DEFAULT BRANCH: master
Ran 09 Apr 2020 02:42PM UTC
Jobs 16
Files 18
Run time 8min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

pending completion
1729

push

travis-ci

web-flow
Merge #1070

1070: Make 'Lx' safe for use with uncertainties r=hgrecco a=PorcelainMouse

- [x] Pertains to issue # 814
- [x] Executed ``black -t py36 . && isort -rc . && flake8`` with no errors
- [x] The change is fully covered by automated unit tests
- [x] Documented in docs/ as appropriate
- [x] Added an entry to the CHANGES file

Here is my suggested patch related to issue #814. After working on it for a while, I considered several solutions and this seemed the best, immediately available option.
This patch set avoids a compilation error thrown by LaTeX when SIunitx is given uncertainty value containing a decimal place, i.e. "\SI{123.4(1.2)}{\meter}%wrong!".

I think a better solution would be to work with 'uncertainties' to implement a fully compatible string format type implementation, as the current implementation for 'S' is not compatible and, as best I can tell, incorrect. (See NIST "concise" form for representing uncertain values in a single figure, which is what SIunitx is expecting.) If this is fixed, I think 'pint' could go back to the original code and achieve even more compatibility.

As part of this patch set, I removed the hard-coded SIunitx option "separate-uncertainty=true". It wasn't clear why this option was hard set and it did not appear to be necessary to pass any tests, nor any additional use case I tried.  Also, I could not think of a good way to reverse this option for the user of pint; it is not configurable.  It could be added back without much trouble, if required.

An alternative solution would be to check for '.' in the () part of the "concise" uncertainty value and just remove it. I did not do this because it requires that 'uncertainties' always produces nominal and unc values aligned with the same least significant digit, which I think is the case, but I wasn't confident.

However, '.1Lx' still produces invalid LaTeX code. Such a format spec may be invalid, though; I'm not sure. This is a separate issue a... (continued)

9 of 9 new or added lines in 1 file covered. (100.0%)

3589 of 3992 relevant lines covered (89.9%)

11.85 hits per line

Jobs
ID Job ID Ran Files Coverage
1 1729.1 (PKGS="python=3.7 flake8 black isort") 09 Apr 2020 02:42PM UTC 0
0.0
Travis Job 1729.1
2 1729.2 (PKGS="python=3.7 ipython matplotlib nbsphinx numpy pandas jupyter_client ipykernel python-graphviz graphviz xarray sparse dask[complete] sphinx Pygments==2.3.1 docutils==0.14 alabaster commonmark==0.8.1 recommonmark==0.5.0") 09 Apr 2020 02:44PM UTC 0
0.0
Travis Job 1729.2
3 1729.3 (PKGS="python=3.6") 09 Apr 2020 02:43PM UTC 0
75.43
Travis Job 1729.3
4 1729.4 (PKGS="python=3.7") 09 Apr 2020 02:43PM UTC 0
75.36
Travis Job 1729.4
5 1729.5 (PKGS="python=3.8") 09 Apr 2020 02:44PM UTC 0
75.8
Travis Job 1729.5
6 1729.6 (PKGS="python=3.6 uncertainties=3.0") 09 Apr 2020 02:44PM UTC 0
88.3
Travis Job 1729.6
7 1729.7 (PKGS="python=3.7 uncertainties=3.0") 09 Apr 2020 02:45PM UTC 0
88.3
Travis Job 1729.7
8 1729.8 (PKGS="python=3.6 numpy=1.14 matplotlib") 09 Apr 2020 02:46PM UTC 0
84.92
Travis Job 1729.8
9 1729.9 (PKGS="python=3.7 numpy=1.14 matplotlib") 09 Apr 2020 02:46PM UTC 0
85.0
Travis Job 1729.9
10 1729.10 (PKGS="python=3.8 numpy=1.17 matplotlib") 09 Apr 2020 02:47PM UTC 0
87.42
Travis Job 1729.10
11 1729.11 (PKGS="python=3.6 numpy=1.14 uncertainties=3.0") 09 Apr 2020 02:47PM UTC 0
86.13
Travis Job 1729.11
12 1729.12 (PKGS="python=3.7 numpy=1.14 uncertainties=3.0") 09 Apr 2020 02:48PM UTC 0
86.13
Travis Job 1729.12
13 1729.13 (PKGS="python=3.6 numpy uncertainties") 09 Apr 2020 02:48PM UTC 0
88.23
Travis Job 1729.13
14 1729.14 (PKGS="python=3.7 numpy uncertainties") 09 Apr 2020 02:49PM UTC 0
88.3
Travis Job 1729.14
15 1729.15 (PKGS="python=3.8 numpy uncertainties") 09 Apr 2020 02:49PM UTC 0
88.43
Travis Job 1729.15
16 1729.16 (PKGS="python=3.8 numpy uncertainties sparse xarray netCDF4") 09 Apr 2020 02:50PM UTC 0
88.52
Travis Job 1729.16
Source Files on build 1729
Detailed source file information is not available for this build.
  • Back to Repo
  • Travis Build #1729
  • cec44515 on github
  • Prev Build on staging (#1726)
  • Next Build on staging (#1732)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc