Slacker News Slacker News logo featuring a lazy sloth with a folded newspaper hat
  • top
  • new
  • show
  • ask
  • jobs
Library
← Back to context

Comment by graemep

10 months ago

Yes, that works if you do:

    from foo import nonexistent

but if you do:

    import foo

    foo.nonexistent()

You get a run time error.

A lot of the time with Python you will be importing classes so it will be mostly run time errors.

0 comments

graemep

Reply

No comments yet

Contribute on Hacker News ↗

Slacker News

Product

  • API Reference
  • Hacker News RSS
  • Source on GitHub

Community

  • Support Ukraine
  • Equal Justice Initiative
  • GiveWell Charities