[ 
https://issues.apache.org/jira/browse/AVRO-3162?focusedWorklogId=643132&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-643132
 ]

ASF GitHub Bot logged work on AVRO-3162:
----------------------------------------

                Author: ASF GitHub Bot
            Created on: 28/Aug/21 21:21
            Start Date: 28/Aug/21 21:21
    Worklog Time Spent: 10m 
      Work Description: kojiromike commented on a change in pull request #1270:
URL: https://github.com/apache/avro/pull/1270#discussion_r697919504



##########
File path: lang/py/avro/test/test_script.py
##########
@@ -193,26 +178,29 @@ def tearDown(self):
                 continue
 
     def _run(self, *args, **kw):
-        args = [sys.executable, SCRIPT, "write", "--schema", self.schema_file] 
+ list(args)
+        args = [sys.executable, "-m" "avro", "write", "--schema", 
self.schema_file] + list(args)

Review comment:
       Hah, this one is funny, because `python -mavro` works just as well as 
`python -m avro`, but it was a good find by the code scanner anyway.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Issue Time Tracking
-------------------

            Worklog Id:     (was: 643132)
    Remaining Estimate: 0h
            Time Spent: 10m

> Update Python CLI Argument Handling
> -----------------------------------
>
>                 Key: AVRO-3162
>                 URL: https://issues.apache.org/jira/browse/AVRO-3162
>             Project: Apache Avro
>          Issue Type: Improvement
>          Components: python
>    Affects Versions: 1.10.2
>            Reporter: Michael A. Smith
>            Assignee: Michael A. Smith
>            Priority: Major
>          Time Spent: 10m
>  Remaining Estimate: 0h
>
> Avro python has several modules that use commandline arguments via sys.argv 
> or the outdated optparse library. I propose to replace all of that using the 
> up-to-date argparse library.
> Also, I would like to move scripts/avro into {{avro/__main__.py}}, so that 
> {{{{python -m avro}}}} invokes it directly, and so that all the avro python 
> code is in the same directory tree.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to