amberframework / amber

A Crystal web framework that makes building applications fast, simple, and enjoyable. Get started with quick prototyping, less bugs, and blazing fast performance.
https://amberframework.org
MIT License
2.58k stars 206 forks source link

Broken Jennifer support in new amber projects #1288

Closed korun closed 1 year ago

korun commented 2 years ago

Description

Hello!
If we try to use Jennifer in fresh amber project -- we'll get an error:

Error shard name (i18n) has ambiguous sources: 'git: https://github.com/dare892/i18n.cr.git' and 'git: https://github.com/crimson-knight/i18n.cr.git'.

Seems like it was appeared after this request #1263.
See also @crimson-knight comment here: https://github.com/dare892/citrine-i18n/commit/98709b1076cce3fe7ab64f3b1b1f847aa078dfb6#r53309756

Steps to Reproduce

  1. Generate fresh project with amber new test1
  2. cd test1
  3. Add Jennifer shard to shard.yml:
    jennifer:
    github: imdrasil/jennifer.cr
    version: "~> 0.12.0"
  4. Run shards install

Expected behavior: all dependencies resolved correctly

Actual behavior: error on i18n package from dare892/citrine-i18n

Reproduces how often: 100%

Versions

$ amber --version
Amber CLI (amberframework.org) - v1.2.2

$ crystal --version
Crystal 1.5.0 (2022-07-06)

LLVM: 14.0.6
Default target: x86_64-apple-macosx

$ shards --version
Shards 0.17.0 (2022-03-24)

Additional Information

Maybe we can update official amberframework/citrine-i18n repo, and fix all the links to point to it..?

korun commented 2 years ago

If anyone need temporary solution: we can create file shard.override.yml with:

dependencies:
  i18n:
    github: crimson-knight/i18n.cr
    version: "~> 0.4.1"
crimson-knight commented 2 years ago

Hi @korun thanks for submitting this. I'm aware of this compatibility issue, and I'm also currently working to make Jennifer the default ORM for Amber which will entirely resolve this issue.

Welcome to Amber! Make sure to join us in the discord https://discord.gg/vwvP5zakSn