Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
170 commits
Select commit Hold shift + click to select a range
fa68328
search class
marc-vdm Jul 21, 2025
40bf407
Include correct init file as well
marc-vdm Jul 22, 2025
413ac1a
Search tests, minor corrections, better documentation
marc-vdm Jul 23, 2025
556908c
Merge branch 'beta' into major_search
marc-vdm Jul 23, 2025
d01387f
Improve search speed with many results.
marc-vdm Jul 24, 2025
295995e
Add basic logging to SearchEngine
marc-vdm Jul 24, 2025
30958c7
Merge remote-tracking branch 'upstream/major' into major_search
marc-vdm Jul 24, 2025
79754ca
.
marc-vdm Jul 24, 2025
6bd39f7
Base implementation of metadata specific class
marc-vdm Jul 28, 2025
91a3328
minor changes to searchengine
marc-vdm Aug 18, 2025
e4c2005
Merge branch 'major' into major_search
marc-vdm Sep 2, 2025
8ec0cf4
- Solve bug in OSA distance for early stopping with long similar strings
marc-vdm Sep 2, 2025
e2bb1cf
update add/change identifier (and tests) to accept dataframes instead…
marc-vdm Sep 3, 2025
2d6ca0f
update add/change identifier (and tests) to accept dataframes instead…
marc-vdm Sep 3, 2025
04053ab
move searchengine.py to bwutils instead of subfolder
marc-vdm Sep 3, 2025
478ed5d
move searchengine.py to bwutils instead of subfolder
marc-vdm Sep 3, 2025
1c13007
move searchengine files
marc-vdm Sep 3, 2025
646b3be
move searchengine files
marc-vdm Sep 3, 2025
39af763
metadata and search size logging
marc-vdm Sep 3, 2025
fad8a06
- Faster results with large data and short queries
marc-vdm Sep 3, 2025
1aad95b
Base implementation of better search in ActivitiesProducts table
marc-vdm Sep 3, 2025
f14d43b
Merge branch 'major' into major_search
marc-vdm Sep 4, 2025
5b0a965
check all newly added items are unique
marc-vdm Sep 4, 2025
9ee3450
dont allow sorting of table when search engine in use
marc-vdm Sep 4, 2025
e92d298
resolve search bug with multiple typos not working
marc-vdm Sep 4, 2025
83ae162
First version of autocomplete
marc-vdm Sep 4, 2025
2b61e16
cache database identifiers for faster results + much faster autocomplete
marc-vdm Sep 4, 2025
64bbcd1
Implement proper autocomplete popup
marc-vdm Sep 4, 2025
e76f57c
suggestions for currently edited word instead of last word + better a…
marc-vdm Sep 5, 2025
eeed992
Improve text cleaning regex + autocomplete deals better with key hash…
marc-vdm Sep 5, 2025
bba71c7
better key hash sorting
marc-vdm Sep 5, 2025
8e73436
better autocomplete performance when many long qgram matches
marc-vdm Sep 5, 2025
2f07859
resolve bug with removing identifier from searchengine leading to bre…
marc-vdm Sep 5, 2025
6e5d1cb
add functionality for adding, changing and removing identifiers (exce…
marc-vdm Sep 5, 2025
0bd672c
add functionality for adding and removing full databases
marc-vdm Sep 6, 2025
4791c56
improve matching speed after metadata conversion to ProductModel
marc-vdm Sep 7, 2025
532cac2
make autocomplete suggestions aware of context of other words in quer…
marc-vdm Sep 7, 2025
42c3593
ProductModel suggestions now include literal matches better
marc-vdm Sep 7, 2025
4ec98fb
Update line-edit autocompleter base class
marc-vdm Sep 8, 2025
72e01d1
Add marking of unknown words to search
marc-vdm Sep 9, 2025
fbeb455
drop literal search results
marc-vdm Sep 9, 2025
59e8e18
marginal speed increases for initializing/updating for base class
marc-vdm Sep 9, 2025
e04c20e
marginal speed increases for initializing/updating for base class
marc-vdm Sep 9, 2025
1bedc53
Implement multiprocessing to increase speed for text cleaning during …
marc-vdm Sep 9, 2025
169a7cb
Fix bug with incorrect text length settings
marc-vdm Sep 9, 2025
fe10a1d
Merge branch 'major' into major_search
marc-vdm Sep 9, 2025
7efab02
Fix to allow testing of metadatastore
marc-vdm Sep 9, 2025
06747b8
Refactor textedit to proper location
marc-vdm Sep 12, 2025
90583c6
Refactor textedit to proper location
marc-vdm Sep 12, 2025
fecbcf2
Implement search caching for faster results
marc-vdm Sep 16, 2025
3c3bc6d
Merge branch 'major' into major_search
marc-vdm Sep 16, 2025
9734ad2
bold only current word, not all search suggested words
marc-vdm Sep 16, 2025
e342f22
enable dealing with empty metadata in tests
marc-vdm Sep 16, 2025
033d49c
Reimplement uncertainty for the parameter table
mrvisscher Nov 17, 2025
d05e8f8
Reimplement uncertainty for the parameter tab in the activity details
mrvisscher Nov 17, 2025
0905cca
Reimplement uncertainty for the characterization factors
mrvisscher Nov 17, 2025
e6a2c10
New Tree View header fixes
mrvisscher Nov 17, 2025
fd0e0ef
Apply parameter template button to scenario section
mrvisscher Nov 17, 2025
4cd75d2
Column search fixes
mrvisscher Nov 18, 2025
fa627a5
Group parameter page by parameter type
mrvisscher Nov 18, 2025
dc75fc6
Move ABTreeView to be main solution
mrvisscher Nov 18, 2025
3072b3c
Split up the parameter page for maintainability
mrvisscher Nov 18, 2025
f0b1d9c
Merge branch 'fork/marc-vdm/major_search' into major-search
mrvisscher Nov 18, 2025
ed48dfc
Initial reimplementation of Marc's search
mrvisscher Nov 18, 2025
89d3e68
Skip linking page when nothing to link
mrvisscher Nov 21, 2025
d467c0d
Updates to the ABWizard
mrvisscher Nov 21, 2025
8a7a0a7
Updates to EI and excel importer for better flow
mrvisscher Nov 21, 2025
5539943
First iteration on the import preview dialog
mrvisscher Nov 21, 2025
02ea3d9
Changes to the wizard setup
mrvisscher Nov 24, 2025
9434e10
Update searcher to work with no database
mrvisscher Nov 24, 2025
9a42dba
Full project search dialog
mrvisscher Nov 24, 2025
9803481
Showing unlinked exchanges
mrvisscher Nov 24, 2025
c569115
Simple view for the database_products table
mrvisscher Nov 25, 2025
73353c9
UI changes for the table_view
mrvisscher Nov 25, 2025
fbd8f2c
Update to node selection tool
mrvisscher Nov 25, 2025
9d7d9a7
Search to return dataframes
mrvisscher Nov 25, 2025
40bce35
Parameters for search
mrvisscher Nov 25, 2025
95a3210
Drag and drop to ProductViews
mrvisscher Nov 25, 2025
2cf0ea3
Keyboard actions
mrvisscher Nov 25, 2025
5c3da84
Move from node to card delegate
mrvisscher Nov 27, 2025
cb0b561
Updated node_tab info
mrvisscher Nov 27, 2025
d61f523
Edge tab for import
mrvisscher Nov 27, 2025
3b58700
Add exchange link icons
mrvisscher Nov 27, 2025
d4a18c4
Card font sizing fix
mrvisscher Nov 27, 2025
8abc88d
Stuff
mrvisscher Dec 1, 2025
fc9cb77
Keeping tree state when linking
mrvisscher Dec 1, 2025
b0cc5ff
Fix column filtering in grouped model
mrvisscher Dec 1, 2025
b1c8a3b
Fix sorting and filtering on grouped columns
mrvisscher Dec 1, 2025
f1c2eea
Fixed overlay error in dragdrop
mrvisscher Dec 1, 2025
e2b15ba
Fixed sorting on full search
mrvisscher Dec 1, 2025
362e05d
Fix branch spanning for inserted rows
mrvisscher Dec 1, 2025
b9ea70f
Add nodes_to_excel function for exporting nodes as HTML table
mrvisscher Dec 1, 2025
8d5aa7f
Fixed quick search being out of order
mrvisscher Dec 1, 2025
dfd61c3
Fixed some card display bugs
mrvisscher Dec 1, 2025
3658bbe
Fixed broken exchange context menu
mrvisscher Dec 1, 2025
a5bc384
Fixed broken exchange context menu
mrvisscher Dec 2, 2025
0999733
Caching the MDS
mrvisscher Dec 2, 2025
569a375
node updates now register in searchindex
marc-vdm Dec 2, 2025
3a9cb2d
Merge branch 'major-search+importers' into major-search+importers_mm
marc-vdm Dec 2, 2025
b99d923
Quicker tables
mrvisscher Dec 2, 2025
568face
Merge pull request #4 from marc-vdm/major-search+importers_mm
mrvisscher Dec 2, 2025
7bebb33
Fix print statement
mrvisscher Dec 2, 2025
542bfa9
Setting excel data threaded because loading exchanges takes time
mrvisscher Dec 2, 2025
b21adb4
Stop updater breaking the mds when an activity is emited as changed w…
mrvisscher Dec 2, 2025
15d3158
Set a new logs folder
mrvisscher Dec 2, 2025
1252c62
dataframe sync fix
mrvisscher Dec 2, 2025
2242ab1
dataframe sync fix
mrvisscher Dec 2, 2025
9eb3dfa
ID column to Int64 instead of int64
mrvisscher Dec 4, 2025
af19851
Cached metadata checks
mrvisscher Dec 4, 2025
198bf9a
Make expensive model sorting opt-in
mrvisscher Dec 4, 2025
05118c0
Table optimizations
mrvisscher Dec 4, 2025
5faaf90
Sorting in the CF model
mrvisscher Dec 4, 2025
e830ba2
Updating the search index on mds changes (Adding DBS doesn't work yet)
mrvisscher Dec 4, 2025
947aab8
MDS model with a chunk_size
mrvisscher Dec 5, 2025
2d89944
Showing and deleting broken parameter groups
mrvisscher Dec 5, 2025
cc91571
MDS searcher signal fix
mrvisscher Dec 5, 2025
772b6d9
Excel linking using MDS
mrvisscher Dec 5, 2025
3404f74
Enable database relinking
mrvisscher Dec 5, 2025
29a5b63
Hide allocation factor of non-production exchanges
mrvisscher Dec 5, 2025
5f4caff
Node select to ctrl+shift+F
mrvisscher Dec 5, 2025
8fde7a2
Better search dialog and button
mrvisscher Dec 5, 2025
8c970d3
logging syncs
mrvisscher Dec 6, 2025
d1440f0
Fix formula edit import bug
mrvisscher Dec 6, 2025
7bed7f4
Fix search test import bug
mrvisscher Dec 6, 2025
6eb104e
Fix windows seg fault in testing
mrvisscher Dec 6, 2025
2b79254
Changed widget debug log
mrvisscher Dec 6, 2025
601a68a
No mp in base searchengine
mrvisscher Dec 8, 2025
4ddbcc2
Fix tabwidget init signature
mrvisscher Dec 8, 2025
1a124f0
CTW is part of the main_window
mrvisscher Dec 8, 2025
82f2d10
Deleting initiated pages on MainWindow delete
mrvisscher Dec 8, 2025
3d63030
Don't double-sync CS pane
mrvisscher Dec 8, 2025
8453181
Trying to fix segfault during tests
mrvisscher Dec 8, 2025
008c736
Trying to fix segfault during tests
mrvisscher Dec 8, 2025
fad76cb
Trying to fix segfault during tests
mrvisscher Dec 8, 2025
57b3161
Don't write empty on database duplicate
mrvisscher Dec 8, 2025
6457b95
Wait for full database load during test config
mrvisscher Dec 8, 2025
a457374
Fix CS actions using deprecated signals
mrvisscher Dec 8, 2025
fd843ff
Delete redundant tests
mrvisscher Dec 8, 2025
2683d99
Fixing tests
mrvisscher Dec 8, 2025
1c245ac
Fixing tests
mrvisscher Dec 8, 2025
412ae1f
Fixing tests - copy mdf
mrvisscher Dec 9, 2025
929007d
Fixing tests - thread-lock mdf
mrvisscher Dec 9, 2025
dc59f1f
Fixing tests - set-default on ABWizard
mrvisscher Dec 9, 2025
ec2ff4a
Fixing tests - waiting for threads
mrvisscher Dec 9, 2025
896cd75
Fixing tests
mrvisscher Dec 9, 2025
11effce
Fixing tests
mrvisscher Dec 9, 2025
8696ca1
Fixing tests
mrvisscher Dec 9, 2025
bbcb029
Fixing tests
mrvisscher Dec 9, 2025
e92588c
Fixing tests
mrvisscher Dec 9, 2025
ea8e45c
Fixing tests
mrvisscher Dec 9, 2025
225b13e
Fixing tests
mrvisscher Dec 9, 2025
42182d9
Fixing tests
mrvisscher Dec 9, 2025
5943f6f
Fixing tests
mrvisscher Dec 9, 2025
9805a26
Fixing tests
mrvisscher Dec 9, 2025
f25ef8b
Fixing tests
mrvisscher Dec 9, 2025
9dbc23f
Application documentation
mrvisscher Dec 10, 2025
32c17a5
Merge branch 'major-search+importers' of https://github.com/mrvissche…
mrvisscher Dec 10, 2025
15b59cc
Fixing tests
mrvisscher Dec 10, 2025
aa398c1
Fixing tests
mrvisscher Dec 10, 2025
6f0d725
Merge remote-tracking branch 'origin/major-search+importers' into maj…
mrvisscher Dec 10, 2025
6c2f4a0
Cleaning up the mds
mrvisscher Dec 10, 2025
24842ac
Add SYNC log level
mrvisscher Dec 10, 2025
8a9bdfc
Some logging changes
mrvisscher Dec 10, 2025
8c6ae46
Remove old settings
mrvisscher Dec 10, 2025
9d04b4a
Remove deprecated docs
mrvisscher Dec 10, 2025
e2e5347
Updates to top level modules
mrvisscher Dec 10, 2025
f025498
UI refactoring
mrvisscher Dec 10, 2025
7c43c07
Clean up workflows
mrvisscher Dec 10, 2025
d4dc736
Workflow readme
mrvisscher Dec 10, 2025
d62ca0b
fixed setup.py
mrvisscher Dec 10, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
192 changes: 192 additions & 0 deletions .github/workflows/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,192 @@
# GitHub Actions Workflows

This document describes the GitHub Actions workflows used in the Activity Browser project.

## Overview

The Activity Browser project uses five GitHub Actions workflows to automate testing, deployment, and project management tasks:

1. **Automated Testing** - Runs tests on every push and PR
2. **Canary Installation** - Daily installation checks to catch dependency issues
3. **Beta Deployment** - Publishes beta releases to PyPI and Anaconda
4. **Stable Release** - Creates releases and publishes to Anaconda
5. **Milestone Comments** - Automatically notifies users when issues are resolved in releases

---

## 1. Automated Testing (`testing.yaml`)

**Trigger:** Push or pull request to the `major` branch

**Purpose:** Ensures code quality by running the test suite across multiple operating systems and Python versions.

### Matrix Strategy
- **Operating Systems:** Ubuntu (latest), Windows (latest), macOS 15, macOS (latest)
- **Python Versions:** 3.10, 3.11, 3.12
- **Total combinations:** 12 test runs per trigger

### Steps
1. Checkout code
2. Set up Python for the specified version
3. Install Qt libraries (Linux only)
4. Update pip, setuptools, and wheel
5. Install package with testing dependencies: `pip install .[testing]`
6. Run pytest with minimal output: `pytest -s --no-header --no-summary -q`

### Environment
- Sets `QT_QPA_PLATFORM=offscreen` for headless GUI testing
- Uses `fail-fast: false` to run all combinations even if some fail

---

## 2. Canary Installation (`install-canary.yaml`)

**Trigger:** Scheduled daily at 7:00 AM UTC (cron: `0 7 * * *`)

**Purpose:** Proactively detects dependency issues by performing fresh installations of Activity Browser from PyPI daily.

### Matrix Strategy
- **Operating Systems:** Ubuntu (latest), Windows (latest), macOS 15, macOS (latest)
- **Python Versions:** 3.10, 3.11, 3.12
- **Timeout:** 12 minutes per job

### Steps
1. Checkout code
2. Set up Python
3. Install activity-browser from PyPI (not from source)
4. Generate environment info with `pip freeze`
5. Upload frozen requirements as artifact for each OS/Python combination

### Notes
- Uses `bash -e {0}` shell to exit on error
- Helps catch breaking changes in dependencies before users encounter them
- Artifacts show exact dependency versions that successfully installed

---

## 3. Beta Deployment (`python-package-deploy.yml`)

**Trigger:** Push to `beta` branch or any tag

**Purpose:** Publishes beta versions to PyPI (test and production) and Anaconda Cloud.

### Version Scheme
- Beta version format: `3.0.0b<N>` where N is the commit count since commit `199b6c3`
- Calculated dynamically: `git rev-list 199b6c3..HEAD --count`

### Steps
1. Checkout with full git history (`fetch-depth: "0"`)
2. Calculate and set version number
3. Set up Python 3.11
4. Install `build` package
5. Build wheel and source distribution
6. **PyPI Publishing:**
- Publish to Test PyPI (with `skip-existing: true`)
- Publish to production PyPI
7. **Conda Publishing:**
- Set up Conda environment from `.github/conda-envs/build.yml`
- Build Conda package: `conda build -c conda-forge -c cmutel ./recipe/`
- Upload to Anaconda Cloud using `CONDA_LCA` secret token

### Permissions
- Requires `id-token: write` for PyPI trusted publishing

---

## 4. Stable Release (`release.yaml`)

**Trigger:** Push of any git tag

**Purpose:** Creates GitHub releases with auto-generated changelogs and publishes stable versions to Anaconda.

### Steps
1. Checkout code
2. **Generate Changelog:**
- Uses `mikepenz/release-changelog-builder-action@v4`
- Configuration from `.github/changelog-configuration.json`
- Builds changelog from PRs with labels
3. **Create GitHub Release:**
- Uses `ncipollo/release-action@v1`
- Includes generated changelog as release notes
- Targets `main` branch commit
4. **Build and Upload Conda Package:**
- Set up Conda environment (Python 3.11)
- Build with `conda build recipe/`
- Upload to Anaconda using `CONDA_UPLOAD_TOKEN` secret
5. **Update Wiki:**
- Runs `.github/scripts/update_wiki.sh` to automatically update documentation

### Notes
- Only runs on tagged commits (version releases)
- Creates public GitHub releases visible to users
- Updates project wiki documentation automatically

---

## 5. Milestone Comments (`comment-milestoned-issues.yaml`)

**Trigger:** When a milestone is closed

**Purpose:** Automatically notifies users on closed issues when their issue has been implemented in a release.

### Steps
1. Uses `actions/github-script@v5` to run JavaScript automation
2. Gets milestone number and title from the event
3. Lists all issues associated with the milestone
4. For each closed issue (not PRs):
- Posts a comment with:
- Link to the new release
- Instructions to update Activity Browser
- Link to subscribe to the updates mailing list
- Bot disclaimer

### Comment Template
The bot posts a formatted note:
- Informs that the issue is implemented in version X
- Provides update instructions
- Offers subscription to updates mailing list (brightway.groups.io)
- Includes bot identification

---

## Workflow Dependencies

### Secrets Required
- `GITHUB_TOKEN` - Automatically provided by GitHub Actions
- `CONDA_LCA` - Anaconda upload token for beta releases
- `CONDA_UPLOAD_TOKEN` - Anaconda upload token for stable releases

### Configuration Files
- `.github/conda-envs/build.yml` - Conda environment for building packages
- `.github/changelog-configuration.json` - Changelog generation configuration
- `.github/scripts/update_wiki.sh` - Wiki update script
- `recipe/meta.yaml` - Conda package recipe
- `pyproject.toml` - Python package configuration

---

## Development Notes

### Running Tests Locally
To run the same tests that CI runs:
```bash
pip install .[testing]
pytest -s --no-header --no-summary -q
```

### Testing Matrix Changes
When modifying the test matrix (OS or Python versions):
- Update both `testing.yaml` and `install-canary.yaml` to keep them in sync
- Consider the maintenance burden of additional combinations
- Current support: Python 3.10-3.12, Ubuntu/Windows/macOS

### Release Process
1. **Beta release:** Push to `beta` branch → Auto-publishes beta version
2. **Stable release:** Create and push a tag → Creates GitHub release and publishes to Anaconda
3. **Close milestone:** When closing a milestone → Users get notified automatically

### Monitoring
- Check daily canary runs to catch dependency issues
- Review failed test runs in PR checks before merging
- Monitor PyPI and Anaconda Cloud for successful uploads

101 changes: 2 additions & 99 deletions .github/workflows/install-canary.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,113 +3,16 @@ on:
schedule:
# Run the tests once every 24 hours to catch dependency problems early
- cron: '0 7 * * *'
push:
branches:
- install-canary

jobs:
canary-installs:
timeout-minutes: 12
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest, macos-13]
python-version: ["3.10", "3.11"]
defaults:
run:
shell: bash -l {0}
steps:
- name: Setup python ${{ matrix.python-version }} conda environment
uses: conda-incubator/setup-miniconda@v3
with:
python-version: ${{ matrix.python-version }}
miniconda-version: "latest"
- name: Install activity-browser
run: |
conda create -y -n ab -c conda-forge --solver libmamba activity-browser python=${{ matrix.python-version }}
- name: Environment info
run: |
conda activate ab
conda list
conda env export
conda env export -f env.yaml
- name: Upload final environment as artifact
uses: actions/upload-artifact@v4
with:
name: env-${{ matrix.os }}-${{ matrix.python-version }}
path: env.yaml

# also run install with micromamba instead of conda to have a timing comparison
canary-installs-mamba:
runs-on: ${{ matrix.os }}
timeout-minutes: 30
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
python-version: ['3.11']
defaults:
run:
shell: bash -l {0}
steps:
- name: Setup python ${{ matrix.python-version }} conda environment
uses: mamba-org/setup-micromamba@v1
with:
micromamba-version: '1.5.9-1'
environment-name: ab
create-args: >-
python=${{ matrix.python-version }}
activity-browser
- name: Environment info
run: |
micromamba list
micromamba env export
micromamba env export > env.yaml
- name: Upload final environment as artifact
uses: actions/upload-artifact@v4
with:
name: env-${{ matrix.os }}-${{ matrix.python-version }}-mamba
path: env.yaml

conda-micromamba-comparison:
runs-on: ubuntu-latest
defaults:
run:
shell: bash -l {0}
needs:
- canary-installs
- canary-installs-mamba
steps:
- name: Download all artifacts
uses: actions/download-artifact@v4
- name: show files
run: |
ls -la
- name: correct yaml formatting
# add correct indentation to make diffing possible
uses: mikefarah/yq@master
with:
cmd: |
ls | grep mamba | while read d; do yq -i $d/env.yaml; done
- name: diff ubuntu
run: |
diff -u env-ubuntu-latest-3.11* || :
- name: diff windows
run: |
diff -u env-windows-latest-3.11* || :
- name: diff macos
run: |
diff -u env-macos-latest-3.11* || :

canary-installs-pip:
timeout-minutes: 12
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ ubuntu-latest, windows-latest, macos-13 ]
python-version: [ '3.10' ]
os: [ubuntu-latest, windows-latest, macos-15, macos-latest]
py-version: ["3.10", "3.11", "3.12"]
defaults:
run:
shell: bash -e {0}
Expand Down
28 changes: 0 additions & 28 deletions .github/workflows/just-release.yaml

This file was deleted.

Loading