summaryrefslogtreecommitdiffstats
path: root/SCons/dblite.py
Commit message (Collapse)AuthorAgeFilesLines
* maintenance: update/cleanup dblite moduleMats Wichmann2023-06-191-67/+123
| | | | Signed-off-by: Mats Wichmann <mats@linux.com>
* Add some cheap return and parameter annotationsMats Wichmann2023-05-011-8/+8
| | | | | | | | | | | | | | | | | Use: https://github.com/JelleZijlstra/autotyping to add "safe" return annotations. Where a parameter has a default value that is an obvious scalar type (bool, int, str, etc.) add those annotations as well. Also fixed two small bugs that popped up when sanity-checking with mypy. One in FortranCommon, where a return had been previously annotated to be a tuple of Action, which should be ActionBase - Action is the factory function, not the base class. The other was a typo in the error raised in _add_cppdefines - the message was formatted with the value of "define" which should have been "defines". Signed-off-by: Mats Wichmann <mats@linux.com>
* Drop dictionary has_key references: Py2-ism.Mats Wichmann2021-03-111-3/+0
| | | | | | | | | | | | | | In some cases, added a __contains__ method instead, not because it necessarily was needed, but for completeness. Also one completely unrelated change because it happened to be sitting modified in the tree when I committed modified files: be a little more cautious about building CHECK_METHODS in our subclassing of the optparse Option class... current cpython starts it at None, then fills it in, so it shouldn't be None when we subclass. Signed-off-by: Mats Wichmann <mats@linux.com>
* Flesh out comment on sconsign file syncMats Wichmann2020-12-051-4/+11
| | | | Signed-off-by: Mats Wichmann <mats@linux.com>
* [PR #3837] retry sconsign replacement on failMats Wichmann2020-12-041-1/+10
| | | | | | | | | The pending change stopped fiddling to try to get around an unwritable .sconsign.dblite which needs updating - this is apparently expected to work, so added a retry with some permission fiddling. Signed-off-by: Mats Wichmann <mats@linux.com>
* dblite tweaksMats Wichmann2020-11-301-49/+28
| | | | | | | | | | | use os.replace instead of the dance around os.rename which behaves differently on Windows. use True/False for flags for clarity. Fix some PEP8 warnings. Signed-off-by: Mats Wichmann <mats@linux.com>
* Update some copyright strings and drop __revision__ [skip appveyor]Mats Wichmann2020-09-231-0/+23
| | | | | | | | | | | | | | | | | | Touches the first and second levels of SCons (except SCons.Tool), not tests or docs which remain TODO. Make sure docstring is first non-comment content, eliminate cases where docstring is set elsewhere but assigns to __doc__ - this approach of course worked inside Python, but confuses various tools. Some module-level docstrings modified a bit, in particular the convention of having the name of the module as the first line is dropped, replaced by a summary description going there instead - this improves the look in the API Docs, which otherwise display something like: SCons.Foo - SCons.Foo Signed-off-by: Mats Wichmann <mats@linux.com>
* Docstring changes from Sphinx conversion [ci skip]Mats Wichmann2020-05-301-0/+1
| | | | | | | | These changes are prompted by complaints Sphinx makes about existing docstrings; split from the Sphinx-build PR to make for easier reviewing. Signed-off-by: Mats Wichmann <mats@linux.com>
* classes no longer explicitly inherit from objectMats Wichmann2020-05-241-1/+1
| | | | | | In Python3 this is the default. Signed-off-by: Mats Wichmann <mats@linux.com>
* Reorganize the repo. Moved src/engine/SCons to ./SCons to be more in line ↵William Deegan2020-05-061-0/+279
with current python packaging practices