Comments (14)
Hi. Is there an update on this problem?
We were trying to find a solution using tags consisting of only 3 numbers but unfortunately it wont solve our problem. We need to tag hotfixes with 4 numbers or with some postfix following the third number. As mentioned above none of these two options work. Do you think its a valid problem which should be addressed or can you see any other possible solution?
from rebar3.
No updates.
I've cut back some of my maintaining time for OSS stuff as I'm doing other things in my life (and also side projects that aren't just builds), and as such I've tackled generally blocking bugs or compatibility issues across Erlang versions, but I don't have the bandwidth to do deeper overhauls within the tooling.
The apparent thing is that relx started only supporting semver somewhere in 2020 as part of its 4.0 version, which we introduced in Rebar3 3.14.0 back in August 2020. These fixes to go for semver were made as part of some refactorings to properly sort versions while trying to support systools updates that happened back then.
At this point I'm not really sure what is safe or not to do, or how we could do comparison of non-semver versions with semver versions if we were to support both; the change has been there for a long enough time that undoing it is its own risk as well, so it's not a simple change for sure.
from rebar3.
You can put basically anything after a +
can't you?
from rebar3.
No, unfortunately using a tag like 0.1.0+build1 is not possible. Using rebar3 3.22.1 it fails with
===> Upfrom release version (0.1.0+build1) for relup not found
even though the release has been generated for that tag
tothlac:oyhveyh find . -name 0.1.0+build1
./_build/default/rel/oyhveyh/releases/0.1.0+build1
./.git/refs/tags/0.1.0+build1
tothlac:oyhveyh
tothlac:oyhveyh ls ./_build/default/rel/oyhveyh/releases/0.1.0+build1
no_dot_erlang.boot start.script vm.args
oyhveyh.rel start_clean.boot
start.boot sys.config
from rebar3.
tothlac:oyhveyh rebar3 --version
rebar 3.22.1 on Erlang/OTP 26 Erts 14.2.1
from rebar3.
I've pushed a repository here, where it does not work: https://github.com/tothlac/oyhveyh/
I've used this script to reproduce the error:
tothlac:oyhveyh cat ~/work/upgr.sh
#!/bin/bash
set -ex
APP=$1
BASE=$2
TARGET=$3
printf "Upgrade on %s between versions %s ==> %s\n" ${APP} ${BASE} ${TARGET}
rm -rf _build
git reset --hard ${BASE}
rebar3 release
git reset --hard ${TARGET}
rebar3 release
rebar3 appup generate
rebar3 relup --relname ${APP} --relvsn ${TARGET}
then I called
../upgr.sh oyhveyh 0.1.0 0.1.0+build1
It works with target tag 0.1.1, but does not work with 0.1.0+build1 because I got the above mentioned problem
from rebar3.
Oh, is this only an issue for relups?
from rebar3.
You say it is "newer rebar3" tho, did using such version tags used to work?
from rebar3.
Sorry, why did I not reread the origin post, haha.
I see it is two separate issues for using 4 digits and using +build1
.
The latter is possibly a systools issue since it is an issue in relups. I need to check where that error message comes from.
from rebar3.
Ok, it is a bug in relx_relup it appears. I don't know why get_version_before
fails. But this should definitely be fixable and I'll look into it more.
from rebar3.
Actually either tags containing four numbers (4.2.1.10) or three numbers + something at the end like 4.2.1+build1 would be good for us. Unfortunately 3 numbers is not enough for us, we would like to use something after the third number.
I've just tried it with 4.2.1-build1, but that one also does not work, even though:
tothlac:oyhveyh ls _build/default/rel/oyhveyh/releases/
0.1.0 0.1.0-build1 RELEASES start_erl.data
from rebar3.
I got this:
tothlac:oyhveyh ../upgr.sh oyhveyh 0.1.0 0.1.0-build1
+ APP=oyhveyh
+ BASE=0.1.0
+ TARGET=0.1.0-build1
+ printf 'Upgrade on %s between versions %s ==> %s\n' oyhveyh 0.1.0 0.1.0-build1
Upgrade on oyhveyh between versions 0.1.0 ==> 0.1.0-build1
+ rm -rf _build
+ git reset --hard 0.1.0
HEAD is now at d01dff0 Add appup plugin
+ rebar3 release
===> Fetching rebar3_appup_plugin (from {git,"https://github.com/lrascao/rebar3_appup_plugin.git",
{branch,"master"}})
===> Fetching bbmustache v1.5.0
===> Fetching string_compat v0.0.1
===> Analyzing applications...
===> Compiling string_compat
===> Compiling bbmustache
===> Compiling rebar3_appup_plugin
===> Verifying dependencies...
===> Analyzing applications...
===> Compiling oyhveyh
===> Assembling release oyhveyh-0.1.0...
===> Release successfully assembled: _build/default/rel/oyhveyh
+ git reset --hard 0.1.0-build1
HEAD is now at 87ca560 Add cowboy
+ rebar3 release
===> Verifying dependencies...
===> Fetching cowboy v2.11.0
===> Fetching cowlib v2.12.1
===> Fetching ranch v1.8.0
===> Analyzing applications...
===> Compiling cowlib
===> Compiling ranch
===> Compiling cowboy
===> Analyzing applications...
===> Compiling oyhveyh
===> Assembling release oyhveyh-0.1.0-build1...
===> Release successfully assembled: _build/default/rel/oyhveyh
+ rebar3 appup generate
===> current base dir: "/Users/tothlac/work/oyhveyh/_build/default"
===> app oyhveyh ebin dir: "/Users/tothlac/work/oyhveyh/_build/default/lib/oyhveyh/ebin"
===> Generated appup ("0.1.0" <-> "0.1.0-build1") for oyhveyh in "/Users/tothlac/work/oyhveyh/_build/default/lib/oyhveyh/ebin/oyhveyh.appup"
+ rebar3 relup --relname oyhveyh --relvsn 0.1.0-build1
===> Verifying dependencies...
===> Analyzing applications...
===> Compiling oyhveyh
===> Assembling release oyhveyh-0.1.0-build1...
===> Release successfully assembled: _build/default/rel/oyhveyh
===> Upfrom release version (0.1.0-build1) for relup not found
from rebar3.
Do you have any updates on this?
from rebar3.
No updates at this point in time.
from rebar3.
Related Issues (20)
- rebar3 auto: Error loading module enotify HOT 1
- Hooks env variables documentation HOT 1
- {mode, ...} overrides variables explicitly set in the profile
- rebar3 killed spawned processes after compile HOT 1
- Dependency post_hooks clean override not executed. HOT 3
- `rebar3 version` compiles dependencies before outputting value HOT 5
- cover aggregation bug HOT 6
- `REBAR_SRC_DIRS` not available in hook HOT 5
- code:lib_dir/2 is deprecated; this functionality will be removed in a future release HOT 4
- How to execute a Function just before aborting rebar3 shell? HOT 6
- Cannot deploy application because of "Uncaught error in rebar_core" HOT 1
- tests in separate test modules are performed twice by eunit command HOT 6
- error rebar_core HOT 2
- Request new `rebar3` release HOT 4
- rebar3 shell doesn't return prompt HOT 1
- ENV variable replacement with nested configs in releases HOT 3
- Fetching dependency by git ref fails when upgrading to Erlang 26 HOT 2
- `bootstrap --offline` uses https_proxy HOT 3
- rebar3 shell randomly fails on Windows in OTP 27 HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from rebar3.