MsJackson
MsJackson

Reputation: 1

How to fix IndentationError: unindent does not match any outer indentation level

i am getting this error File "ad.py", line 132 else : ^ IndentationError: unindent does not match any outer indentation level

what do i have to change? i am actually kinda new thanks

                        print("ACCOUNT WAS BANIDA!")
                        break
                    except UserChannelsTooMuchError:
                        print('userbe many groups.')
                else :
                    ja_adicionado += 1
                    print('Already added:{}'.format(ja_adicionado))
                    continue
            else :        
                ja_adicionado += 1
                print("{} is already in the group.".format(user['name']))
                continue
        if user == users[-1]:
            print('LIST FINISHED!')

Upvotes: -1

Views: 1538

Answers (3)

Renu
Renu

Reputation: 35

It might because continue is only allowed within a for or while loop. A more recent version of python raise a syntax error when modules containing break or continue outside of a loop are imported.

Upvotes: 0

MsJackson
MsJackson

Reputation: 1

thanks about the answear, have you know to solve this error that im getting ?

SyntaxError: 'continue' not properly in loop

lines: else :
ja_adicionado += 1 print("{} is already in the group.".format(user['name'])) continue if user == users[-1]: print('LIST FINISHED!')

Upvotes: 0

Renu
Renu

Reputation: 35

There might be spaces mixed in with your tab. This will cause that error. Configure your editor to use space only for indentation.

Upvotes: 1

Related Questions