-
Notifications
You must be signed in to change notification settings - Fork 77
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
✨ [FEAT] Add CirkwiParser to retrieve Treks and Touristic Contents (refs #3947) #3968
Conversation
2f125da
to
5173b63
Compare
Geotrek-admin Run #10507
Run Properties:
|
Project |
Geotrek-admin
|
Branch Review |
refs/pull/3968/merge
|
Run status |
Passed #10507
|
Run duration | 02m 09s |
Commit |
70171ce990 ℹ️: Merge 5381f1e6f8c5cc3634fc4869d6155898bf63b6cb into 0fec8084eea1f82c694ac178e3cc...
|
Committer | Célia |
View all properties for this run ↗︎ |
Test results | |
---|---|
Failures |
0
|
Flaky |
0
|
Pending |
0
|
Skipped |
0
|
Passing |
22
|
View all changes introduced in this branch ↗︎ |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #3968 +/- ##
==========================================
+ Coverage 98.45% 98.46% +0.01%
==========================================
Files 267 268 +1
Lines 21106 21290 +184
==========================================
+ Hits 20780 20964 +184
Misses 326 326 ☔ View full report in Codecov by Sentry. |
6add793
to
809dfb9
Compare
809dfb9
to
76af75e
Compare
b5bc7e8
to
2431963
Compare
180ca07
to
8e94844
Compare
4be8290
to
44c8c58
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have reviewed the move of the get_geom* functions and I have added a comment. :)
8035303
to
1c70e0f
Compare
1c70e0f
to
98cf5e7
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have made a few remarks you may address.
LGTM otherwise. Nice work! 👍
src = src.replace("<LANG>", self.default_language) | ||
# Return a list of XML elements | ||
if src.endswith('/*'): | ||
return val.findall(src[:-2]) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it is possible to return directly strings here instead of a list of XML elements. This way it would work in the same way than when a single text value is returned at line 114. And you could remove all conversion done in filter_*
methods.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It gets tricky with lists here, because, what do we do after retrieving the multiple elements ? Do we need to get the list of inner texts, or a list from the attributes ? Are we looking for one or several other inner element(s) ? We would need to add some more recursivity to combine this with the other syntaxes. It's why I chose to use get_part
to return the list of elements and let filter_xxxx
handle further processing for now
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Alright, let's leave it as is then.
98cf5e7
to
5381f1e
Compare
Description
Related Issue
#3947
Checklist