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

Please add CRUD methods to RangeWithAddressRequestBuilder subclass and please re-add "values" property to WorkbookRange subclass #844

Open
dianalingtung opened this issue Aug 5, 2024 · 3 comments
Assignees
Labels
priority:p2 Medium. For a p2 bug, generally have a work-around. Bug SLA <=30 days type:feature New experience request type:investigation Investigation work, output should be a document detailing findings or a prototype

Comments

@dianalingtung
Copy link

Is your feature request related to a problem? Please describe the problem.

With version 1.5.4, I am unable to perform CRUD operations against a user-defined Excel worksheet range address (i.e., A1:B2) using the RangeWithAddressRequestBuilder and WorkbookRange subclasses in the Python SDK. Specifically, I am unable to read, update, and delete Excel worksheet cell data in a user-defined range address. Please note that I am able to perform these actions using Graph Explorer.

Describe the solution you'd like.

  1. Can PATCH and DELETE methods be added to the RangeWithAddressRequestBuilder subclass?
  2. Can the "values" property be re-added to the WorkbookRange subclass?

Additional context?

  1. Currently, the RangeWithAddressRequestBuilder subclass has methods to build a GET request that is sent to the MS Graph API, but this subclass does not have update or delete methods to send PATCH or DELETE requests.

  2. In the recently updated Python SDK, the WorkbookRange subclass no longer contains the "values" property. Previously, with the "values" property, a GET request could be sent to retrieve raw values from a given Excel range address in the Python SDK. Now that the "values" property is no longer in the WorkbookRange subclass, a user can no longer submit a GET request for raw values at a given range address.

@dianalingtung dianalingtung added status:waiting-for-triage An issue that is yet to be reviewed or assigned type:feature New experience request labels Aug 5, 2024
@shemogumbe shemogumbe added type:investigation Investigation work, output should be a document detailing findings or a prototype priority:p2 Medium. For a p2 bug, generally have a work-around. Bug SLA <=30 days and removed status:waiting-for-triage An issue that is yet to be reviewed or assigned labels Aug 9, 2024
@shemogumbe
Copy link
Collaborator

Hello @dianalingtung thanks for raising this.

On Values property: - this was removed as it gave challenges with serialization considering the type information was wrong, the values property for now can be obtained from the additional_data

@dianalingtung
Copy link
Author

dianalingtung commented Aug 9, 2024

Hello @dianalingtung thanks for raising this.

On Values property: - this was removed as it gave challenges with serialization considering the type information was wrong, the values property for now can be obtained from the additional_data

@shemogumbe Shem,

Thank you for the response.

While the values property can be obtained from the additional_data property for now, is there any chance you could add PATCH and DELETE methods for the RangeWithAddressRequestBuilder? Is there an alternative request builder method that could be called to PATCH/DELETE (for example by referencing a raw Graph API call)?

Thank you,

Diana

@dianalingtung
Copy link
Author

dianalingtung commented Oct 30, 2024

Hi,

Is there any update on this request? I would like to bring data into an Excel spreadsheet using the patch method with the Python SDK.

I can execute the following in Graph Explorer but am unable to do so in the Python SDK using additional_data. Since the RangeWithAddressRequestBuilder does not have a patch method (it currently only has a get method), is there another method that can be called for this type of request?

Request: https://graph.microsoft.com/v1.0/drives/{drive id}/items/{drive item id}/workbook/worksheets/{worksheet id}/range(address='A1')

Request body: {"values": [["hello"]]}

Edited: I am able to send a single request to patch one value to an Excel range. I would like to know if additional_data can be used to patch a list of data such as:

{"values": [["hello"], ["bye"]]}

If so, how should the additional_data be written for the following code in Python?

request_body = File(additional_data={data here})

Thank you,

Diana

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
priority:p2 Medium. For a p2 bug, generally have a work-around. Bug SLA <=30 days type:feature New experience request type:investigation Investigation work, output should be a document detailing findings or a prototype
Projects
None yet
Development

No branches or pull requests

3 participants