Upgrading Directus 7 by using git causes error when using - git pull origin - directus

According to the Directus documenentation, https://docs.directus.io/guides/upgrading.html
the correct procedure to upgrade a current version 7 to newer version (7.x) is by pulling the new version from git:
git pull origin
However, this results in an error stating that the local changes e.g. in the files for migrations located in: migrations/db/schemas/
and some more locations will be overwritten thus the operation will not be performed (ending with an error).
Are the instructions on the linked page incorrect or am I doing something wrong here?
Any help is appreciated
/Chris

The issue appears to be that you've manually modified files within Directus, therefore your local Git is expecting the changes to be committed before updating, you may need to update by force, but any changes you've made will be overwritten.
Your config.php and uploads should remain untouched.

Related

requested datatype filelists not available in yum update

In order to patch RedHat 7 machines to version 7.9, I've created an RPM repository with RPMs extracted from a DVD.iso file of the patch (example source guide), and updated said machines using yum.
The patch has succeeded with many of the machines (RHEL 7.7 only), but the rest (7.0, 7.2 and some 7.7 as well) have failed the with the following error:
Error: requested datatype filelists not available
I've also tried to gradualize the process and patch the 7.0 and 7.2 ones to 7.7 first by the same process, but yielded the same result. I've made sure I got each and every file in the Packages folder.
It is rather puzzling for me that some succeed and some fail, especially those with the same version. But I'm assuming they were created differently as I don't have the information to say otherwise. So my best direction would be to go by the error.
In this github post, lr1980 says:
https://blog.packagecloud.io/eng/2015/07/20/yum-repository-internals/
this means the "filelists.xml.gz" is missing on repo => it's a packager.io problem
Indeed, browsing my repository's repodata folder reveals only other.xml.gz and primary.xml.gz files, which are also the only files pointed to in the repomd.xml.
I've tried uploading the filelists.xml.gz file from the dvd.iso and reindexing, but it gets removed (admittedly am not familiar with this area of knowledge.. at all). What does "it's a packager.io problem" mean?
How can I force the repo to have such a file, assuming that's what I need? Or what can I do to solve this issue otherwise?
Many thanks

npm install and codepush: The uploaded package was not released because it is identical to the contents of the specified deployment's current release

when i update a package with npm install only, codepush fails with message:
The uploaded package was not released because it is identical to the contents of the specified deployment's current release.
Is there a way to upload update even when there is only one package updated, right now users have to install new apk everytime package version changes?
Not a lot of information in this question, but this error is from the appcenter-cli, which produces this error if the target contents are the same as the source, indicating that it did not create a new codepush release.
This situation will happen all the time in a typical project. If this error is stopping your CI pipeline from completing, you can use the --disable-duplicate-release-error parameter, which simply reports a warning instead of an error.
See https://learn.microsoft.com/en-us/appcenter/distribution/codepush/cli#no-duplicate-release-error-parameter for more details.
I just did logout and login again! it worked

My Debian repository is throwing a "Hash Sum mismatch" error

We maintain a Debian repository for an app and all .deb files are stored on a s3 bucket.
We wrote a script to upload the files and update the Packages.gz file. All went fine until one of the developers found deb-s3 and tried using it.
After the first package upload we started getting this error message:
W: Failed to fetch s3://s3.amazonaws.com/myapp/dists/test/main/binary-amd64/Packages Hash Sum mismatch
I've tried to restore an old version of our Packages.gz file with no success. I've searched for this error and removing the /var/lib/apt/lists/ does not work either.
What would deb-s3 do that could break our entire repo?
Looks like deb-s3 creates a Releases file under dist/test and that conflicts with Packages.gz.
Removing the Release file restored our repository back to what it was.

How can I recover after a checksum mismatch with 'git svn clone'?

I'm cloning an SVN repository to git as part of our migration plan. I've hit various snags along the way, forcing me to continue the clone with a git svn fetch command. The most recent failure I can't figure out how to solve:
$ git svn fetch
Checksum mismatch: dc/trunk-4632-jh/dc-smtpd/lib/Qpsmtpd/Address.pm.t 8ce3aea3f47dc115e8fe53bd62d0f074cfe93ec6
expected: 59de969022e46135fa6dc7599fc2f3b4
got: 4334926a01c905cdb7fce71265e370c1
I found this related answer, however that solution doesn't work because git svn log is not yet functional, as the repo is not fully in place:
$ git svn log dc/trunk-4632-jh/dc-smtpd/lib/Qpsmtpd/Address.pm.t
fatal: ambiguous argument 'HEAD': unknown revision or path not in the working tree.
Use '--' to separate paths from revisions
log --no-color --first-parent --pretty=medium HEAD: command returned error: 128
How can I proceed?
Another answer to an old question but straight forward solutions are tough to find for this problem so hopefully this helps others.
I think this issue occurs due to a corrupted file during transfer. Not sure how or why it happens, but in my case, I get the same error at different revisions every time I do a new clone and sometimes not at all.
Using the questioners error message
$ git svn fetch
Checksum mismatch: dc/trunk-4632-jh/dc-smtpd/lib/Qpsmtpd/Address.pm.t
8ce3aea3f47dc115e8fe53bd62d0f074cfe93ec6
expected: 59de969022e46135fa6dc7599fc2f3b4
got: 4334926a01c905cdb7fce71265e370c1
The following steps allowed me to resume and progress :-
View all branches. These will all be remote branches. git branch -a
Checkout branch affected. git checkout remotes/origin/trunk-4632-jh
This will take some time to complete.
Find the last revision that the problematic file was changed. git svn log dc-smtpd/lib/Qpsmtpd/Address.pm.t
Note the highest revision #
Reset back to this rev. git svn reset -r (rev #) -p
Carry on. git svn fetch
Good luck.
I know this is old but maybe it will be helpful for future reference as all search results on this are not helpful.
I've hit similar issue on our huge repository which takes days to clone and unfortunately at one point I had to restart my machine. I am currently working out how to resolve the problem, so please keep in mind this is more a suggestion than tested solution.
I think you need to try creating a branch and checking out the commits you currently have from previous fetch:
git checkout -b master git-svn
After that is done you should have working tree up to that commit. Another fetches will probably fail due to object mismatch but at that point at least it should be possible to use "git svn reset" to revert faulty svn fetches (see OP's related answer link). If that's true find offending commit, reset before it and then continue fetching.
You might want to rebase and revert to state before that broken commit on your master branch or convert back to bare repository, if that's what you're after (in my case it is).
Hope this works. I'll post an update when my checkout is done (will take at least few hours... sigh).
Edit: That seemed to work. I successfully discarded some git-svn commits and am able to re-fetch them again. :)
Edit2: Make sure to reset until you don't get any object mismatch warnings on git svn fetch (otherwise you will run into the same issue soon).
Cheers,
Henryk
See also: Git svn rebase : checksum mismatch
In our case the additional treatment of the files (server-side includes in Apache) caused the checksum problem.
Disabling SSI in Apache's /etc/httpd.conf file for the period of migration by commenting out the
AddType text/html .shtml
AddOutputFilter INCLUDES .shtml
directives solved the problem, caused by the interpretation of .shtml files by the front-end Apache server, which produced a new content (and thus a new hash), other than the hash of the original file itself.
That means some files in the repository got corrupted. It can be caused by various reasons such as software bugs, bit rots in drives, etc. I was recently transitioning very old ~10GB svn repository to git, therefore some corruption was expected.
To fix the corruption, you basically need to dump the entire repository and import it while filtering the errors out. Note that our goal is to complete the import process no matter why or how the repository got corrupted. You cannot simply fix the corruption without having a backup and diffing through the revision files.
First basic one-off command you could use is:
svnadmin create repo2
svnadmin dump repo | sed '/^Text-content-md5/d' | svnadmin load repo2
This removes the checksum calculation from the dump so the new repo will have updated checksums.
If you encountered more errors during the dump and load (which is expected), try incremental approach so you can continue from the point you left. Below command will dump the revisions starting from 101 to 150 (inclusive).
svnadmin dump --incremental -r101:150 repo | sed '/^Text-content-md5/d' | svnadmin load repo2
Some common errors and solutions:
'Premature end of content data in dumpstream': That means Content-length of some file does not match the repository version, so some data is lost in the specified file. We must skip it. Add | svndumpfilter exclude path/to/file.jar command like this:
svnadmin dump --incremental -r101:150 repo | svndumpfilter exclude path/to/file.jar | sed '/^Text-content-md5/d' | svnadmin load repo2
Property errors: Add --bypass-prop-validation to svnadmin load command
After populating your second repo, you would simply svnserve -d -r repo2 and try git svn fetch again.
Good luck!

Redmine revision keywords not working after migration

A couple of days ago we did a long due migration from Redmine 0.9.3 to 2.2.0. Everything migrated perfectly and seemed to work right away.
But we just found one function that no longer works. Redmine no longer seems to listen to the repository keyword. They are still found under Administration -> Repositories and it's still possible to browse the repositorie and see the changes. But Redmine will no longer associate revisions to redmine ids.
I already tried to remove the keywords, save the changes and readd them. No succes.
I told Redmine to re-read all the changesets using the command "rails runner "Repository.fetch_changesets" -e production"
But nothing seems to work.
Any ideas?
Have You changed subversion system or commits numbering?
Link to a changeset with a *non-numeric* hash: commit:c6f4d0fd (displays c6f4d0fd).
Or, this can be bug in Redmine
http://www.redmine.org/issues/13000
When you change the reference keywords they only work for new committs. If you want them work for old commits you have to delete the repository inside yor redmineproject and readd ir there. On the next fetch of changesets (if you have fetch changesets automatically activated yust openthe repository tab in your project) the keywords are used for all commits, including old onea.
For example you have a commit with "#1234" as commitmessage and the default keywords (ref, reference issue [as far as I remember]) rhe ticked 1234 would not be connected to the commit. Now changing the keywords to just * (single star means every issuenumber is bind without keyword) it would still be not connected. When now delete, readd and refetch changesets the issue 1234 would be connected to the commit