This error message is seldom clear. Here the answer goes like this, basichttpbinding doesn't support session. So you have to use the below property if you want to use it.
[ServiceContract(SessionMode = SessionMode.Allowed)]
This means, If you are trying to configure multiple bindings like basichttp, wshttp, net.tcp, WCF will automatically enable session for other than basichttp binding. so if you put SessionMode.Required instead of Allowed, then you are forced not to use basichttpbinding.
That said, solving this issue usually would require something like this:
<system.serviceModel>
<protocolMapping>
<add scheme="http" binding="wsHttpBinding" bindingConfiguration="wsHttpBindingConfiguration" />
</protocolMapping>
<bindings>
<wsHttpBinding>
<binding name="wsHttpBindingConfiguration" transactionFlow="true" />
</wsHttpBinding>
.......
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…