File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change 138138shutil .copy ("./LICENSE" , "target/LICENSE" )
139139shutil .copy ("./CHANGELOG.md" , "target/CHANGELOG.md" )
140140
141- # If we have a PyPI release for the current version, complete the codemeta.json template
141+ # Complete the codemeta.json template
142142try :
143- with urlopen (f"https://pypi.org/pypi/openminds/{ context [ 'version' ] } / json" ) as handle :
143+ with urlopen (f"https://pypi.org/pypi/openminds/json" ) as handle :
144144 pypi_metadata = json .loads (handle .read ())
145145except HTTPError :
146146 pypi_metadata = None
147147
148148if pypi_metadata :
149149 with open ("pipeline/src/codemeta.json" ) as fp :
150150 codemeta = json .load (fp )
151- codemeta ["version" ] = context ["version" ]
151+ codemeta ["version" ] = pypi_metadata [ "info" ] ["version" ]
152152 for item in pypi_metadata ["urls" ]:
153153 if item ["packagetype" ] == "sdist" :
154154 codemeta ["downloadUrl" ] = item ["url" ]
You can’t perform that action at this time.
0 commit comments