241 Commits

Author SHA1 Message Date
Sybren A. Stüvel
3b4da656c9 Add-on: cache manager info in a JSON file
Instead of storing the cached manager info in the Blender preferences,
store the info in a JSON file. The file is located in the user prefs
folder (`~/.config/blender/{version}/config` on Linux).

This also reduces the number of 'refresh' operators to a single one, which
then fetches all necessary info from the Manager.

This fixes an issue (reported via chat) where worker tags were sometimes
not retained across file saves.
2024-03-04 13:08:53 +01:00
Sybren A. Stüvel
f9bb7afcc6 Add-on: fix mypy warnings
No functional changes.
2024-03-04 12:46:38 +01:00
Sybren A. Stüvel
8cf19876c0 OAPI: regenerate code 2024-03-01 08:36:40 +01:00
Sybren A. Stüvel
d9ffe8a1b6 OAPI: regenerate code 2024-02-29 20:38:38 +01:00
Sybren A. Stüvel
94bf65a9e3 Bumped version to 3.5-alpha1 2024-02-26 18:17:19 +01:00
Sybren A. Stüvel
fd9605583f OAPI: regenerate code 2024-02-21 22:16:23 +01:00
Sybren A. Stüvel
1ed893fa84 OAPI: regenerate code 2024-02-05 09:14:31 +01:00
Sybren A. Stüvel
aa2ad35155 Bumped version to 3.5-alpha0 2024-01-17 13:17:35 +01:00
Sybren A. Stüvel
e1306010d7 Bumped version to 3.4 2024-01-12 11:14:50 +01:00
Sybren A. Stüvel
b110f5fb51 Bumped version down to 3.4-beta1
There are a few more things I want to do before releasing 3,4.
2024-01-11 17:17:56 +01:00
Sybren A. Stüvel
0c08a5ad5d Bumped version to 3.4 2024-01-11 16:51:21 +01:00
Sybren A. Stüvel
1095caeddd OAPI: regenerate code
This creates the Python and JavaScript files for the job mass-deletion
operation.
2024-01-11 16:47:25 +01:00
Sybren A. Stüvel
ba02fa9a41 Upgrade BAT to 1.18
This fixes a long-standing issue when packing files on Windows. It also
solves some more bugs, and adds support for packing OpenVDB files.
2024-01-11 16:46:20 +01:00
Sybren A. Stüvel
e6a29e1662 Bumped version to 3.4-beta0 2024-01-05 17:01:29 +01:00
Sybren A. Stüvel
e4f5dff21c Addon: log BAT pack parameters
This can help to debug issues.

Note that these are logged at `INFO` level, and thus probably won't be
seen with Python's default logging configuration.
2024-01-05 11:25:17 +01:00
Sybren A. Stüvel
a6f6f10239 Fix #104263: Error performing BAT pack in Windows with shared storage
Replace calls to `Path.absolute()` and `Path.resolve()` with
`bpathlib.make_absolute(path)`.

The replaced functions can transform drive letters on Windows to UNC
notation. Either all of Flamenco + BAT should be using UNC notation, or
drive letters, but mixing those will cause errors.
2024-01-05 11:23:49 +01:00
Sybren A. Stüvel
b34ad8da90 Addon: fix issue where resubmission was blocked after submission error
Fix an issue where a submission error would keep the BAT status set to
`INVESTIGATING`, which hides the 'Submit to Flamenco' button. In case of
an error, it's now properly set to `ABORTED`, which does show that button.
2024-01-05 11:21:12 +01:00
Sybren A. Stüvel
1a4e0c36e4 Addon: gracefully handle disappearing job type
When refreshing the list of available job types, Blender recreates the
job type property itself, clearing out any previously chosen value. The
add-on tries to restore that previously chosen value, and now also
gracefully handles the case where this job type is no longer available.
2024-01-02 17:13:22 +01:00
Sybren A. Stüvel
a4000f1909 Bumped version to 3.3.1 2023-12-14 12:09:33 +01:00
Sybren A. Stüvel
a6db15fdfa Bump BAT from 1.16 to 1.17 2023-12-14 11:59:16 +01:00
Sybren A. Stüvel
02011f8237 Bumped version to 3.4-alpha0 2023-11-06 15:08:36 +01:00
Sybren A. Stüvel
788b6138b7 Bumped version to 3.3 2023-11-06 11:56:48 +01:00
Sybren A. Stüvel
0333fe1383 Bumped version to 3.3-beta3 2023-11-02 16:29:56 +01:00
Sybren A. Stüvel
30da72a9b7 Upgrade BAT to 1.16 2023-11-02 15:49:38 +01:00
Sybren A. Stüvel
90186d7a79 Fix mypy error
No functional changes.
2023-11-02 13:50:45 +01:00
Sybren A. Stüvel
01f2e6d558 Bumped version to 3.3-beta2 2023-10-31 14:54:20 +01:00
Sybren A. Stüvel
4134388dda Addon API client README: add missing link 2023-10-20 11:07:23 +02:00
Sybren A. Stüvel
624135f55b Bump version to v3.3-beta1 2023-10-20 11:05:47 +02:00
Sybren A. Stüvel
621f050a68 OAPI: regenerate code 2023-08-23 13:54:02 +00:00
Sybren A. Stüvel
1eb7764d00 OAPI: regenerate code 2023-08-14 16:00:06 +02:00
Sybren A. Stüvel
b24d748840 Add-on: use the 'eval' description in the 'eval now' button as well
In the tooltip of the 'evaluate now' button (the one with the Python
icon), include the description provided by the job type in its
`evalInfo.description` field. This makes it explicit what the button
will do when pressed.
2023-07-13 15:14:39 +02:00
Sybren A. Stüvel
6994413ed6 Use new property names for 'use automatic values' button
Adjustment of the job settings property names, making them more widely
usable than just the 'use automatic values' button (also known as
'eval-on-submit').
2023-07-13 15:02:00 +02:00
Sybren A. Stüvel
4b53c06467 OAPI: regenerate code 2023-07-13 15:00:34 +02:00
Sybren A. Stüvel
242ed119ab Eval-on-submit job settings: improve GUI in the add-on
Improve the usability of the 'eval-on-submit' toggle button:

- Add a placeholder text that can be shown instead of the input field. This
  can be used to describe what the evaluated Python code will do. In the
  case of the 'Simple Blender Render' job, this is set to 'Scene frame
  range'.
- Change the way in which the job type has to declare this, both for
  clarity and to add the extra placeholder string
2023-07-13 14:44:24 +02:00
Sybren A. Stüvel
ab399594c7 OAPI: regenerate code 2023-07-13 14:42:07 +02:00
Sybren A. Stüvel
8f9fddd512 Add-on: silence mypy error
Mypy doesn't know the `bl-rna` property exists.

No functional changes.
2023-07-13 12:56:03 +02:00
Sybren A. Stüvel
33aa44e623 Add-on: remove accidental debug print 2023-07-13 12:55:11 +02:00
Sybren A. Stüvel
3a3e664ae2 Add option to make a job setting auto-evaluatable by the user
Add a new job setting option `autoevalLockable`. Setting this to `true` in
the job compiler's `JOB_TYPE` settings has the following effect:

- By default, the setting will not be editable in Blender's job submission
  interface. Instead, a toggle button with a 'car' icon will be shown.
- When the 'car' button is toggled off, the setting becomes editable again.

In its default, uneditable state, the setting will be auto-evaluated before
submission.

This makes it possible to 'lock in' auto-evaluation. The main use case is
for the frame range of the render job. By default this will be locked to
the scene frame range, but it can still be overridden if a different
range is wanted.
2023-07-13 12:07:02 +02:00
Sybren A. Stüvel
168305f785 OAPI: regenerate code 2023-07-13 12:06:21 +02:00
Eveline Anderson
830c3fe794 Rename worker 'clusters' to 'tags'
As it was decided that the name "tags" would be better for the clarity
of the feature, all files and code named "cluster" or "worker cluster"
have been removed and replaced with "tag" and "worker tag". This is only
a name change, no other features were touched.

This addresses part of #104204.

Reviewed-on: https://projects.blender.org/studio/flamenco/pulls/104223

As a note to anyone who already ran a pre-release version of Flamenco
and configured some worker clusters, with the help of an SQLite client
you can migrate the clusters to tags. First build Flamenco Manager and
start it, to create the new database schema. Then run these SQL queries
via an sqlite commandline client:

```sql
insert into worker_tags
    (id, created_at, updated_at, uuid, name, description)
  select id, created_at, updated_at, uuid, name, description
  from worker_clusters;

insert into worker_tag_membership (worker_tag_id, worker_id)
  select worker_cluster_id, worker_id from worker_cluster_membership;
```
2023-07-10 11:11:03 +02:00
Eveline Anderson
341dc6c8e2 OAPI: regenerate code 2023-07-10 11:08:44 +02:00
Sybren A. Stüvel
82456424c9 OAPI: regenerate code 2023-07-06 12:19:48 +02:00
Sybren A. Stüvel
86514b9342 Remove the 'None' project finder, set 'blender project' as default
The 'None' project finder is the old behaviour of the add-on, and it is not
really necessary. If any of the other finders cannot find the directory
they're looking for, they'll return the current blend file's directory
anyway.

The new default is 'blender project'.
2023-06-01 16:34:13 +02:00
Sybren A. Stüvel
f4f61ea593 Add 'project finders' to the add-on
The Flamenco add-on can now find the top-level directory of your Blender
project. It can be configured to find any of these directories:

- `.blender_project`
- `.git`
- `.subversion`
- None, which is the default and the old behaviour of just using the
  directory of the current blend file as the 'project directory'.
2023-06-01 16:07:11 +02:00
Sybren A. Stüvel
fbc7c0cfd9 Fix mypy errors
Mypy doesn't understand Blender property annotations.
2023-06-01 15:51:44 +02:00
Sybren A. Stüvel
16da14479b OAPI: regenerate code 2023-05-26 11:25:51 +02:00
Sybren A. Stüvel
ef53304b1b Fix #104206: Worker cluster assignment is lost when blender is restarted
The available worker clusters are stored on the addon preferences, to be
available across restarts of Blender. The prefs were not marked as 'dirty'
though, so Blender never actually saved them. That's now resolved.
2023-04-24 12:42:45 +02:00
Sybren A. Stüvel
0e0fddc076 Add-on: Change 'No Cluster' to 'All'
In the 'Cluster' drop-down, change the label and tooltip of the 'No
Cluster' option. The functionality is still the same, it causes the job
to be submitted without cluster assigned. The wording now reflect
Flamenco's behaviour better, instead of describing this technical aspect.

Old: "No Cluster", "No cluster assigned, any worker can handle this job"
New: "All", "No specific cluster assigned, any worker can handle this job"
2023-04-08 11:30:25 +02:00
Sybren A. Stüvel
f5ab2bb4c2 OAPI: regenerate code 2023-04-04 13:18:59 +02:00
Sybren A. Stüvel
2a6cbcf030 Addon: Add worker cluster support
Worker clusters can be fetched from the Manager, and submitted jobs can
be assigned to those clusters.
2023-04-04 12:19:44 +02:00