Skip to content

GitLab

  • Menu
Projects Groups Snippets
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • cubicweb cubicweb
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 197
    • Issues 197
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 15
    • Merge requests 15
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Packages & Registries
    • Packages & Registries
    • Container Registry
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • cubicweb
  • cubicwebcubicweb
  • Issues
  • #107

Closed
Open
Created Nov 17, 2020 by François Ferry@fferryMaintainer

[migration] add_relation don't take into account `required=True`

How to reproduce this bug ?

  • take one of your cube, add poulet=String(required=True) in one class schema declaration, and run db-init. If you ask postgresql, you should find that poulet is NON-nullable ;
  • on an existing base, add poulet=String(required=True) in one class schema declaration, and add this attribute in the shell with add_attribute("MyClass", "poulet"). If you ask postgresql, you should find that poulet can be NULL, while it shouldn't.

Cubicweb version 3.28, with postgresql 11

Edited Nov 17, 2020 by François Ferry
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
Time tracking