What about
try:
        file_location = os.path.join(request.folder, 'views','plot')

 except Exception as error:
    print (error)

El lun., 1 de jul. de 2019 23:47, Quang Lam <[email protected]>
escribió:

> Hi All, i try to do the try - exception - finally for os.path.join how
> somehow it does not catch the error. Please help
>
>  try:
>         file_location = os.path.join(request.folder, 'views','plot')
>         raise OSError
>     except OSError as error:
>     print (error)
>
> --
> Resources:
> - http://web2py.com
> - http://web2py.com/book (Documentation)
> - http://github.com/web2py/web2py (Source code)
> - https://code.google.com/p/web2py/issues/list (Report Issues)
> ---
> You received this message because you are subscribed to the Google Groups
> "web2py-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/web2py/bd443e12-6318-46ae-a8c9-6228e15e3a21%40googlegroups.com
> <https://groups.google.com/d/msgid/web2py/bd443e12-6318-46ae-a8c9-6228e15e3a21%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/web2py/CA%2Bs%2BuJss6Fmh3BsRD7jpjL2NjzQEwFVr2P3S1hpk_gr5p%3DH4MA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to