Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Re-Introspection removes shadowDatabaseUrl from schema #7337

Closed
janpio opened this issue May 29, 2021 · 1 comment · Fixed by prisma/prisma-engines#1990
Closed

Re-Introspection removes shadowDatabaseUrl from schema #7337

janpio opened this issue May 29, 2021 · 1 comment · Fixed by prisma/prisma-engines#1990
Assignees
Labels
bug/2-confirmed Bug has been reproduced and confirmed. kind/bug A reported bug. team/schema Issue for team Schema. topic: re-introspection
Milestone

Comments

@janpio
Copy link
Member

janpio commented May 29, 2021

Bug description

Running Introspection with an existing shadowDatabaseUrl in a datasource in a schema file, removes this property.

How to reproduce

  1. Create new project
  2. Fill via Introspection
  3. Add shadowDatabaseUrl in schema
  4. Run Introspection again
  5. Observe shadowDatabaseUrl disappearing

Expected behavior

shadowDatabaseUrl does not disappear

Environment & setup

  • OS: Windows
  • Database: MySQL
  • Node.js version: v14.16.1

Prisma Version

C:\Users\Jan\Documents\throwaway\planetscale>npx prisma -v          
Environment variables loaded from .env
prisma               : 2.24.0-dev.27
@prisma/client       : 2.24.0-dev.27
Current platform     : windows
Query Engine         : query-engine 5ab68a73e954e003cc528d6e1e42d924ce99c676 (at node_modules\@prisma\engines\query-engine-windows.exe)
Migration Engine     : migration-engine-cli 5ab68a73e954e003cc528d6e1e42d924ce99c676 (at node_modules\@prisma\engines\migration-engine-windows.exe)
Introspection Engine : introspection-core 5ab68a73e954e003cc528d6e1e42d924ce99c676 (at node_modules\@prisma\engines\introspection-engine-windows.exe)
Format Binary        : prisma-fmt 5ab68a73e954e003cc528d6e1e42d924ce99c676 (at node_modules\@prisma\engines\prisma-fmt-windows.exe)
Default Engines Hash : 5ab68a73e954e003cc528d6e1e42d924ce99c676
Studio               : 0.397.0
@janpio janpio added bug/1-unconfirmed Bug should have enough information for reproduction, but confirmation has not happened yet. kind/bug A reported bug. topic: re-introspection team/schema Issue for team Schema. labels May 29, 2021
@pantharshit00
Copy link
Contributor

This is reproducible.

@pantharshit00 pantharshit00 added bug/2-confirmed Bug has been reproduced and confirmed. process/candidate and removed bug/1-unconfirmed Bug should have enough information for reproduction, but confirmation has not happened yet. labels May 31, 2021
@tomhoule tomhoule added this to the 2.25.0 milestone Jun 2, 2021
@tomhoule tomhoule self-assigned this Jun 3, 2021
tomhoule added a commit to prisma/prisma-engines that referenced this issue Jun 3, 2021
It was previously not included in the lowering of the datamodel to an
AST (after introspection).

closes prisma/prisma#7337
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug/2-confirmed Bug has been reproduced and confirmed. kind/bug A reported bug. team/schema Issue for team Schema. topic: re-introspection
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants