Menu

#2865 Plot title is not initialized correctly following a plot with no valid data

None
pending-fixed
nobody
None
2 days ago
2 days ago
No

If a plot title is given as a string-valued function, this expression is stored for evaluation after the plot is drawn and then cleared. However if the plot is never drawn because there are no valid data points, the stored expression is not cleared. If the following plot component does not specify a title, it inherits the unused expression which is at best wrong and at worst may cause an error failure because the expression is no longer valid.

Reproducer:

plot for [foo in "A B"] 'silver.dat' title foo if (0), 40-x/2
     "title.bug" line 11: warning: Skipping data file with no valid points
     "title.bug" line 11: warning: Skipping data file with no valid points
     "title.bug" line 11: undefined variable: foo

Discussion

  • Ethan Merritt

    Ethan Merritt - 2 days ago
    • Description has changed:

    Diff:

    --- old
    +++ new
    @@ -2,7 +2,6 @@
    
     Reproducer:
    
    
    -    list = "A B"
         plot for [foo in "A B"] 'silver.dat' title foo if (0), 40-x/2
              "title.bug" line 11: warning: Skipping data file with no valid points
              "title.bug" line 11: warning: Skipping data file with no valid points
    
    • Group: -->
    • Priority: -->
     
  • Ethan Merritt

    Ethan Merritt - 2 days ago
    • Description has changed:

    Diff:

    --- old
    +++ new
    @@ -6,5 +6,3 @@
              "title.bug" line 11: warning: Skipping data file with no valid points
              "title.bug" line 11: warning: Skipping data file with no valid points
              "title.bug" line 11: undefined variable: foo
    -
    -The same problem is present for splot.
    
     
  • Ethan Merritt

    Ethan Merritt - 2 days ago
    • status: open --> pending-fixed
     
  • Ethan Merritt

    Ethan Merritt - 2 days ago

    Fixed in 6.1
    Queued for 6.0.5

     

Log in to post a comment.

MongoDB Logo MongoDB