Skip to content

03-packaging-installing: Improving episode. #77

@vinisalazar

Description

@vinisalazar

Hi,

there are some things I'd suggest to improve Ep03:

- Fix the ModuleNotFoundError

If I run the code in the current version of Episode 03, when I run the following line:

from conversions import temperature, speed

Assuming I'm in the conversions/ directory as instructed, I get the following error:

---------------------------------------------------------------------------
ModuleNotFoundError                       Traceback (most recent call last)
<ipython-input-4-180d6e73763d> in <module>
----> 1 from conversions import temperature, speed

ModuleNotFoundError: No module named 'conversions'

This does work, if I'm in the conversions/ directory:

from temperature import fahr_to_celsius
from speed import kph_to_ms

Not entirely sure if I am doing anything wrong.

If I open a Python terminal from the parent directory of conversions and run import sys; sys.path.append('conversions'), which is explained earlier in the episode, I can run the imports as they are currently displayed (from conversions import temperature, speed).

- Move the Pip section to somewhere else in the Episode

As described in #58, the Pip section seems a bit out of place. I'd suggest moving it somewhere else in the Episode.

I will document other things I find in this issue. May I submit a PR to address these two points in the meantime?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions