Skip to content

Commit fd8298a

Browse files
committed
Merge branch 'dev' into stable
2 parents 78f0a98 + 471019e commit fd8298a

32 files changed

+1267
-1084
lines changed

CHANGELOG.md

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
# History
2+
* [v4.2.0 'Batch'](#v4.2.0), 14th Sept, 2022
23
* [v4.1.0 'Phase'](#v4.1.0), 30th August 2022
34
* [v4.0.3 'Dovetail'](#v4.0.3), 18th July 2022
45
* [v4.0.2 'Relink'](#v4.0.2), 15th July 2022
@@ -28,6 +29,32 @@
2829
* [v2.0.1](#v2.0.1), 9th Sept, 2014
2930
* [v2.0 'Phoenix'](#v2.0), 2nd Sept, 2014
3031

32+
<a name="v4.2.0"></a>
33+
34+
## Version 4.2.0 'Batch'
35+
14th September 2022
36+
<!-- [(view commits)](https://github.com/sonic-pi-net/sonic-pi/commits/v4.2.0): -->
37+
38+
The main purpose of this release is to address a booting issue discovered on a school Windows cluster with common security restrictions. This issue was reported by Adam Cooper from Moor Park High School & Sixth Form in the UK. Adam was wonderfully helpful in finding the specific issue and testing potential solutions. Thanks Adam!
39+
40+
If you happen to have had any trouble running v4 of Sonic Pi on your school clusters, please give this release a go! (Note, this issue didn't affect v3 of Sonic Pi).
41+
42+
In addition, there have been some translation improvements, Global Time Warp now has a greater range and a couple of `time_warp` related bugs were found and dealt with. Have fun!
43+
44+
### GUI
45+
* Change Global Time Warp range from +-250 to -250 -> 999. This lets users access the full phase down to a BPM of 48.
46+
47+
### Improvements
48+
* Booting process on Windows has been modified to enable it to run when executing in an environment which restricts access to CMD (which prevents terminal usage and running .bat files). This is typical in schools.
49+
* Sonic Pi stores all its history, configuration and logs in a folder called `.sonic-pi` which is typically placed in the user's home directory. If the user happens to not have permission to write to their home directory, Sonic Pi now raises a descriptive error on boot and explains that the fix is to set an environment variable called `SONIC_PI_HOME` to point to a directory the user does have permission to write to.
50+
51+
### Translations
52+
* Improvements to the Dutch, Hungarian and Indonesian translations.
53+
54+
### Bugfixes
55+
* Teach timing safety system that `time_warp` doesn't sleep (even if it contains calls to `sleep` internally). This now means that wrapping all code within a `live_loop` with `time_warp` no longer causes the thread to spin out of control. It instead reports that the live loop did not sleep as expected.
56+
* Throw error when attempting to call `sync` within a `time_warp`. This is because time warps are effectively timeless and `sync` asks the running thread to wait for an unknown period (until a matching event appears). Attempting to wait within a timeless context is clearly nonsensical!
57+
3158
<a name="v4.1.0"></a>
3259

3360
## Version 4.1.0 'Phase'

CONTRIBUTORS.md

Lines changed: 53 additions & 88 deletions
Large diffs are not rendered by default.

app/api/include/api/sonicpi_api.h

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,8 @@ enum class APIInitResult
4242
{
4343
Successful,
4444
TerminalError,
45-
ScsynthBootError
45+
ScsynthBootError,
46+
HomePathNotWritableError
4647
};
4748

4849
enum class BootDaemonInitResult
@@ -55,6 +56,7 @@ enum class BootDaemonInitResult
5556
enum class SonicPiPath
5657
{
5758
RootPath, // Sonic Pi Application root
59+
HomePath, // User-writable home directory root (parent of UserPath).
5860
UserPath, // User-writable folder for config/saves etc.
5961
RubyPath, // Path to ruby executable
6062
BootDaemonPath, // Path to the Boot Daemon script

app/api/src/sonicpi_api.cpp

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -646,6 +646,12 @@ APIInitResult SonicPiAPI::Init(const fs::path& root, bool noScsynthInputs)
646646
}
647647
}
648648

649+
if (m_homeDirWriteable) {
650+
LOG(INFO, "Home dir writable: ");
651+
} else {
652+
return APIInitResult::HomePathNotWritableError;
653+
}
654+
649655

650656
EnsurePathsAreCanonical();
651657
StartClearLogsScript();
@@ -671,11 +677,7 @@ APIInitResult SonicPiAPI::Init(const fs::path& root, bool noScsynthInputs)
671677
}
672678
});
673679

674-
if (m_homeDirWriteable) {
675-
LOG(INFO, "Home dir writable: ");
676-
} else {
677-
LOG(INFO, "Home dir NOT writable: ");
678-
}
680+
679681

680682
LOG(INFO, "Log Path: " + GetPath(SonicPiPath::LogPath).string());
681683
m_state = State::Initializing;
@@ -722,6 +724,7 @@ bool SonicPiAPI::InitializePaths(const fs::path& root)
722724
m_paths[SonicPiPath::RootPath] = fs::canonical(fs::absolute(root));
723725

724726
// Sonic pi home directory
727+
m_paths[SonicPiPath::HomePath] = FindHomePath();
725728
m_paths[SonicPiPath::UserPath] = FindHomePath() / ".sonic-pi";
726729

727730
// Set path to Ruby executable (system dependent)

app/gui/qt/CMakeLists.txt

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,16 +2,17 @@ cmake_minimum_required(VERSION 3.2)
22

33
message(STATUS "CMakeLists: Sonic Pi Qt GUI")
44

5+
if(APPLE)
6+
set(CMAKE_OSX_DEPLOYMENT_TARGET "10.15")
7+
endif()
8+
59
project("Sonic Pi"
610
LANGUAGES CXX C
711
DESCRIPTION "A code-based music creation and performance tool"
8-
VERSION 4.1.0
12+
VERSION 4.2.0
913
HOMEPAGE_URL "https://sonic-pi.net"
1014
)
1115

12-
if(APPLE)
13-
set(CMAKE_OSX_DEPLOYMENT_TARGET "10.15")
14-
endif()
1516

1617
set_property(GLOBAL PROPERTY USE_FOLDERS ON)
1718

app/gui/qt/html/doc.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
code_as <span class="highlight">:art</span></pre>
1616
</p>
1717

18-
<p class="version">v4.1.0</p>
18+
<p class="version">v4.2.0</p>
1919

2020
</center>
2121

app/gui/qt/html/info.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,6 @@
2929

3030
<br/>
3131

32-
<p class="version">v4.1.0</p>
32+
<p class="version">v4.2.0</p>
3333
</center>
3434
</body>

app/gui/qt/images/splash.png

289 Bytes
Loading

app/gui/qt/images/splash2x.png

651 Bytes
Loading

app/gui/qt/images/splash@2x.png

651 Bytes
Loading

0 commit comments

Comments
 (0)