Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Disable packages living on decomissioned svn server #160

Merged
merged 5 commits into from Dec 7, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/python_unittests.yml
Expand Up @@ -10,8 +10,8 @@ jobs:
matrix:
py_version: ['2.7.x', '3.7']
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: ${{ matrix.py_version }}
- name: Install requirements
Expand Down
2 changes: 1 addition & 1 deletion ilcsoft/cernlib.py
Expand Up @@ -183,7 +183,7 @@ def cleanupInstall(self):
#os.chdir( self.installPath + "/build" )

## delete object files
os_system( "find "+self.installPath + "/build -type f -name *.o -exec rm -f {} \;" )
os_system( "find "+self.installPath + r"/build -type f -name *.o -exec rm -f {} \;" )

def postCheckDeps(self):
BaseILC.postCheckDeps(self)
Expand Down
2 changes: 1 addition & 1 deletion ilcsoft/ilcsoft.py
Expand Up @@ -80,7 +80,7 @@ def __init__(self, installPath):
#fg: release_string might be empty, e.g. if lsb_release does not exis (MacOs)
self.release_number = '-1'
if len( release_string ):
self.release_number = release_string[re.search('\d', release_string).start()]
self.release_number = release_string[re.search(r'\d', release_string).start()]

for k,v in self.debugInfo.items():
print("+", k, '\t', str(v).replace("\n","\n\t\t"))
Expand Down
2 changes: 1 addition & 1 deletion ilcsoft/ninja.py
Expand Up @@ -54,7 +54,7 @@ def compile(self):
def cleanupInstall(self):
BaseILC.cleanupInstall(self)
os.chdir( self.installPath )
os_system( "find . \! -name 'ninja' -delete" )
os_system( r"find . \! -name 'ninja' -delete" )

def postCheckDeps(self):
BaseILC.postCheckDeps(self)
Expand Down
24 changes: 12 additions & 12 deletions ilcsoft/test_version.py
Expand Up @@ -3,30 +3,30 @@
################################################

from .version import Version
import py
import pytest

def test_sanity():
py.test.raises(TypeError, Version )
py.test.raises(ValueError, Version, 0)
py.test.raises(ValueError, Version, [])
py.test.raises(ValueError, Version, '')
py.test.raises(ValueError, Version, '1')
py.test.raises(ValueError, Version, '1.')
py.test.raises(ValueError, Version, 'a.b')
py.test.raises(ValueError, Version, 'blah')
pytest.raises(TypeError, Version )
andresailer marked this conversation as resolved.
Show resolved Hide resolved
pytest.raises(ValueError, Version, 0)
pytest.raises(ValueError, Version, [])
pytest.raises(ValueError, Version, '')
pytest.raises(ValueError, Version, '1')
pytest.raises(ValueError, Version, '1.')
pytest.raises(ValueError, Version, 'a.b')
pytest.raises(ValueError, Version, 'blah')

def test_general():

MIN_ELEM = Version._min_elements

# versions must have at least one element > 0
py.test.raises(ValueError, Version, MIN_ELEM * (0,) )
pytest.raises(ValueError, Version, MIN_ELEM * (0,) )

# elements must be integers or convertible to int
py.test.raises(ValueError, Version, (MIN_ELEM * [1]) + ['a'] )
pytest.raises(ValueError, Version, (MIN_ELEM * [1]) + ['a'] )

# elements must be >= 0
py.test.raises(ValueError, Version, (MIN_ELEM * [1]) + [-1] )
pytest.raises(ValueError, Version, (MIN_ELEM * [1]) + [-1] )

# cutting off / filling missing elements
MAX_ELEM = 4
Expand Down
14 changes: 7 additions & 7 deletions releases/HEAD/release-ilcsoft.cfg
Expand Up @@ -202,16 +202,16 @@ ilcsoft.module("LICH").addDependency( [ 'LCIO', 'ROOT', 'Marlin', 'MarlinUtil' ]
#ilcsoft.module("Eutelescope").env['MILLEPEDEII_VERSION']='trunk'


ilcsoft.install( PathFinder( PathFinder_version ))
ilcsoft.module("PathFinder").download.type="svn"
# ilcsoft.install( PathFinder( PathFinder_version ))
# ilcsoft.module("PathFinder").download.type="svn"

ilcsoft.install( MarlinTPC( MarlinTPC_version ))
ilcsoft.module("MarlinTPC").download.type="svn"
ilcsoft.module("MarlinTPC").envcmake['INSTALL_DOC']='ON'
# ilcsoft.install( MarlinTPC( MarlinTPC_version ))
# ilcsoft.module("MarlinTPC").download.type="svn"
# ilcsoft.module("MarlinTPC").envcmake['INSTALL_DOC']='ON'


ilcsoft.install( BBQ( BBQ_version ))
ilcsoft.module("BBQ").download.type="svn"
# ilcsoft.install( BBQ( BBQ_version ))
# ilcsoft.module("BBQ").download.type="svn"

#fg: needs porting to ROOT6 (dictionary!)
#ilcsoft.install( Druid( Druid_version ))
Expand Down
15 changes: 7 additions & 8 deletions releases/v02-03/release-ilcsoft.cfg
Expand Up @@ -199,17 +199,16 @@ ilcsoft.module("LICH").addDependency( [ 'LCIO', 'ROOT', 'Marlin', 'MarlinUtil' ]
#ilcsoft.module("Eutelescope").env['EUDAQ_VERSION']='trunk'
#ilcsoft.module("Eutelescope").env['MILLEPEDEII_VERSION']='trunk'

# ilcsoft.install( PathFinder( PathFinder_version ))
# ilcsoft.module("PathFinder").download.type="svn"

ilcsoft.install( PathFinder( PathFinder_version ))
ilcsoft.module("PathFinder").download.type="svn"
# ilcsoft.install( MarlinTPC( MarlinTPC_version ))
# ilcsoft.module("MarlinTPC").download.type="svn"
# ilcsoft.module("MarlinTPC").envcmake['INSTALL_DOC']='ON'

ilcsoft.install( MarlinTPC( MarlinTPC_version ))
ilcsoft.module("MarlinTPC").download.type="svn"
ilcsoft.module("MarlinTPC").envcmake['INSTALL_DOC']='ON'


ilcsoft.install( BBQ( BBQ_version ))
ilcsoft.module("BBQ").download.type="svn"
# ilcsoft.install( BBQ( BBQ_version ))
# ilcsoft.module("BBQ").download.type="svn"

#fg: needs porting to ROOT6 (dictionary!)
#ilcsoft.install( Druid( Druid_version ))
Expand Down
2 changes: 1 addition & 1 deletion scripts/tagging/parseversion.py
Expand Up @@ -57,7 +57,7 @@ def _parseVersion( self ):
elif 'pre' in parts[2]:
self.pre = int(parts[2].strip('pre'))
else:
self.patch = int( parts[2] )
self.patch = int( parts[2].strip('p') )

if len(parts) >= 4:
if 'pre' == parts[3]:
Expand Down
12 changes: 9 additions & 3 deletions scripts/tests/Test_Tagging.py
Expand Up @@ -11,7 +11,13 @@
except ImportError: # for python3
import builtins
builtin_module_name = 'builtins'

import unittest
try: # monkey patch python2 to also use non-deprecated functionality
unittest.TestCase.assertRaisesRegex
except AttributeError:
unittest.TestCase.assertRaisesRegex = unittest.TestCase.assertRaisesRegexp

import os
import shutil
import sys
Expand Down Expand Up @@ -211,7 +217,7 @@ def test_ctor_fail_1( self ):
}
]

with self.assertRaisesRegexp( RuntimeError, "Invalid version required"), \
with self.assertRaisesRegex( RuntimeError, "Invalid version required"), \
patch( "tagging.gitinterface.Repo.getGithubTags", new=Mock( return_value=myTagInfo)):
self.repo = Repo(owner="tester", repo="testrepo", branch="testbranch", newVersion="v01-03-20-pre", preRelease=True, dryRun=True)

Expand All @@ -225,7 +231,7 @@ def test_ctor_fail_2( self ):
"tarball_url": "tarball/v0.1"
}
]
with self.assertRaisesRegexp( RuntimeError, "Invalid version required"), \
with self.assertRaisesRegex( RuntimeError, "Invalid version required"), \
patch( "tagging.gitinterface.Repo.getGithubTags", new=Mock( return_value=myTagInfo)):
self.repo = Repo(owner="tester", repo="testrepo", branch="testbranch", newVersion="v01-03-19", preRelease=True, dryRun=True)

Expand All @@ -241,7 +247,7 @@ def test_ctor_fail_3( self ):
]


with self.assertRaisesRegexp( RuntimeError, "Invalid version required"), \
with self.assertRaisesRegex( RuntimeError, "Invalid version required"), \
patch( "tagging.gitinterface.Repo.getGithubTags", new=Mock( return_value=myTagInfo)):
self.repo = Repo(owner="tester", repo="testrepo", branch="testbranch", newVersion="v01-03-20-pre1", preRelease=True, dryRun=True)

Expand Down