Opened 12 months ago

Closed 12 months ago

Last modified 12 months ago

#26299 closed enhancement (fixed)

py3: use repr for floats in plot3d file format outputs

Reported by: embray Owned by:
Priority: minor Milestone: sage-8.4
Component: python3 Keywords:
Cc: Merged in:
Authors: Erik Bray Reviewers: Frédéric Chapoton
Report Upstream: N/A Work issues:
Branch: 06cce34 (Commits) Commit:
Dependencies: Stopgaps:

Description

This can be seen as a continuation of #25247.

Change History (17)

comment:1 Changed 12 months ago by embray

  • Status changed from new to needs_review

comment:2 Changed 12 months ago by embray

  • Status changed from needs_review to needs_work

Apparently I inserted a tab somewhere??

comment:3 Changed 12 months ago by git

  • Commit changed from aa0a1088e9063b36ac14c31402ce1bc031ad4f03 to 24fc2d1b19a752bd5d9bb95f298e627d1aa7b2ff

Branch pushed to git repo; I updated commit sha1. This was a forced push. New commits:

24fc2d1p3: use more explit float.__repr__ instead of float.__str__ for plot3d

comment:4 Changed 12 months ago by embray

  • Status changed from needs_work to needs_review

comment:5 Changed 12 months ago by git

  • Commit changed from 24fc2d1b19a752bd5d9bb95f298e627d1aa7b2ff to 2cec77ca93dca18ad4e41a517560523cc866a04f

Branch pushed to git repo; I updated commit sha1. New commits:

2cec77cpy3: a few more string formatting enhancements in str -> repr for floats

comment:6 Changed 12 months ago by embray

Added a couple more

comment:7 Changed 12 months ago by chapoton

  • Status changed from needs_review to needs_work

one failing doctest

sage -t --long src/sage/plot/plot3d/parametric_surface.pyx

comment:8 Changed 12 months ago by embray

Ah...it seems that when you use f-strings in Cython on Python 2 it returns unicode strings, somewhat annoyingly (but also reasonably).

comment:9 Changed 12 months ago by git

  • Commit changed from 2cec77ca93dca18ad4e41a517560523cc866a04f to 06cce349f9c8bee1236241fbb53c02202b7ebe2a

Branch pushed to git repo; I updated commit sha1. This was a forced push. New commits:

06cce34py3: a few more string formatting enhancements in str -> repr for floats

comment:10 Changed 12 months ago by embray

  • Status changed from needs_work to needs_review

Don't use Python 3 style f-strings if it will needlessly change the output type of existing functions on Python 2.

comment:11 Changed 12 months ago by chapoton

  • Reviewers set to Frédéric Chapoton
  • Status changed from needs_review to positive_review

ok, let it be. Thanks

comment:12 Changed 12 months ago by vbraun

  • Status changed from positive_review to needs_work

merge conflict

comment:13 Changed 12 months ago by chapoton

  • Status changed from needs_work to positive_review

branch is still green, with no apparent conflict with 8.4.b6

I am therefore setting back to positive

comment:14 Changed 12 months ago by vbraun

  • Branch changed from u/embray/python3/sage-plot-plot3d/float-repr to 06cce349f9c8bee1236241fbb53c02202b7ebe2a
  • Resolution set to fixed
  • Status changed from positive_review to closed

comment:15 Changed 12 months ago by embray

  • Commit 06cce349f9c8bee1236241fbb53c02202b7ebe2a deleted

I wonder where the supposed merge conflict came from then...

comment:16 Changed 12 months ago by embray

I don't know why Trac does that sometimes...

comment:17 Changed 12 months ago by embray

Weird. It actually will not even allow me to set the commit field. I guess the plugin doesn't allow a commit field to be set after a ticket is closed, and is so militant about that that it will delete it if you comment on a closed ticket.

Note: See TracTickets for help on using tickets.