-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Importing/exporting CSV/HTML with dates does not work as expected #5831
Comments
This is already fixed, will be part of 2.6.3 |
Thank you for your quick response but I respectfully disagree. After testing on the following version: KeePassXC - Version 2.7.0-snapshot
The timestamp in seconds is much more problematic than the time in ISO 8601, This is a compatibility issue with other programs. Please reconsider this portion of the code :) Would you accept a PR on this? |
We are not making further changes to the date format acceptability. There is a live preview to confirm the import, so yes there is a warning of sorts. There is no such thing as csv compatibility, everyone does there own thing, you have to confirm the data on your end to achieve success. Documentation will be updated based on your feedback. |
I am not aware of any form of unix time that has a decimal or comma in it, the whole point is millisecond precision based off of jan 1, 1970 start point. |
Thought about this a little more, I would accept a pr that converts a seconds timestamp with decimal to milliseconds timestamp, as well as strips the milliseconds from iso format. |
Overview
Problems/missing doc during the import/export of dates in CSV and HTML files.
Steps to Reproduce
Expected Behavior
Dates are exported properly according to Improve CSV export and import capability #5346
ISO 8601 (Ex: 2018-01-02T22:08:12.510696) is quite cumbersome and maybe not used by many softwares.
Timestamps in milliseconds and seconds are widely used.
Thus the importer should be tolerant to such values (See Importing CSV with modified or created dates does not work as expected #4557 discussion)
Note also that the value of a timestamp in seconds is not necessarily an integer;
if it's derived from timestamp in milliseconds, it's a decimal number (the separator of which can be a period (
.
) or a comma (,
) depending on the country).Thus, the following regex are not sufficient:
keepassxc/src/gui/csvImport/CsvImportWidget.cpp
Line 225 in 56c4967
keepassxc/src/gui/csvImport/CsvImportWidget.cpp
Line 236 in 56c4967
When date fields are not properly parsed the current date is used,
which is great but the user should be warned about this.
Warned about this behavior or better: about the fact that parsing is failing.
This would avoid having to notice the problem after importing.
Finally, the most important thing; the expected types should be specified in the official documentation:
https://keepassxc.org/docs/KeePassXC_UserGuide.html#_importing_csv_file
The user should not have to go through the issues to get the information.
Actual Behavior
which is the export format used by Firefox Lockwise (the default password manager of Firefox).
Context
KeePassXC - 2.6.2
Revision: e9b9582
Operating System: Linux
Desktop Env: KDE
Windowing System: X11
The text was updated successfully, but these errors were encountered: