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

Add breeze generate-migration-file command #39632

Merged
merged 2 commits into from
May 15, 2024

Conversation

ephraimbuddy
Copy link
Contributor

This helps to generate alembic migration file for ORM changes.

Closes: #39576

This helps to generate alembic migration file for ORM changes.

Closes: apache#39576
Copy link
Member

@potiuk potiuk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

NIT. Can you also add information about this command to to contributing-docs/13_metadata_database_updates.rst ?

@ephraimbuddy
Copy link
Contributor Author

@potiuk
Copy link
Member

potiuk commented May 15, 2024

Screenshot 2024-05-15 at 07 12 45

@ephraimbuddy
Copy link
Contributor Author

Screenshot 2024-05-15 at 07 12 45

Other commands like build-docs did not create a new file like it's suggesting I create: dev/breeze/src/airflow_breeze/commands/generate_migration_file_commands_config.py. I thought having it in dev/breeze/src/airflow_breeze/commands/developer_commands_config.py is enough

@potiuk
Copy link
Member

potiuk commented May 15, 2024

Other commands like build-docs did not create a new file like it's suggesting I create: dev/breeze/src/airflow_breeze/commands/generate_migration_file_commands_config.py. I thought having it in dev/breeze/src/airflow_breeze/commands/developer_commands_config.py is enough

Yeah that message is not 100% correct in all cases - release_commands for example are also in a different place. It might need some improvement. But generally it's about making sure there is a group defined and used in breeze so that the --message in help does not land in Common options group.

@ephraimbuddy
Copy link
Contributor Author

Other commands like build-docs did not create a new file like it's suggesting I create: dev/breeze/src/airflow_breeze/commands/generate_migration_file_commands_config.py. I thought having it in dev/breeze/src/airflow_breeze/commands/developer_commands_config.py is enough

Yeah that message is not 100% correct in all cases - release_commands for example are also in a different place. It might need some improvement. But generally it's about making sure there is a group defined and used in breeze so that the --message in help does not land in Common options group.

Solved it by adding it to the developer_command in dev/breeze/src/airflow_breeze/commands/setup_commands.py

@ephraimbuddy ephraimbuddy merged commit 6afc75f into apache:main May 15, 2024
68 checks passed
@ephraimbuddy ephraimbuddy deleted the autogenerate-cmd2 branch May 15, 2024 15:02
ephraimbuddy added a commit to astronomer/airflow that referenced this pull request May 15, 2024
This was suggested by Jarek in apache#39632 but I forgot to include it.
ephraimbuddy added a commit to astronomer/airflow that referenced this pull request May 15, 2024
This was suggested by Jarek in apache#39632 but I forgot to include it.
ephraimbuddy added a commit to astronomer/airflow that referenced this pull request May 15, 2024
ephraimbuddy added a commit that referenced this pull request May 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants