Forum Discussion

acioffarelli's avatar
12 months ago

Share Open to collect logs Python script errors

Hello i'm working on a 5250 appliance but when i try to open the share to collect the logs an error is returned (three, really).

The error seems related to an indentation issue in the executed python scripts...details in the attached screenshot.

Have you ever seen an error like this? Can i solve this myself?

Thank you!

1 Reply

  • Yes, I have seen errors like this before. They are usually caused by indentation errors in Python code. Indentation errors can be difficult to spot, but there are a few things you can do to check for them.

    • First, make sure that you are using the correct indentation style for Python. The most common style is called "four spaces", which means that each level of indentation should be four spaces.
    • Second, you can use a code editor that has syntax highlighting for Python. This will help you to identify any indentation errors in your code.
    • Third, you can run your code through a Python linter. A linter is a tool that checks your code for errors, including indentation errors.

    If you have checked for indentation errors and you are still getting the error, then you may need to consult with a Python expert. They will be able to help you to identify and fix the error.

    Here are the steps on how to fix the indentation error in your Python code:

    1. Open the Python code in a code editor.
    2. Enable the option that shows the tab and whitespaces.
    3. Identify the lines of code that are indented incorrectly.
    4. Fix the indentation errors by adding or removing spaces.
    5. Save the Python code and run it again.

    The error should now be fixed.

    Here is a link to a tutorial on how to fix indentation errors in Python:

    I hope this helps!