Skip to content
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

Incorrect parameterization args to test in noisy_controlled_qpc_test.py #849

Closed
mhucka opened this issue Jan 19, 2025 · 1 comment
Closed
Assignees
Labels
area/tests Concerns tests and testing of the TFQ codebase kind/bug-report Something doesn't seem to work priority/p1 Fix is needed as soon as possible

Comments

@mhucka
Copy link
Member

mhucka commented Jan 19, 2025

There's something odd happening with the parameter value in this test in TFQ:

@parameterized.parameters([{'sample_based': True, 'sample_based': False}])

A dict is being created with the same key, but different values. In Python, that means the last assignment wins; it won't result in 2 dict entries. Therefore, that part of the code is probably wrong.

@mhucka mhucka added area/tests Concerns tests and testing of the TFQ codebase kind/bug-report Something doesn't seem to work priority/p1 Fix is needed as soon as possible labels Jan 19, 2025
@mhucka mhucka self-assigned this Jan 19, 2025
mhucka added a commit to mhucka/quantum that referenced this issue Jan 19, 2025
This fixes the incorrect `dict` being passed as an argument to the
test function `test_controlled_pqc_simple_learn`, reported in issue
tensorflow#849.
mhucka added a commit to mhucka/quantum that referenced this issue Jan 19, 2025
This fixes the incorrect `dict` being passed as an argument to the
test function `test_controlled_pqc_simple_learn`, reported in issue
tensorflow#849.
mhucka added a commit that referenced this issue Jan 21, 2025
This fixes the incorrect `dict` being passed as an argument to the test
function `test_controlled_pqc_simple_learn`, reported in issue #849.
@mhucka
Copy link
Member Author

mhucka commented Jan 23, 2025

Completed by #850

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/tests Concerns tests and testing of the TFQ codebase kind/bug-report Something doesn't seem to work priority/p1 Fix is needed as soon as possible
Development

No branches or pull requests

1 participant