-
Notifications
You must be signed in to change notification settings - Fork 28
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
move the xml_to_dict and msfiletime to datetime from bruker parser to utils.tools #111
move the xml_to_dict and msfiletime to datetime from bruker parser to utils.tools #111
Conversation
from bruker api to utils.date_time_tools as public function for eventual reuse in other formats.
fix typo of prev commit
Codecov ReportPatch coverage:
Additional details and impacted files@@ Coverage Diff @@
## main #111 +/- ##
==========================================
+ Coverage 85.20% 85.26% +0.05%
==========================================
Files 73 73
Lines 8991 9030 +39
Branches 2030 2045 +15
==========================================
+ Hits 7661 7699 +38
Misses 871 871
- Partials 459 460 +1
☔ View full report in Codecov by Sentry. |
make it look for it in under utils.tools rename XML2Dict into XmlToDict add more customisation of dictionarization to XmlToDict
Ok, this is kind of ready to review, few minor issues which I had spotted: |
Would it make sense to write some test specific to the cases/issues it need support for? This would make future support and development much easier. Lint is failing. For what it is worth, pre-commit configuration have been added recently in #86. I would add a changelog, because the changelog is also useful for developers, for example, to easily find when things have been done, the context, reasoning, etc. |
@ericpre, I find current lint rules to be stupid and offensive. It asks to change better formatted (more readable) code into worse formatted (less readable)! I still use older hardware for most of my work (it is not even 2k, just old 1k laptop widescreen of good old thinkpad T420), lint complains about line formatted to fit to 79 charter and want to collapse it into single line much over 80 charters. That makes it pain to have two split files opened side-by-side. One is to allow writing longer lines (up to 88, seriously?) which should be allowed exception (best would be to 120) not the rule, but forcing collapsing divided lines into single cluster***** line - that is offensive and makes it less readable - absolutely counter-productive. Who let in the Java devs setting this python lint rules? After looking around internet what this |
Regarding the usage of What do you think about writing test specific to the cases/issues it need support for? |
I think discussion section will be right place to discuss further about I will add small made up XML and tests. I think it would be good idea to create edit: I see that there is test_utils.py under |
Commit 44df588 can be removed now that ipython 8.13.0 have been yanked and 8.13.1 released. |
* added test XML file
44df588
to
bc3f1a5
Compare
All tests are passing, I think this is ready for review |
Description of the change
There are some dublication attempts spotted (i.e. XML handling) where different kind of
parsers have its own implementation.
This PR moves some of functions from bruker api to utils.functionaly_coresponding_file:
This is first step. Next step (other PR) will be format by format review if XML can be parsed using the same tools.
Progress of the PR
upcoming_changes
folder (seeupcoming_changes/README.rst
),readthedocs
doc build of this PR (link in github checks)