Azure / Azure/MachineLearningNotebooks

BUG: PythonScriptStep arguments wrongly encodes strings with semicolons

Open
#1,536 4 comments 0 reactions 0 assignees View on GitHub
ADO product-issue
Dominant language
Jupyter Notebook
Stars
4.4k
Forks
2.6k
PR merge metrics
No merged PRs in 30d

Description

I am passing a string to the `arguments` of a `PythonScriptStep`. Specifically, I am passing a blob storage connection string that has semicolons in it (e.g, `DefaultEndpointsProtocol=http;AccountName=xxx;AccountKey=xxxxxx;`):

```python
PythonScriptStep(
name=...,
source_directory=...,
script_name=''script.py',
compute_target=...,
arguments=[
...
"--connection_string",
"DefaultEndpointsProtocol=http;AccountName=xxx;AccountKey=xxxxxx;",
],
runconfig=...
)
```
The problem is that `script.py` will receive a wrongly encoded string, where each semicolon is escaped by a slash: `"DefaultEndpointsProtocol=http\;AccountName=xxx\;AccountKey=xxxxxx\;"`. I tried to run `script.py` locally and it works perfectly. I suspect there is a problem with parsing the arguments in `PythonScriptStep`

---
#### Document Details

⚠ *Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.*

* ID: 1411eede-5d88-1a8e-0ddf-2dc0ceea4f0e
* Version Independent ID: 6b5a0467-67a8-674a-a569-a8865e6cb400
* Content: [azureml.pipeline.steps.python_script_step.PythonScriptStep class - Azure Machine Learning Python](https://docs.microsoft.com/en-us/python/api/azureml-pipeline-steps/azureml.pipeline.steps.python_script_step.pythonscriptstep?view=azure-ml-py)
* Content Source: [AzureML-Docset/stable/docs-ref-autogen/azureml-pipeline-steps/azureml.pipeline.steps.python_script_step.PythonScriptStep.yml](https://github.com/MicrosoftDocs/MachineLearning-Python-pr/blob/live/AzureML-Docset/stable/docs-ref-autogen/azureml-pipeline-steps/azureml.pipeline.steps.python_script_step.PythonScriptStep.yml)
* Service: **machine-learning**
* Sub-service: **core**
* GitHub Login: @DebFro
* Microsoft Alias: **debfro**

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.