Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
A
anonymizer
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Wiki
Redmine
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
nlpworkers
anonymizer
Commits
1809724f
There was an error fetching the commit references. Please try again later.
Commit
1809724f
authored
1 year ago
by
Paweł Walkowiak
Browse files
Options
Downloads
Patches
Plain Diff
Add if
parent
b4d3bcf8
1 merge request
!13
Fix anonymizer errors
Pipeline
#15181
passed with stages
Stage:
Stage:
Stage:
in 1 minute and 35 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/replacers/date_replacer.py
+3
-2
3 additions, 2 deletions
src/replacers/date_replacer.py
with
3 additions
and
2 deletions
src/replacers/date_replacer.py
+
3
−
2
View file @
1809724f
...
...
@@ -95,11 +95,12 @@ class DateReplacer(ReplacerInterface):
month_name
=
months_map
[
random_month
]
replacement
.
append
(
month_name
)
elif
entry
[
0
]
==
DateDetection
.
AnnotationPart
.
OTHER
:
replacement
.
append
(
entry
[
1
])
if
entry
[
1
]
is
not
None
:
replacement
.
append
(
entry
[
1
])
else
:
raise
ValueError
(
f
"
Unknown format entry:
{
entry
}
"
)
_log
.
debug
(
f
"
entry
{
entry
}
replacement:
{
replacement
[
-
1
]
}
"
)
_log
.
debug
(
f
"
replacement:
{
replacement
}
"
)
replacement
=
""
.
join
(
replacement
)
already_replaced
[
text
[
start
:
end
]]
=
replacement
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment