# Enviro+ bme280 Library import in Weather.py

**URL:** https://forums.pimoroni.com/t/enviro-bme280-library-import-in-weather-py/10939
**Category:** Support
**Created:** [July 11, 2019, 4:12am UTC](https://forums.pimoroni.com/t/enviro-bme280-library-import-in-weather-py/10939 "2019-07-11T04:12:40Z")
**Posts on this page:** 10
**Page:** 1

<div class="post-metadata">

### Author: ![DavidL](https://avatars.discourse-cdn.com/v4/letter/d/ecc23a/32.png) [@DavidL](https://forums.pimoroni.com/u/DavidL)
#### Post date: [July 11, 2019, 4:12am UTC](https://forums.pimoroni.com/t/enviro-bme280-library-import-in-weather-py/10939/1 "2019-07-11T04:12:40Z")

</div>

I have just received an Enviro+ and following the “Getting started” instructions. I am using a Pi Zero running Raspbian Jessie. When I try to run the weather.py example I get the following

pi@raspberrypi:~/enviroplus-python/examples $ python weather.py  
Traceback (most recent call last):  
File “weather.py”, line 4, in   
from bme280 import BME280  
ImportError: No module named bme280

Looks like I need to install the bme280 library manually as it does not happen during the install script.

git clone [https://github.com/pimoroni/enviroplus-python](https://github.com/pimoroni/enviroplus-python)  
cd enviroplus-python  
sudo ./install.sh

Where do I get the bme280 library?

---

<div class="post-metadata">

### Author: ![DavidL](https://avatars.discourse-cdn.com/v4/letter/d/ecc23a/32.png) [@DavidL](https://forums.pimoroni.com/u/DavidL)
#### Post date: [July 11, 2019, 4:30am UTC](https://forums.pimoroni.com/t/enviro-bme280-library-import-in-weather-py/10939/2 "2019-07-11T04:30:57Z")

</div>

Fixed!!

Found a Pimoroni bme280 library in github and installed it from there.For anyone else having this problem. Install the library as per the following.

git clone [https://github.com/pimoroni/bme280-python](https://github.com/pimoroni/bme280-python)  
cd bme280-python  
sudo ./install.sh

I also found you have to manually install the light and the PMS5003 libraries. The gas library is missing and can’t find it in the list of libraries.

Cheers

---

<div class="post-metadata">

### Author: ![alphanumeric](https://sea2.discourse-cdn.com/flex016/user_avatar/forums.pimoroni.com/alphanumeric/32/2729_2.png) [@alphanumeric](https://forums.pimoroni.com/u/alphanumeric)
#### Post date: [July 11, 2019, 11:06am UTC](https://forums.pimoroni.com/t/enviro-bme280-library-import-in-weather-py/10939/3 "2019-07-11T11:06:42Z")

</div>

`curl -sSL https://get.pimoroni.com/enviroplus | bash`

Should install everything needed?

---

<div class="post-metadata">

### Author: ![DavidL](https://avatars.discourse-cdn.com/v4/letter/d/ecc23a/32.png) [@DavidL](https://forums.pimoroni.com/u/DavidL)
#### Post date: [July 11, 2019, 11:41am UTC](https://forums.pimoroni.com/t/enviro-bme280-library-import-in-weather-py/10939/4 "2019-07-11T11:41:24Z")

</div>

Thanks. Will give it a go.

Maybe the tutorial which uses

```auto
git clone https://github.com/pimoroni/enviroplus-python
cd enviroplus-python
sudo ./install.sh

```

needs to be updated. Many hours wasted.

---

<div class="post-metadata">

### Author: ![gadgetoid](https://sea2.discourse-cdn.com/flex016/user_avatar/forums.pimoroni.com/gadgetoid/32/13_2.png) [@gadgetoid](https://forums.pimoroni.com/u/gadgetoid)
#### Post date: [July 11, 2019, 11:53am UTC](https://forums.pimoroni.com/t/enviro-bme280-library-import-in-weather-py/10939/5 "2019-07-11T11:53:24Z")

</div>

This is really bizarre, since the bme280 library is a dependency of the enviroplus installer… oh dear I wonder if I’ve broken something by having the `install_requires` in `setup.py` but also having a `setup.cfg`

> <https://github.com/pimoroni/enviroplus-python/blob/master/library/setup.py#L35>

---

<div class="post-metadata">

### Author: ![DavidL](https://avatars.discourse-cdn.com/v4/letter/d/ecc23a/32.png) [@DavidL](https://forums.pimoroni.com/u/DavidL)
#### Post date: [July 11, 2019, 12:28pm UTC](https://forums.pimoroni.com/t/enviro-bme280-library-import-in-weather-py/10939/6 "2019-07-11T12:28:47Z")

</div>

Yes

curl -sSL [https://get.pimoroni.com/enviroplus](https://get.pimoroni.com/enviroplus) | bash  
works with all libraries now accessible.

Bit hard to keep my mind on this topic with the poms in a good position against the aussies in the World Cup at the moment. Cheers

---

<div class="post-metadata">

### Author: ![alphanumeric](https://sea2.discourse-cdn.com/flex016/user_avatar/forums.pimoroni.com/alphanumeric/32/2729_2.png) [@alphanumeric](https://forums.pimoroni.com/u/alphanumeric)
#### Post date: [July 11, 2019, 1:37pm UTC](https://forums.pimoroni.com/t/enviro-bme280-library-import-in-weather-py/10939/7 "2019-07-11T13:37:10Z")

</div>

Thats good to hear. Now you can have some fun with your Enviro +.

---

<div class="post-metadata">

### Author: ![gadgetoid](https://sea2.discourse-cdn.com/flex016/user_avatar/forums.pimoroni.com/gadgetoid/32/13_2.png) [@gadgetoid](https://forums.pimoroni.com/u/gadgetoid)
#### Post date: [July 12, 2019, 8:18pm UTC](https://forums.pimoroni.com/t/enviro-bme280-library-import-in-weather-py/10939/8 "2019-07-12T20:18:03Z")

</div>

I’ve updated the library’s setup.cfg to - hopefully - prevent this happening. This is what I get for rolling out experimental packaging improvements to a popular new software repository.

---

<div class="post-metadata">

### Author: ![alphanumeric](https://sea2.discourse-cdn.com/flex016/user_avatar/forums.pimoroni.com/alphanumeric/32/2729_2.png) [@alphanumeric](https://forums.pimoroni.com/u/alphanumeric)
#### Post date: [July 12, 2019, 8:34pm UTC](https://forums.pimoroni.com/t/enviro-bme280-library-import-in-weather-py/10939/9 "2019-07-12T20:34:30Z")

</div>

Phil, I for one appreciate everything you do. Making mistakes just proves your human, lol. :P =)

---

<div class="post-metadata">

### Author: ![theslop](https://avatars.discourse-cdn.com/v4/letter/t/c6cbf5/32.png) [@theslop](https://forums.pimoroni.com/u/theslop)
#### Post date: [December 11, 2019, 9:44pm UTC](https://forums.pimoroni.com/t/enviro-bme280-library-import-in-weather-py/10939/10 "2019-12-11T21:44:56Z")

</div>

Just a quick add as I have just hacked my new Enviro+ into existance and in case any other newbies are struggling.

Don’t use the **git clone** approach that is in the Getting started article, use the **curl**

There is still one error in the script, installing the modules for python3. You might not notice as all the examples are for python.

To fix this run the extra command

```
$ python3 -m pip install pimoroni-bme280 pms5003 ltr559 st7735 ads1015

```

This installs the modules for python3

It is a great bit of kit and I will do a better write up later.
