Skip to content

TypeError: post() takes from 1 to 3 positional arguments but 5 were given #30

@gglconveste

Description

@gglconveste

Description

Hi, a colleague and I have been working on a script that extracts text from image files (.png)

For that he (colleague) has been using the method computervision_client.recognize_printed_text_in_stream().

Since last Thursday, Feb-25-2021, this method stopped working properly.

When called, it generates the following error:

TypeError Traceback (most recent call last)
in
----> 1 ocr_result_local = computervision_client.recognize_printed_text_in_stream(image=open(contrato, "rb" ))

/anaconda/envs/azureml_py36/lib/python3.6/site-packages/azure/cognitiveservices/vision/computervision/operations/_computer_vision_client_operations.py in recognize_printed_text_in_stream(self, image, detect_orientation, language, custom_headers, raw, callback, **operation_config)
1406
1407 # Construct and send request
-> 1408 request = self._client.post(url, query_parameters, header_parameters, body_content)
1409 response = self._client.send(request, stream=False, **operation_config)
1410

TypeError: post() takes from 1 to 3 positional arguments but 5 were given

In which platform does it happen?

Azure Machine Learning Studio

How do we replicate the issue?

Just try to use the module: computervision_client.recognize_printed_text_in_stream()

Expected behavior (i.e. solution)

It should extract text from an image file.

Other Comments

I saw that something similar occurred here: microsoft/botbuilder-python#93

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions