Skip to content

Make RegexGenerator generate unique values on consecutive reverse_transform calls - #1096

Open
fealho wants to merge 1 commit into
mainfrom
issue-1091-regex-generator-uniqueness
Open

Make RegexGenerator generate unique values on consecutive reverse_transform calls #1096
fealho wants to merge 1 commit into
mainfrom
issue-1091-regex-generator-uniqueness

Conversation

@fealho

@fealho fealho commented Jul 29, 2026

Copy link
Copy Markdown
Member

CU-86bav75gd, Resolve #1091

@sdv-team

Copy link
Copy Markdown
Contributor

@fealho
fealho force-pushed the issue-1091-regex-generator-uniqueness branch from 57fd749 to 317429a Compare July 29, 2026 17:05
@fealho
fealho marked this pull request as ready for review July 29, 2026 17:06
@fealho
fealho requested a review from a team as a code owner July 29, 2026 17:06
@fealho
fealho requested review from amontanez24 and frances-h and removed request for a team July 29, 2026 17:06
@codecov

codecov Bot commented Jul 29, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 100.00%. Comparing base (00f1bba) to head (ba4f0e6).

Additional details and impacted files
@@            Coverage Diff            @@
##              main     #1096   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           19        19           
  Lines         2718      2733   +15     
=========================================
+ Hits          2718      2733   +15     
Flag Coverage Δ
integration 84.12% <89.47%> (+0.16%) ⬆️
unit 100.00% <100.00%> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@fealho
fealho force-pushed the issue-1091-regex-generator-uniqueness branch from 317429a to ba4f0e6 Compare July 29, 2026 17:11
@fealho
fealho requested review from pvk-developer and removed request for amontanez24 July 29, 2026 17:18

@pvk-developer pvk-developer left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think that this introduced a bug with categorical values:

transformer = RegexGenerator(regex_format='[A-Da-d]', cardinality_rule='unique')
transformer.fit(pd.DataFrame(columns=['id']), 'id')
samples = pd.concat([transformer.reverse_transform(pd.DataFrame(index=[0])) for i in range(50)])['id']

samples
# output 
0                                                    A
0                                                    B
0                                                    C
0                                                    D
0                                                    a
0                                                    b
0                                                    c
0                                                    d
0                                                 d(0)
0                                              d(0)(0)
0                                           d(0)(0)(0)
........

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

RegexGenerator not generating unique values on consecutive reverse_transform calls

3 participants