mauza opened a new pull request #9773:
URL: https://github.com/apache/pulsar/pull/9773


   When running a python function in pulsar on a broker don't rely on the 
extension to tell if the file is a zipfile or not but use the built in 
zipfile.is_zipfile(filepath) function to check.
   
   ### Motivation
   
   Automation using the pulsar admin api saves python zip files as .py files 
which breaks when running the function on a broker because 
python_instance_main.py only checks if they file has a .zip extension for it to 
extract all the contents.
   
   ### Modifications
   
   Changed the conditional that checks for a .zip extensions to now use 
zipfile.is_zipfile
   
   ### Verifying this change
   
   - [?] Make sure that the change passes the CI checks.
   
   *(Please pick either of the following options)*
   
   This change is a trivial rework / code cleanup without any test coverage.
   
   *(or)*
   
   This change is already covered by existing tests, such as *(please describe 
tests)*.  <---- I'm guessing
   
   *(or)*
   
   This change added tests and can be verified as follows:
   
   *(example:)*
     - *Added integration tests for end-to-end deployment with large payloads 
(10MB)*
     - *Extended integration test for recovery after broker failure*
   
   ### Does this pull request potentially affect one of the following parts:
   
   *If `yes` was chosen, please highlight the changes*
   
     - Dependencies (does it add or upgrade a dependency): (no)
     - The public API: (no)
     - The schema: (no)
     - The default values of configurations: (no)
     - The wire protocol: (no)
     - The rest endpoints: (no)
     - The admin cli options: (no)
     - Anything that affects deployment: (don't know)
   
   ### Documentation
   
     - Does this pull request introduce a new feature? (no)
   
   


----------------------------------------------------------------
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.

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


Reply via email to