How to isolate a soil moisture sensor
As discussed in comments, providing that the power source is capable of low amounts of power and there are no components that are likely to store energy (that can generate a spark) there will be no ignition or surface temperature side-effects that could ignite even the most volatile of gases such as hydrogen (19uJ) to ignite in the perfect gas-oxygen mix.

The cable feeding the sensor will have inductance but it is likely to be less than a ten microhenries BUT what is the chance that hydogen will be around? It would need a minimum of 40uH with 1A flowing from the battery pack to be potentially unsafe. This circuit would then need to be broken to produce a spark. No chance. If hydrogen is present then what sort of plants are you cultivating?

You might have some petrol around but you'd need a lot bigger energy spark than for hydrogen (the most volatile of the gases to sparks) but you could ignite petrol with a surface temperature of 250ºC however, this is unlikely to be produced by the sensor circuit and the 4AA batteries.

If you can't ignite the most volatile of gases and fluids with energy or hot surfaces you won't ignite anything known to man. 

If you don't believe look up Intrinsic Safety techniques and look out for iginition temperatures of the most volatile gases and also check for hot surface temperatures.

Here is a simple site that should convey the basic principles