Board index » off-topic » [WL] QC rating
|
Serge Dosyukov (Dragon Soft)
Delphi Developer |
|
Serge Dosyukov (Dragon Soft)
Delphi Developer |
[WL] QC rating2006-04-12 02:56:27 AM off-topic10 I know it is all anonymous system but same time it is not When someone is putting a rating on the report and it is low rating then it should be a requirement to put explanation for low rating - this might simply goes into comment field without an ability to be removed by author if only rating is modified. This will help authors with reports and people who put rating to be more responsible for their ratings... |
| Sebastian Modersohn
Delphi Developer |
2006-04-12 04:26:35 AM
Re:[WL] QC ratingQuoteWhen someone is putting a rating on the report and it is low rating then probably would have rated it between 2 and 3 too, for the following reasons: - assuming you know about the nature of floating point numbers it should be quite clear that TDateTime is not the perfect type to store timestamps and compare them to the millisecond; if every millisecond counts, consider storing the date as a TDateTime and store the time in milliseconds as an Integer. - even if you ignore the point above, in your sample you are converting a floating point number to a string and then back assuming that it wouldn't loose any precision. Beside that, I find that it is rather difficult to get the point of the report. You are showing code and it's resulting output in the description and then repeat that in the Steps. Nowhere is it mentioned what you would expect, what you actually get and what kind of consequences you are facing because of the difference. This is not meant to offend you. Its just my 2 cents. Cheers |
| Serge Dosyukov (Dragon Soft)
Delphi Developer |
2006-04-12 05:09:06 AM
Re:[WL] QC rating
"Sebastian Modersohn" < XXXX@XXXXX.COM >wrote in message
Quote>When someone is putting a rating on the report and it is low rating then Quote- assuming you know about the nature of floating point numbers it should any conversons from/to it should not change a value which is stored. Float value IS commonly used to avoid locale format dependency and not introduce UTC convention especially when send via XML Float is Float on every machine and DateTime as String is different based on the locale until someone is using something like this '2005-01-31 10:23:34.212'. Please notice that it is not about Time in Milliseconds but about HOW this value is stored. Off value is because of float presentation as string. In my example 38807.3958333333 is not the same like 38807.39583333333 (+ one 3 after .) or 38807.3958(3) for what that matter. So, IF I assign 38807.39583 to the float it cannot just became 38807.395833 To be precise TDateTime = type Double; so it is especially important that ANY conversion from/to TDateTime (Double) will persist stored value without introducing or reducing number of digits where possible. Any functions which manipulate TDateTime should act the same way like conversion. I hope I am more clear now I also put additional test case to show what exactly happening. it is easy to reproduce. Quote- even if you ignore the point above, in your sample you are converting a packets. Why should I do additional conversion when DateTimeToStr and FloatToStr or access TDateTime/Double value directly should produce the same result no matter how data is massaged in the middle. QuoteBeside that, I find that it is rather difficult to get the point of the Of course you need to read the code to see a difference in accessing the date. QuoteThis is not meant to offend you. Its just my 2 cents. blankly. Yes, one would need to read the report and follow the steps, but does not mean that report is off completely. I've modified the report a little, see if it is better now. PS. there is a reason for the any report, it might be not so clear for everybody who reads it and authors (if they care about it) would go long mile to make the report opened, IF people who spend time to set Rating will spend time on supporting their rating. Not all of us are native English speakers, but it does not makes result of our work worse or better. Believe me, I am trying to put my thoughts as clear as possible, but the same time you need to understand differences in how ideas are presented in different languages. {smallsort} |
| Sebastian Modersohn
Delphi Developer |
2006-04-12 06:10:42 AM
Re:[WL] QC ratingQuoteTDateTime is a type which represent date and time up to point of the precision problems which apply to floating point numbers. Maybe this isn't documented well enough, but that is a different issue. QuoteFloat value IS commonly used to avoid locale format dependency and not dependencies. QuotePlease notice that it is not about Time in Milliseconds but about HOW this code. I've seen INI files there a timestamp has been saved as a float string etc. QuoteI hope I am more clear now simple syntax like expected behaviour and actual behaviour. Quite a few reports employ this and IMHO that makes it easier to grasp what the actual problem is. QuoteI am not ignoring your point but in real life one does not always dictate QuoteI disagree, if you look at the comment after the result of the call you as I mentioned above, would make the report easier to understand. QuoteAnd this is exactly my point in the post here - if someone doesn't see it a rather low rating, because it is *hard* to understand. QuoteI've modified the report a little, see if it is better now. that the conversion could get you "off" by hours if not more. I can't see how this can happen. If you've got a test case I'm more than willing to be proven wrong. QuotePS. there is a reason for the any report, it might be not so clear for post a potential report in the newsgroups and then wait for the input of others. If there is any interest in the subject, you should get enough feedback to prepare a very good report. I realize that this might mean that even more effort for reporting a bug is needed. Cheers |
| Serge Dosyukov (Dragon Soft)
Delphi Developer |
2006-04-12 06:43:11 AM
Re:[WL] QC ratingQuote>TDateTime is a type which represent date and time up to point of the to be made but not here. Quote>Float value IS commonly used to avoid locale format dependency and not Quote>Please notice that it is not about Time in Milliseconds but about HOW Same is here. Double could be precise enough for DateTime, it is current implementation which should recognize this. Quote>I hope I am more clear now Quote>I am not ignoring your point but in real life one does not always dictate Quote>I disagree, if you look at the comment after the result of the call you |
| Brad White
Delphi Developer |
2006-04-12 07:31:54 AM
Re:[WL] QC rating
"Serge Dosyukov (Dragon Soft)" <serge [AT] dragonsoftru [DoT] com>wrote in
message news: XXXX@XXXXX.COM ... Quote
Store a few odd integers in floats. Then do a trunc and assign to an integer. roughly half of them will be off by one. This is just theory, but I don't have time to try it tonight. I can create a test project tomorrow if you care. -- Thanks, Brad. |
| John Herbster
Delphi Developer |
2006-04-12 08:51:07 AM
Re:[WL] QC rating
Serge,
I have added my comments to qc.borland.com/wc/qcmain.aspx I think that you have just discovered some problems with floating point numbers that many of us have long since learned to live with. Regards, JohnH |
| John Herbster
Delphi Developer |
2006-04-12 09:00:05 AM
Re:[WL] QC rating
"Brad White" <bwhite at inebraska.com>wrote
QuoteStore a few odd integers in floats. up about 2^<number of bits in mantissa>will be stored without any error. For type extended, that is about 19-20 decimal digits. Regards, JohnH |
| Serge Dosyukov (Dragon Soft)
Delphi Developer |
2006-04-12 09:50:45 PM
Re:[WL] QC ratingQuote>Precision problem does not appear until you start to add/mutliply/etc. QuoteThis is just theory, but I don't have time to try |
| Serge Dosyukov (Dragon Soft)
Delphi Developer |
2006-04-12 09:56:02 PM
Re:[WL] QC rating
Thank you for your comment, when more information appear (from Brad) I will
extend a project. Yes, I know it is an "legacy" problem, and we live with them... but it is exactly my point - why should we? I hate work around and I will never agree with someone who is saying that "since it is known problem and it has work around then lets just leave it alone". If it is a problem (no matter how old is it) and it is reproducible, then record it, open it and let it flow in the pipe. If people think it is important then they will rate it high and have chance to fix it... thank you, guys, for all your help QuoteI have added my comments to |
| John Herbster
Delphi Developer |
2006-04-12 10:41:56 PM
Re:[WL] QC rating
"Serge Dosyukov (Dragon Soft)" wrote
QuoteYes, I know it is an "legacy" problem, and we live with them... but it is with limited number of digits, make sure that the limited-digits values and the programs variables and data storage mechanisms can hold the complete range of allowed values *exactly*. Or (2) Make sure that the values in their transformations into and out of the data storage mechanisms can be from end-to-end exactly without corruption, even if though the in-between storage values are not exactly correct. --JohnH |
| John Herbster
Delphi Developer |
2006-04-12 11:30:26 PM
Re:[WL] QC rating
Correction:
I have added my comments to qc.borland.com/wc/qcmain.aspx Also see qc.borland.com/wc/qcmain.aspx qc.borland.com/wc/qcmain.aspx --JohnH |
| Sebastian Modersohn
Delphi Developer |
2006-04-13 02:59:10 AM
Re:[WL] QC ratingQuote>>I am not ignoring your point but in real life one does not always gets converted into the string. Since that part would come from your C# app, it would be quite interesting to see if its happening there too. Quoteif you are on the verge between 1st half an hour and next then 1 your needs. HTH |
| Sebastian Modersohn
Delphi Developer |
2006-04-13 03:06:40 AM
Re:[WL] QC ratingQuoteYes, I know it is an "legacy" problem, and we live with them... but it is something different than a float to represent a date/timestamp and I don't think this is what you are suggesting. QuoteI hate work around and I will never agree with someone who is saying that be a fix. QuoteIf people think it is important then they will rate it high and have it reproducible etc. Regards |
| Serge Dosyukov (Dragon Soft)
Delphi Developer |
2006-04-13 03:23:27 AM
Re:[WL] QC ratingQuoteBecause you can't fix it? You are experiencing problems which are significant digits which happens to be the same for the functions when rounded Quote>I hate work around and I will never agree with someone who is saying that Quote>If people think it is important then they will rate it high and have implemented. |
