File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -18,10 +18,12 @@ matrix:
1818 os : osx
1919 osx_image : xcode10.2
2020 language : shell
21+ env :
22+ - PIPFLAG="--user"
2123before_install :
2224 - make build
2325install :
24- - pip3 install dist/*.whl
26+ - pip3 install dist/*.whl $PIPFLAG
2527script :
2628 - make lint
2729 - make tests
Original file line number Diff line number Diff line change 2828# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
2929
3030import logging
31- import os
3231
3332from simulaqron .local .setup import setup_local
3433from simulaqron .general .hostConfig import socketsConfig
35- from simulaqron .toolbox import get_simulaqron_path
34+ from simulaqron .settings import simulaqron_settings
3635from twisted .internet .defer import inlineCallbacks
3736from twisted .internet import reactor
3837from twisted .spread import pb
@@ -120,14 +119,13 @@ def main():
120119 myName = "Alice"
121120
122121 # This file defines the network of virtual quantum nodes
123- simulaqron_path = get_simulaqron_path .main ()
124- virtualFile = os .path .join (simulaqron_path , "config/virtualNodes.cfg" )
122+ network_file = simulaqron_settings .network_config_file
125123
126124 # This file defines the nodes acting as servers in the classical communication network
127125 classicalFile = "classicalNet.cfg"
128126
129127 # Read configuration files for the virtual quantum, as well as the classical network
130- virtualNet = socketsConfig (virtualFile )
128+ virtualNet = socketsConfig (network_file )
131129 classicalNet = socketsConfig (classicalFile )
132130
133131 # Check if we should run a local classical server. If so, initialize the code
Original file line number Diff line number Diff line change 2929
3030
3131import logging
32- import os
3332
3433from simulaqron .local .setup import setup_local
3534from simulaqron .general .hostConfig import socketsConfig
36- from simulaqron .toolbox import get_simulaqron_path
35+ from simulaqron .settings import simulaqron_settings
3736from twisted .internet .defer import inlineCallbacks
3837from twisted .spread import pb
3938
@@ -129,14 +128,13 @@ def main():
129128 myName = "Bob"
130129
131130 # This file defines the network of virtual quantum nodes
132- simulaqron_path = get_simulaqron_path .main ()
133- virtualFile = os .path .join (simulaqron_path , "config/virtualNodes.cfg" )
131+ network_file = simulaqron_settings .network_config_file
134132
135133 # This file defines the nodes acting as servers in the classical communication network
136134 classicalFile = "classicalNet.cfg"
137135
138136 # Read configuration files for the virtual quantum, as well as the classical network
139- virtualNet = socketsConfig (virtualFile )
137+ virtualNet = socketsConfig (network_file )
140138 classicalNet = socketsConfig (classicalFile )
141139
142140 # Check if we should run a local classical server. If so, initialize the code
Original file line number Diff line number Diff line change 2727# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
2828# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
2929
30- import logging
3130import os
31+ import logging
3232
3333from simulaqron .local .setup import setup_local
3434from simulaqron .general .hostConfig import socketsConfig
35- from simulaqron .toolbox import get_simulaqron_path
35+ from simulaqron .settings import simulaqron_settings
3636from twisted .internet .defer import inlineCallbacks
3737from twisted .spread import pb
3838from twisted .internet import reactor
@@ -121,14 +121,13 @@ def main():
121121 myName = "Alice"
122122
123123 # This file defines the network of virtual quantum nodes
124- simulaqron_path = get_simulaqron_path .main ()
125- virtualFile = os .path .join (simulaqron_path , "config/virtualNodes.cfg" )
124+ network_file = simulaqron_settings .network_config_file
126125
127126 # This file defines the nodes acting as servers in the classical communication network
128127 classicalFile = os .path .join (os .path .dirname (__file__ ), "classicalNet.cfg" )
129128
130129 # Read configuration files for the virtual quantum, as well as the classical network
131- virtualNet = socketsConfig (virtualFile )
130+ virtualNet = socketsConfig (network_file )
132131 classicalNet = socketsConfig (classicalFile )
133132
134133 # Check if we should run a local classical server. If so, initialize the code
Original file line number Diff line number Diff line change 2727# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
2828# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
2929
30- import logging
3130import os
31+ import logging
3232
3333from simulaqron .local .setup import setup_local
3434from simulaqron .general .hostConfig import socketsConfig
35- from simulaqron .toolbox import get_simulaqron_path
35+ from simulaqron .settings import simulaqron_settings
3636from twisted .internet .defer import inlineCallbacks
3737from twisted .spread import pb
3838
@@ -128,14 +128,13 @@ def main():
128128 myName = "Bob"
129129
130130 # This file defines the network of virtual quantum nodes
131- simulaqron_path = get_simulaqron_path .main ()
132- virtualFile = os .path .join (simulaqron_path , "config/virtualNodes.cfg" )
131+ network_file = simulaqron_settings .network_config_file
133132
134133 # This file defines the nodes acting as servers in the classical communication network
135134 classicalFile = os .path .join (os .path .dirname (__file__ ), "classicalNet.cfg" )
136135
137136 # Read configuration files for the virtual quantum, as well as the classical network
138- virtualNet = socketsConfig (virtualFile )
137+ virtualNet = socketsConfig (network_file )
139138 classicalNet = socketsConfig (classicalFile )
140139
141140 # Check if we should run a local classical server. If so, initialize the code
Original file line number Diff line number Diff line change 2727# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
2828# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
2929
30- import logging
3130import os
31+ import logging
3232
3333from simulaqron .local .setup import setup_local
3434from simulaqron .general .hostConfig import socketsConfig
35- from simulaqron .toolbox import get_simulaqron_path
35+ from simulaqron .settings import simulaqron_settings
3636from twisted .internet .defer import inlineCallbacks
3737from twisted .spread import pb
3838
@@ -114,14 +114,13 @@ def main():
114114 myName = "Charlie"
115115
116116 # This file defines the network of virtual quantum nodes
117- simulaqron_path = get_simulaqron_path .main ()
118- virtualFile = os .path .join (simulaqron_path , "config/virtualNodes.cfg" )
117+ network_file = simulaqron_settings .network_config_file
119118
120119 # This file defines the nodes acting as servers in the classical communication network
121120 classicalFile = os .path .join (os .path .dirname (__file__ ), "classicalNet.cfg" )
122121
123122 # Read configuration files for the virtual quantum, as well as the classical network
124- virtualNet = socketsConfig (virtualFile )
123+ virtualNet = socketsConfig (network_file )
125124 classicalNet = socketsConfig (classicalFile )
126125
127126 # Check if we should run a local classical server. If so, initialize the code
Original file line number Diff line number Diff line change 2828# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
2929
3030
31- import logging
3231import os
32+ import logging
3333
3434from simulaqron .local .setup import setup_local
3535from simulaqron .general .hostConfig import socketsConfig
36- from simulaqron .toolbox import get_simulaqron_path
36+ from simulaqron .settings import simulaqron_settings
3737from twisted .internet .defer import inlineCallbacks
3838from twisted .spread import pb
3939from twisted .internet import reactor
@@ -138,14 +138,13 @@ def main():
138138 myName = "Alice"
139139
140140 # This file defines the network of virtual quantum nodes
141- simulaqron_path = get_simulaqron_path .main ()
142- virtualFile = os .path .join (simulaqron_path , "config/virtualNodes.cfg" )
141+ network_file = simulaqron_settings .network_config_file
143142
144143 # This file defines the nodes acting as servers in the classical communication network
145144 classicalFile = os .path .join (os .path .dirname (__file__ ), "classicalNet.cfg" )
146145
147146 # Read configuration files for the virtual quantum, as well as the classical network
148- virtualNet = socketsConfig (virtualFile )
147+ virtualNet = socketsConfig (network_file )
149148 classicalNet = socketsConfig (classicalFile )
150149
151150 # Check if we should run a local classical server. If so, initialize the code
Original file line number Diff line number Diff line change 2828# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
2929
3030
31- import logging
3231import os
33-
32+ import logging
3433import numpy as np
3534
3635from simulaqron .local .setup import setup_local
3736from simulaqron .general .hostConfig import socketsConfig
38- from simulaqron .toolbox import get_simulaqron_path
37+ from simulaqron .settings import simulaqron_settings
3938from twisted .internet .defer import inlineCallbacks
4039from twisted .spread import pb
4140
@@ -138,14 +137,13 @@ def main():
138137 myName = "Bob"
139138
140139 # This file defines the network of virtual quantum nodes
141- simulaqron_path = get_simulaqron_path .main ()
142- virtualFile = os .path .join (simulaqron_path , "config/virtualNodes.cfg" )
140+ network_file = simulaqron_settings .network_config_file
143141
144142 # This file defines the nodes acting as servers in the classical communication network
145143 classicalFile = os .path .join (os .path .dirname (__file__ ), "classicalNet.cfg" )
146144
147145 # Read configuration files for the virtual quantum, as well as the classical network
148- virtualNet = socketsConfig (virtualFile )
146+ virtualNet = socketsConfig (network_file )
149147 classicalNet = socketsConfig (classicalFile )
150148
151149 # Check if we should run a local classical server. If so, initialize the code
Original file line number Diff line number Diff line change 2828# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
2929
3030
31- import logging
3231import os
33-
32+ import logging
3433import numpy as np
3534
3635from simulaqron .local .setup import setup_local
3736from simulaqron .general .hostConfig import socketsConfig
38- from simulaqron .toolbox import get_simulaqron_path
37+ from simulaqron .settings import simulaqron_settings
3938from twisted .internet .defer import inlineCallbacks
4039from twisted .spread import pb
4140
@@ -169,14 +168,13 @@ def main():
169168 myName = "Charlie"
170169
171170 # This file defines the network of virtual quantum nodes
172- simulaqron_path = get_simulaqron_path .main ()
173- virtualFile = os .path .join (simulaqron_path , "config/virtualNodes.cfg" )
171+ network_file = simulaqron_settings .network_config_file
174172
175173 # This file defines the nodes acting as servers in the classical communication network
176174 classicalFile = os .path .join (os .path .dirname (__file__ ), "classicalNet.cfg" )
177175
178176 # Read configuration files for the virtual quantum, as well as the classical network
179- virtualNet = socketsConfig (virtualFile )
177+ virtualNet = socketsConfig (network_file )
180178 classicalNet = socketsConfig (classicalFile )
181179
182180 # Check if we should run a local classical server. If so, initialize the code
Original file line number Diff line number Diff line change 2828# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
2929
3030
31- import logging
3231import os
33-
32+ import logging
3433import numpy as np
3534
3635from simulaqron .local .setup import setup_local
3736from simulaqron .general .hostConfig import socketsConfig
38- from simulaqron .toolbox import get_simulaqron_path
37+ from simulaqron .settings import simulaqron_settings
3938from twisted .internet .defer import inlineCallbacks
4039from twisted .spread import pb
4140
@@ -144,14 +143,13 @@ def main():
144143 myName = "David"
145144
146145 # This file defines the network of virtual quantum nodes
147- simulaqron_path = get_simulaqron_path .main ()
148- virtualFile = os .path .join (simulaqron_path , "config/virtualNodes.cfg" )
146+ network_file = simulaqron_settings .network_config_file
149147
150148 # This file defines the nodes acting as servers in the classical communication network
151149 classicalFile = os .path .join (os .path .dirname (__file__ ), "classicalNet.cfg" )
152150
153151 # Read configuration files for the virtual quantum, as well as the classical network
154- virtualNet = socketsConfig (virtualFile )
152+ virtualNet = socketsConfig (network_file )
155153 classicalNet = socketsConfig (classicalFile )
156154
157155 # Check if we should run a local classical server. If so, initialize the code
You can’t perform that action at this time.
0 commit comments