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

Critical bug: Missing argument in function call #464

Closed
philipjonsen opened this issue Sep 22, 2023 · 2 comments
Closed

Critical bug: Missing argument in function call #464

philipjonsen opened this issue Sep 22, 2023 · 2 comments

Comments

@philipjonsen
Copy link

DESCRIPTION:

A required function parameter isn't provided while calling the function. This is an error.

BAD PRACTICE:

def add_student(student, section):
students[section].append(student)

add_student("Aaron") # Missing parameter section

RECOMMENDED:

def add_student(student, section):
students[section].append(student)

add_student("Aaron", "10A")

No value for argument 'start_time' in method call can be found here: harmony/blob/main/workload/locustfile-prod.py#L113-L113

No value for argument 'name' in method call can be found here: harmony/blob/main/workload/locustfile-prod.py#L113-L113
/harmony/blob/main/workload/locustfile-prod.py#L91-L91

And so on.

goldpanth3r added a commit to goldpanth3r/harmony that referenced this issue Sep 23, 2023
goldpanth3r added a commit to goldpanth3r/harmony that referenced this issue Sep 23, 2023
@goldpanth3r
Copy link

Hey! @philipjonsen, I tried to solve this by newly creating the missing arguments and passing them into the function call similar to how it is implemented in _async_request() in harmony/blob/main/workload/harmony/common.py#L88-99.

Please take a look and guide me through, if anything needs to be changed.

@goldpanth3r
Copy link

Please ignore the previous commits. A new commit with all the required changes is added below.

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 a pull request may close this issue.

3 participants